forked from open-telemetry/opentelemetry-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes open-telemetry#2421
- Loading branch information
Showing
16 changed files
with
2,230 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
Run a single test, set break: | ||
|
||
ocelotl@hilleman:~/github/lightstep/otel-launcher-go/lightstep/sdk/metric/aggregator/histogram/structure$ dlv test -- -test.run TestAlternatingGrowth1 | ||
Type 'help' for list of commands. | ||
(dlv) break tryIncrement | ||
Breakpoint 1 set at 0x68d100,0x68d900,0x68e100,0x68f5e6,0x68f9e6,0x68fde6,0x6901e6,0x68e8e0 for github.com/lightstep/otel-launcher-go/lightstep/sdk/metric/aggregator/histogram/structure.(*bucketsVarwidth).tryIncrement() <autogenerated>:1 | ||
(dlv) c | ||
> github.com/lightstep/otel-launcher-go/lightstep/sdk/metric/aggregator/histogram/structure.(*bucketsVarwidth[uint8]).tryIncrement() <autogenerated>:1 (hits goroutine(6):1 total:1) (PC: 0x68f5e6) | ||
(dlv) l | ||
> github.com/lightstep/otel-launcher-go/lightstep/sdk/metric/aggregator/histogram/structure.(*bucketsVarwidth[uint8]).tryIncrement() <autogenerated>:1 (hits goroutine(6):1 total:1) (PC: 0x68f5e6) | ||
Command failed: open <autogenerated>: no such file or directory | ||
(dlv) n | ||
> github.com/lightstep/otel-launcher-go/lightstep/sdk/metric/aggregator/histogram/structure.(*bucketsVarwidth[go.shape.uint8_0]).tryIncrement() ./exponential.go:684 (hits goroutine(6):2 total:2) (PC: 0x68d100) | ||
679: tmp := b.counts[src] | ||
680: b.counts[src] = 0 | ||
681: return uint64(tmp) | ||
682: } | ||
683: | ||
=> 684: func (b *bucketsVarwidth[N]) tryIncrement(bucketIndex int32, incr uint64) bool { | ||
685: var limit = uint64(N(0) - 1) | ||
686: if uint64(b.counts[bucketIndex])+incr <= limit { | ||
687: b.counts[bucketIndex] += N(incr) | ||
688: return true | ||
689: } | ||
(dlv) print b.counts | ||
[]uint8 len: 1, cap: 1, [0] | ||
(dlv) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
IEE 754 | ||
======= | ||
|
||
|
||
A *normalized* number is written in *scientific notation* with one non-zero | ||
decimal digit before the decimal point. | ||
|
||
The binary representation of a normalized number will always have its first bit | ||
set to 1. To avoid spending space in this bit, it is implicit. | ||
|
||
IEE 754 double precision numbers are represented like this: | ||
|
||
1-sign-bit 11-exponent-bits 52-significand-bits for a total of 64 bits. |
Oops, something went wrong.