Searched refs:bucket (Results 1 - 25 of 91) sorted by relevance

1234

/frameworks/base/libs/androidfw/include/androidfw/
H A DByteBucketArray.h55 T* bucket = buckets_[bucket_index]; local
56 if (bucket == NULL) {
59 return bucket[0x0f & static_cast<uint8_t>(index)];
67 T* bucket = buckets_[bucket_index];
68 if (bucket == NULL) {
69 bucket = buckets_[bucket_index] = new T[kBucketSize]();
71 return bucket[0x0f & static_cast<uint8_t>(index)];
/frameworks/support/car/src/main/java/androidx/car/widget/
H A DIAlphaJumpAdapter.java26 * A bucket represents a "button" in the alpha-jump menu.
30 * Return true if the bucket is empty (and therefore the button should be displayed
36 * Return the label for this bucket, that is displayed at the text to the user.
41 * Return the index of the first item that this bucket matches in the list.
59 * @param bucket The {@link Bucket} that the user clicked on, and should be jumped to.
61 void onAlphaJumpLeave(Bucket bucket); argument
H A DAlphaJumpOverlayView.java65 for (IAlphaJumpAdapter.Bucket bucket : mBuckets) {
68 btn.setText(bucket.getLabel());
70 btn.setTag(bucket);
71 if (bucket.isEmpty()) {
80 IAlphaJumpAdapter.Bucket bucket = (IAlphaJumpAdapter.Bucket) v.getTag();
81 if (bucket != null) {
82 mAdapter.onAlphaJumpLeave(bucket);
84 mPagedListView.snapToPosition(bucket.getIndex());
/frameworks/base/cmds/statsd/src/anomaly/
H A DAnomalyTracker.cpp55 // Excludes the current bucket.
62 ALOGE("index() was passed a negative bucket number (%lld)!", (long long)bucketNum);
88 mPastBuckets[idx] = nullptr; // release (but not clear) the old bucket.
104 // We need to insert into an already existing past bucket.
105 std::shared_ptr<DimToValMap>& bucket = mPastBuckets[bucketIndex]; local
106 auto itr = bucket->find(key);
107 if (itr != bucket->end()) {
112 bucket->insert({key, bucketValue});
117 std::shared_ptr<DimToValMap> bucket = std::make_shared<DimToValMap>(); local
118 bucket
123 addPastBucket(std::shared_ptr<DimToValMap> bucket, const int64_t& bucketNum) argument
142 subtractBucketFromSum(const shared_ptr<DimToValMap>& bucket) argument
164 addBucketToSum(const shared_ptr<DimToValMap>& bucket) argument
182 const auto& bucket = mPastBuckets[index(bucketNum)]; local
[all...]
H A DAnomalyTracker.h50 // Adds a bucket for the given bucketNum (index starting at 0).
51 // If a bucket for bucketNum already exists, it will be replaced.
54 void addPastBucket(std::shared_ptr<DimToValMap> bucket, const int64_t& bucketNum);
56 // Inserts (or replaces) the bucket entry for the given bucketNum at the given key to be the
57 // given bucketValue. If the bucket does not exist, it will be created.
64 // represents the partially-filled current bucket), an anomaly has happened.
73 // represents the partially-filled current bucket), an anomaly has happened, and if so,
84 // Returns the sum of all past bucket values for the given dimension key.
87 // Returns the value for a past bucket, or 0 if that bucket does
[all...]
/frameworks/base/tests/net/java/android/app/usage/
H A DNetworkStatsManagerTest.java135 NetworkStats.Bucket bucket = new NetworkStats.Bucket();
138 assertTrue(stats.getNextBucket(bucket));
139 assertEquals(10, bucket.getStartTimeStamp());
140 assertEquals(20, bucket.getEndTimeStamp());
141 assertBucketMatches(uid1Entry1, bucket);
143 assertTrue(stats.getNextBucket(bucket));
144 assertEquals(20, bucket.getStartTimeStamp());
145 assertEquals(30, bucket.getEndTimeStamp());
146 assertBucketMatches(uid1Entry2, bucket);
149 assertTrue(stats.getNextBucket(bucket));
[all...]
/frameworks/base/cmds/statsd/tests/
H A Dstatsd_test_util.h277 const int64_t timeBaseNs, const int64_t bucketSizeNs, T* bucket) {
278 bucket->set_start_bucket_elapsed_nanos(timeBaseNs + bucketSizeNs * bucket->bucket_num());
279 bucket->set_end_bucket_elapsed_nanos(
280 timeBaseNs + bucketSizeNs * bucket->bucket_num() + bucketSizeNs);
281 bucket->clear_bucket_num();
285 void backfillStartEndTimestampForPartialBucket(const int64_t timeBaseNs, T* bucket) { argument
286 if (bucket->has_start_bucket_elapsed_millis()) {
287 bucket->set_start_bucket_elapsed_nanos(
288 MillisToNano(bucket
276 backfillStartEndTimestampForFullBucket( const int64_t timeBaseNs, const int64_t bucketSizeNs, T* bucket) argument
304 auto bucket = data->mutable_bucket_info(j); local
[all...]
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/util/
H A DMetricsUtils.java26 * A generic bucket containing a start, end, and count. The utility classes will convert to
27 * such a generic bucket which can then be copied into the specific bucket of the proto.
39 * Each big bucket is divided into S sub-buckets
41 * Each (big) bucket is M times bigger than the previous one.
78 public double[] bb; // bucket base
79 public double[] sbw; // sub-bucket width
100 if (subBucketIndex >= hp.s) { // probably a rounding error so move to next big bucket
141 * The 'int[] hp' contains a list of bucket limits. The number of buckets is hp.length() + 1
149 int bucket
[all...]
/frameworks/base/cmds/statsd/tools/loadtest/src/com/android/statsd/loadtest/
H A DPerfData.java57 TimeUnit bucket, long periodSecs, int burst, boolean includeCountMetric,
60 super(placebo, replication, bucket, periodSecs, burst, includeCountMetric,
63 mRecorders.add(new BatteryDataRecorder(placebo, replication, bucket, periodSecs, burst,
66 mRecorders.add(new MemoryDataRecorder(placebo, replication, bucket, periodSecs, burst,
69 mRecorders.add(new StatsdStatsRecorder(loadtestActivity, placebo, replication, bucket,
72 mRecorders.add(new ValidationRecorder(loadtestActivity, placebo, replication, bucket,
56 PerfData(LoadtestActivity loadtestActivity, boolean placebo, int replication, TimeUnit bucket, long periodSecs, int burst, boolean includeCountMetric, boolean includeDurationMetric, boolean includeEventMetric, boolean includeValueMetric, boolean includeGaugeMetric) argument
H A DMemoryDataRecorder.java30 public MemoryDataRecorder(boolean placebo, int replication, TimeUnit bucket, long periodSecs, argument
33 super(placebo, replication, bucket, periodSecs, burst, includeCountMetric,
H A DConfigFactory.java85 * the number of metrics in the config. One can also adjust the bucket size for aggregate
91 * @param bucketMillis The bucket size, in milliseconds, for aggregate metrics
95 public ConfigMetadata getConfig(int replication, TimeUnit bucket, boolean placebo, argument
114 addCountMetric(metric, i, bucket, config);
120 addDurationMetric(metric, i, bucket, config);
126 addGaugeMetric(metric, i, bucket, config);
132 addValueMetric(metric, i, bucket, config);
188 * with the provided suffix, and overrides the bucket size. Then adds that metric to the config.
190 private void addCountMetric(CountMetric template, int suffix, TimeUnit bucket, argument
203 metric.setBucket(bucket);
211 addDurationMetric(DurationMetric template, int suffix, TimeUnit bucket, StatsdConfig.Builder config) argument
232 addGaugeMetric(GaugeMetric template, int suffix, TimeUnit bucket, StatsdConfig.Builder config) argument
253 addValueMetric(ValueMetric template, int suffix, TimeUnit bucket, StatsdConfig.Builder config) argument
[all...]
H A DBatteryDataRecorder.java30 public BatteryDataRecorder(boolean placebo, int replication, TimeUnit bucket, long periodSecs, argument
33 super(placebo, replication, bucket, periodSecs, burst, includeCountMetric,
H A DStatsdStatsRecorder.java28 TimeUnit bucket, long periodSecs, int burst, boolean includeCountMetric,
31 super(placebo, replication, bucket, periodSecs, burst, includeCountMetric,
27 StatsdStatsRecorder(LoadtestActivity loadtestActivity, boolean placebo, int replication, TimeUnit bucket, long periodSecs, int burst, boolean includeCountMetric, boolean includeDurationMetric, boolean includeEventMetric, boolean includeValueMetric, boolean includeGaugeMetric) argument
H A DValidationRecorder.java37 TimeUnit bucket, long periodSecs, int burst, boolean includeCountMetric,
40 super(placebo, replication, bucket, periodSecs, burst, includeCountMetric,
36 ValidationRecorder(LoadtestActivity loadtestActivity, boolean placebo, int replication, TimeUnit bucket, long periodSecs, int burst, boolean includeCountMetric, boolean includeDurationMetric, boolean includeEventMetric, boolean includeValueMetric, boolean includeGaugeMetric) argument
H A DPerfDataRecorder.java42 protected PerfDataRecorder(boolean placebo, int replication, TimeUnit bucket, long periodSecs, argument
46 mColumnSuffix = getColumnSuffix(placebo, replication, bucket, periodSecs, burst,
127 private String getColumnSuffix(boolean placebo, int replication, TimeUnit bucket, argument
135 .append("_bkt=" + bucket)
/frameworks/base/core/java/android/app/usage/
H A DAppStandbyInfo.java23 * A pair of {package, bucket} to denote the app standby bucket for a given package.
37 public AppStandbyInfo(String packageName, int bucket) { argument
39 mStandbyBucket = bucket;
/frameworks/rs/
H A DrsMap.h40 for (size_t i = 0; i < MAP_NUM_BUCKET; i++) { bucket[i] = nullptr; }
45 LinkNode* p = bucket[i];
57 LinkNode* node = bucket[index];
72 bucket[index] = node;
92 next = map->bucket[bucket_index];
128 LinkNode* node = bucket[i];
145 LinkNode* node = bucket[index];
160 LinkNode* bucket[MAP_NUM_BUCKET]; member in class:android::renderscript::Map
/frameworks/base/core/java/com/android/internal/app/procstats/
H A DSysMemUsageTable.java149 final int bucket = ((iscreen + imem) * STATE_COUNT);
150 long count = getValueForId((byte)bucket, SYS_MEM_USAGE_SAMPLE_COUNT);
166 dumpCategory(pw, prefix, " Cached", bucket, SYS_MEM_USAGE_CACHED_MINIMUM);
167 dumpCategory(pw, prefix, " Free", bucket, SYS_MEM_USAGE_FREE_MINIMUM);
168 dumpCategory(pw, prefix, " ZRam", bucket, SYS_MEM_USAGE_ZRAM_MINIMUM);
169 dumpCategory(pw, prefix, " Kernel", bucket, SYS_MEM_USAGE_KERNEL_MINIMUM);
170 dumpCategory(pw, prefix, " Native", bucket, SYS_MEM_USAGE_NATIVE_MINIMUM);
176 private void dumpCategory(PrintWriter pw, String prefix, String label, int bucket, int index) { argument
179 DebugUtils.printSizeValue(pw, getValueForId((byte)bucket, index) * 1024);
181 DebugUtils.printSizeValue(pw, getValueForId((byte)bucket, inde
[all...]
/frameworks/av/media/libnblog/
H A DReportPerformance.cpp89 for (auto bucket = hist->second.begin(); bucket != hist->second.end(); ++bucket) {
90 hfs << bucket->first / static_cast<double>(kJiffyPerMs)
91 << ", " << bucket->second;
92 if (std::next(bucket) != end(hist->second)) {
/frameworks/base/cmds/statsd/src/metrics/
H A DCountMetricProducer.cpp74 TimeUnitToBucketSizeInMillisGuardrailed(key.GetUid(), metric.bucket()) * 1000000;
104 VLOG("metric %lld created. bucket size %lld start_time: %lld", (long long)metric.id(),
207 for (const auto& bucket : counter.second) {
210 // Partial bucket.
211 if (bucket.mBucketEndNs - bucket.mBucketStartNs != mBucketSizeNs) {
213 (long long)NanoToMillis(bucket.mBucketStartNs));
215 (long long)NanoToMillis(bucket.mBucketEndNs));
218 (long long)(getBucketNumFromEndTimeNs(bucket.mBucketEndNs)));
220 protoOutput->write(FIELD_TYPE_INT64 | FIELD_ID_COUNT, (long long)bucket
[all...]
H A DGaugeMetricProducer.cpp93 bucketSizeMills = TimeUnitToBucketSizeInMillisGuardrailed(key.GetUid(), metric.bucket());
134 VLOG("Gauge metric %lld created. bucket size %lld start_time: %lld sliced %d",
259 for (const auto& bucket : pair.second) {
263 if (bucket.mBucketEndNs - bucket.mBucketStartNs != mBucketSizeNs) {
265 (long long)NanoToMillis(bucket.mBucketStartNs));
267 (long long)NanoToMillis(bucket.mBucketEndNs));
270 (long long)(getBucketNumFromEndTimeNs(bucket.mBucketEndNs)));
273 if (!bucket.mGaugeAtoms.empty()) {
274 for (const auto& atom : bucket
[all...]
/frameworks/compile/mclinker/include/mcld/ADT/
H A DHashIterator.h37 bucket_type& bucket = m_pHashTable->m_Buckets[m_Index]; local
38 if (bucket_type::getTombstone() == bucket.Entry) {
40 } else if (m_HashValue == bucket.FullHashValue) {
41 if (bucket.Entry->compare(pKey)) {
116 bucket_type& bucket = m_pHashTable->m_Buckets[m_Index]; local
118 if (bucket_type::getTombstone() == bucket.Entry ||
119 bucket_type::getEmptyBucket() == bucket.Entry) {
121 } else if (m_HashValue == bucket.FullHashValue) {
/frameworks/ex/common/tools/
H A Dmake-iana-tld-pattern.py126 bucket = buckets.get(letter)
128 if bucket is None:
129 bucket = Bucket(letter)
130 buckets[letter] = bucket
132 return bucket
/frameworks/opt/net/wifi/tests/wifitests/src/com/android/server/wifi/
H A DScanTestUtil.java142 WifiNative.BucketSettings bucket = new WifiNative.BucketSettings();
143 bucket.bucket = mSettings.num_buckets;
144 bucket.band = band;
145 bucket.period_ms = period;
146 bucket.report_events = reportEvents;
147 return addBucket(bucket);
161 WifiNative.BucketSettings bucket = new WifiNative.BucketSettings();
162 bucket.bucket
171 addBucket(WifiNative.BucketSettings bucket) argument
[all...]
/frameworks/native/services/surfaceflinger/TimeStats/timestatsproto/
H A DTimeStatsHelper.cpp62 int32_t bucket = histogramConfig[i]; local
63 int32_t count = (hist.count(bucket) == 0) ? 0 : hist.at(bucket);
64 StringAppendF(&result, "%dms=%d ", bucket, count);

Completed in 506 milliseconds

1234