/external/webrtc/webrtc/base/ |
D | random_unittest.cc | 37 void UniformBucketTest(T bucket_count, int samples, Random* prng) { in UniformBucketTest() argument 38 std::vector<int> buckets(bucket_count, 0); in UniformBucketTest() 44 static_cast<T>(total_values % static_cast<uint64_t>(bucket_count)); in UniformBucketTest() 56 buckets[fdiv_remainder(sample, bucket_count)]++; in UniformBucketTest() 59 for (T i = 0; i < bucket_count; i++) { in UniformBucketTest() 61 EXPECT_NEAR(buckets[i], samples / bucket_count, in UniformBucketTest() 62 3 * sqrt(samples / bucket_count)); in UniformBucketTest() 111 void BucketTestSignedInterval(unsigned int bucket_count, in BucketTestSignedInterval() argument 117 std::vector<unsigned int> buckets(bucket_count, 0); in BucketTestSignedInterval() 120 ASSERT_GE(bucket_count, 2u); in BucketTestSignedInterval() [all …]
|
/external/libchrome/base/metrics/ |
D | histogram.cc | 43 uint32_t* bucket_count, in ReadHistogramArguments() argument 49 !iter->ReadUInt32(bucket_count) || in ReadHistogramArguments() 60 INT_MAX / sizeof(HistogramBase::Count) <= *bucket_count || in ReadHistogramArguments() 61 *bucket_count < 2) { in ReadHistogramArguments() 94 uint32_t bucket_count, in Factory() argument 96 : Factory(name, HISTOGRAM, minimum, maximum, bucket_count, flags) {} in Factory() 108 uint32_t bucket_count, in Factory() argument 114 bucket_count_(bucket_count), in Factory() 163 bucket_count_ = static_cast<uint32_t>(registered_ranges->bucket_count()); in Build() 238 uint32_t bucket_count, in FactoryGet() argument [all …]
|
D | sample_vector.cc | 20 local_counts_(bucket_ranges->bucket_count()), in SampleVector() 24 CHECK_GE(bucket_ranges_->bucket_count(), 1u); in SampleVector() 34 counts_size_(bucket_ranges->bucket_count()), in SampleVector() 36 CHECK_LE(bucket_ranges_->bucket_count(), counts_size_); in SampleVector() 37 CHECK_GE(bucket_ranges_->bucket_count(), 1u); in SampleVector() 104 size_t bucket_count = bucket_ranges_->bucket_count(); in GetBucketIndex() local 105 CHECK_GE(bucket_count, 1u); in GetBucketIndex() 107 CHECK_LT(value, bucket_ranges_->range(bucket_count)); in GetBucketIndex() 110 size_t over = bucket_count; in GetBucketIndex() 135 CHECK_GE(bucket_ranges_->bucket_count(), counts_size_); in SampleVectorIterator() [all …]
|
D | persistent_histogram_allocator.cc | 78 size_t CalculateRequiredCountsBytes(size_t bucket_count) { in CalculateRequiredCountsBytes() argument 86 if (bucket_count > std::numeric_limits<size_t>::max() / kBytesPerBucket) in CalculateRequiredCountsBytes() 89 return bucket_count * kBytesPerBucket; in CalculateRequiredCountsBytes() 240 uint32_t bucket_count; member 335 size_t bucket_count = bucket_ranges->bucket_count(); in AllocateHistogram() local 336 size_t counts_bytes = CalculateRequiredCountsBytes(bucket_count); in AllocateHistogram() 343 size_t ranges_count = bucket_count + 1; in AllocateHistogram() 366 histogram_data->bucket_count = static_cast<uint32_t>(bucket_count); in AllocateHistogram() 561 (histogram_data.bucket_count + 1) * sizeof(HistogramBase::Sample); in CreateHistogram() 564 if (!ranges_data || histogram_data.bucket_count < 2 || in CreateHistogram() [all …]
|
/external/libcxx/test/std/containers/unord/unord.set/ |
D | reserve.pass.cpp | 40 size_t buckets = c.bucket_count(); in reserve_invariant() 44 assert(buckets == c.bucket_count()); in reserve_invariant() 65 assert(c.bucket_count() >= 5); in main() 67 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 71 assert(c.bucket_count() >= 2); in main() 74 assert(c.bucket_count() >= 16); in main() 93 assert(c.bucket_count() >= 5); in main() 95 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 99 assert(c.bucket_count() >= 2); in main() 102 assert(c.bucket_count() >= 16); in main()
|
D | rehash.pass.cpp | 27 assert(c.bucket_count() >= c.size() / c.max_load_factor() && c.bucket_count() >= n); in rehash_postcondition() 56 assert(c.bucket_count() >= 5); in main() 59 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 64 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 68 LIBCPP_ASSERT(c.bucket_count() == 31); in main() 87 assert(c.bucket_count() >= 5); in main() 90 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 95 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 99 LIBCPP_ASSERT(c.bucket_count() == 31); in main()
|
D | swap_member.pass.cpp | 40 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 49 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 80 assert(c1.bucket_count() >= 8); in main() 97 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 126 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 135 assert(c2.bucket_count() >= 4); in main() 179 assert(c1.bucket_count() >= 8); in main() 196 assert(c2.bucket_count() >= 4); in main() 220 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 229 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() [all …]
|
/external/libcxx/test/std/containers/unord/unord.multiset/ |
D | rehash.pass.cpp | 27 assert(c.bucket_count() >= c.size() / c.max_load_factor() && c.bucket_count() >= n); in rehash_postcondition() 56 assert(c.bucket_count() >= 7); in main() 59 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 64 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 68 LIBCPP_ASSERT(c.bucket_count() == 31); in main() 87 assert(c.bucket_count() >= 7); in main() 90 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 95 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 99 LIBCPP_ASSERT(c.bucket_count() == 31); in main()
|
D | reserve.pass.cpp | 40 size_t buckets = c.bucket_count(); in reserve_invariant() 44 assert(buckets == c.bucket_count()); in reserve_invariant() 65 assert(c.bucket_count() >= 7); in main() 67 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 71 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 74 assert(c.bucket_count() >= 16); in main() 93 assert(c.bucket_count() >= 7); in main() 95 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 99 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 102 assert(c.bucket_count() >= 16); in main()
|
D | swap_member.pass.cpp | 40 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 49 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 80 assert(c1.bucket_count() >= 8); in main() 97 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 126 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 135 assert(c2.bucket_count() >= 6); in main() 179 assert(c1.bucket_count() >= 8); in main() 196 assert(c2.bucket_count() >= 6); in main() 220 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 229 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() [all …]
|
/external/libcxx/test/std/containers/unord/unord.map/ |
D | reserve.pass.cpp | 41 size_t buckets = c.bucket_count(); in reserve_invariant() 45 assert(buckets == c.bucket_count()); in reserve_invariant() 66 assert(c.bucket_count() >= 5); in main() 68 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 72 assert(c.bucket_count() >= 2); in main() 75 assert(c.bucket_count() >= 16); in main() 94 assert(c.bucket_count() >= 5); in main() 96 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 100 assert(c.bucket_count() >= 2); in main() 103 assert(c.bucket_count() >= 16); in main()
|
D | rehash.pass.cpp | 28 assert(c.bucket_count() >= c.size() / c.max_load_factor() && c.bucket_count() >= n); in rehash_postcondition() 57 assert(c.bucket_count() >= 5); in main() 60 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 65 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 69 LIBCPP_ASSERT(c.bucket_count() == 31); in main() 88 assert(c.bucket_count() >= 5); in main() 91 LIBCPP_ASSERT(c.bucket_count() == 5); in main() 96 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 100 LIBCPP_ASSERT(c.bucket_count() == 31); in main()
|
D | swap_member.pass.cpp | 41 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 50 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 81 assert(c1.bucket_count() >= 8); in main() 98 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 127 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 136 assert(c2.bucket_count() >= 4); in main() 180 assert(c1.bucket_count() >= 8); in main() 197 assert(c2.bucket_count() >= 4); in main() 221 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 230 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() [all …]
|
/external/libcxx/test/std/containers/unord/unord.multimap/ |
D | reserve.pass.cpp | 43 size_t buckets = c.bucket_count(); in reserve_invariant() 47 assert(buckets == c.bucket_count()); in reserve_invariant() 68 assert(c.bucket_count() >= 7); in main() 70 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 74 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 77 assert(c.bucket_count() >= 16); in main() 96 assert(c.bucket_count() >= 7); in main() 98 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 102 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 105 assert(c.bucket_count() >= 16); in main()
|
D | rehash.pass.cpp | 31 assert(c.bucket_count() >= c.size() / c.max_load_factor() && c.bucket_count() >= n); in rehash_postcondition() 68 assert(std::fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in test() 87 assert(c.bucket_count() >= 7); in main() 90 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 95 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 99 LIBCPP_ASSERT(c.bucket_count() == 31); in main() 118 assert(c.bucket_count() >= 7); in main() 121 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 126 LIBCPP_ASSERT(c.bucket_count() == 3); in main() 130 LIBCPP_ASSERT(c.bucket_count() == 31); in main()
|
/external/tensorflow/tensorflow/core/lib/monitoring/ |
D | sampler.cc | 66 ExponentialBuckets(double scale, double growth_factor, int bucket_count) in ExponentialBuckets() argument 68 ComputeBucketLimits(scale, growth_factor, bucket_count)) {} in ExponentialBuckets() 77 int bucket_count) { in ComputeBucketLimits() argument 78 CHECK_GT(bucket_count, 0); in ComputeBucketLimits() 81 for (int i = 0; i < bucket_count; i++) { in ComputeBucketLimits() 104 int bucket_count) { in Exponential() argument 106 new ExponentialBuckets(scale, growth_factor, bucket_count)); in Exponential()
|
/external/libcxx/test/std/containers/unord/unord.set/unord.set.swap/ |
D | swap_non_member.pass.cpp | 40 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 49 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 80 assert(c1.bucket_count() >= 8); in main() 97 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 126 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 135 assert(c2.bucket_count() >= 4); in main() 179 assert(c1.bucket_count() >= 8); in main() 196 assert(c2.bucket_count() >= 4); in main() 220 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 229 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() [all …]
|
/external/libcxx/test/std/containers/unord/unord.multiset/unord.multiset.swap/ |
D | swap_non_member.pass.cpp | 40 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 49 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 80 assert(c1.bucket_count() >= 8); in main() 97 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 126 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 135 assert(c2.bucket_count() >= 6); in main() 179 assert(c1.bucket_count() >= 8); in main() 196 assert(c2.bucket_count() >= 6); in main() 220 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 229 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() [all …]
|
/external/libcxx/test/std/containers/unord/unord.multiset/unord.multiset.cnstr/ |
D | init.pass.cpp | 48 assert(c.bucket_count() >= 7); in main() 60 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 78 assert(c.bucket_count() >= 7); in main() 90 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 111 assert(c.bucket_count() >= 12); in main() 124 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 145 assert(c.bucket_count() >= 12); in main() 159 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main()
|
D | range.pass.cpp | 50 assert(c.bucket_count() >= 7); in main() 62 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 83 assert(c.bucket_count() >= 7); in main() 95 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 116 assert(c.bucket_count() >= 12); in main() 129 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 150 assert(c.bucket_count() >= 16); in main() 164 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main()
|
D | assign_move.pass.cpp | 63 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 83 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 116 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 128 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 161 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 173 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 206 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 218 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 251 LIBCPP_ASSERT(c.bucket_count() == 7); in main() 263 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main()
|
/external/libcxx/test/std/containers/unord/unord.set/unord.set.cnstr/ |
D | init.pass.cpp | 48 assert(c.bucket_count() >= 5); in main() 60 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 78 assert(c.bucket_count() >= 5); in main() 90 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 111 assert(c.bucket_count() >= 12); in main() 124 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 145 assert(c.bucket_count() >= 12); in main() 159 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main()
|
D | range.pass.cpp | 50 assert(c.bucket_count() >= 5); in main() 62 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 83 assert(c.bucket_count() >= 5); in main() 95 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 116 assert(c.bucket_count() >= 12); in main() 129 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 150 assert(c.bucket_count() >= 16); in main() 164 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main()
|
/external/libcxx/test/std/containers/unord/unord.map/unord.map.cnstr/ |
D | init.pass.cpp | 49 assert(c.bucket_count() >= 5); in main() 62 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 80 assert(c.bucket_count() >= 5); in main() 93 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 113 assert(c.bucket_count() >= 12); in main() 125 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main() 145 assert(c.bucket_count() >= 12); in main() 158 assert(fabs(c.load_factor() - (float)c.size()/c.bucket_count()) < FLT_EPSILON); in main()
|
/external/libcxx/test/std/containers/unord/unord.map/unord.map.swap/ |
D | swap_non_member.pass.cpp | 41 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 50 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 81 assert(c1.bucket_count() >= 8); in main() 98 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() 127 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 136 assert(c2.bucket_count() >= 4); in main() 180 assert(c1.bucket_count() >= 8); in main() 197 assert(c2.bucket_count() >= 4); in main() 221 LIBCPP_ASSERT(c1.bucket_count() == 0); in main() 230 LIBCPP_ASSERT(c2.bucket_count() == 0); in main() [all …]
|