Skip to content

Commit

Permalink
[chore][processor/deltatocumulative] Optimize exponential histogram m…
Browse files Browse the repository at this point in the history
…erge
  • Loading branch information
lahsivjar committed Jan 2, 2025
1 parent 7ec077e commit 0b6055e
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ func Merge(arel, brel Buckets) {
size := up - lo

counts := pcommon.NewUInt64Slice()
counts.Append(make([]uint64, size-counts.Len())...)
counts.EnsureCapacity(size)

for i := 0; i < counts.Len(); i++ {
counts.SetAt(i, a.Abs(lo+i)+b.Abs(lo+i))
for i := 0; i < size; i++ {
counts.Append(a.Abs(lo+i) + b.Abs(lo+i))
}

a.SetOffset(int32(lo))
Expand Down

0 comments on commit 0b6055e

Please sign in to comment.