Skip to content

histograms: BenchmarkFloatHistogramAdd#18248

Merged
krajorama merged 2 commits into
prometheus:mainfrom
linasm:benchmark-float-histogram-add
Mar 17, 2026
Merged

histograms: BenchmarkFloatHistogramAdd#18248
krajorama merged 2 commits into
prometheus:mainfrom
linasm:benchmark-float-histogram-add

Conversation

@linasm

@linasm linasm commented Mar 6, 2026

Copy link
Copy Markdown
Contributor

Mainly for demonstrating the difference between FloatHistogram.Add and FloatHistogram.KahanAdd.

BenchmarkFloatHistogramAdd/Add
BenchmarkFloatHistogramAdd/Add-10         	   64574	     18312 ns/op	       0 B/op	       0 allocs/op
BenchmarkFloatHistogramAdd/KahanAdd
BenchmarkFloatHistogramAdd/KahanAdd-10    	   30944	     38313 ns/op	     800 B/op	       3 allocs/op
NONE

Comment thread model/histogram/float_histogram_test.go Outdated
Comment thread model/histogram/float_histogram_test.go Outdated
@krajorama krajorama self-assigned this Mar 10, 2026
Signed-off-by: Linas Medziunas <[email protected]>
@linasm
linasm force-pushed the benchmark-float-histogram-add branch from 4aeb82b to 89c46d4 Compare March 10, 2026 13:01
@linasm
linasm requested a review from krajorama March 10, 2026 13:03

@krajorama krajorama left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm

@bwplotka bwplotka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Comment thread model/histogram/float_histogram_test.go Outdated
Signed-off-by: Linas Medziunas <[email protected]>
@linasm
linasm force-pushed the benchmark-float-histogram-add branch from 24f6fa8 to 7b4aa79 Compare March 17, 2026 12:50
@krajorama
krajorama merged commit c532b65 into prometheus:main Mar 17, 2026
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants