Move SampleStatsCounter to public API
Bug: None Change-Id: I8956f6febbb1caf71e951d212d57746fe1ec5eb2 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/184506 Commit-Queue: Artem Titov <titovartem@webrtc.org> Reviewed-by: Karl Wiberg <kwiberg@webrtc.org> Cr-Commit-Position: refs/heads/master@{#32142}
This commit is contained in:
@ -120,7 +120,7 @@ void BucketTestSignedInterval(unsigned int bucket_count,
|
||||
|
||||
ASSERT_GE(high, low);
|
||||
ASSERT_GE(bucket_count, 2u);
|
||||
uint32_t interval = unsigned_difference<int32_t>(high, low) + 1;
|
||||
uint32_t interval = webrtc_impl::unsigned_difference<int32_t>(high, low) + 1;
|
||||
uint32_t numbers_per_bucket;
|
||||
if (interval == 0) {
|
||||
// The computation high - low + 1 should be 2^32 but overflowed
|
||||
@ -136,7 +136,8 @@ void BucketTestSignedInterval(unsigned int bucket_count,
|
||||
int32_t sample = prng->Rand(low, high);
|
||||
EXPECT_LE(low, sample);
|
||||
EXPECT_GE(high, sample);
|
||||
buckets[unsigned_difference<int32_t>(sample, low) / numbers_per_bucket]++;
|
||||
buckets[webrtc_impl::unsigned_difference<int32_t>(sample, low) /
|
||||
numbers_per_bucket]++;
|
||||
}
|
||||
|
||||
for (unsigned int i = 0; i < bucket_count; i++) {
|
||||
|
Reference in New Issue
Block a user