Home
last modified time | relevance | path

Searched refs:freqs (Results 1 – 20 of 20) sorted by relevance

/frameworks/base/core/tests/coretests/src/com/android/internal/os/
DKernelCpuUidFreqTimeReaderTest.java110 final long[] freqs = {110, 123, 145, 167, 289, 997}; in testReadDelta() local
111 final long[][] times = increaseTime(new long[mUids.length][freqs.length]); in testReadDelta()
113 setFreqsAndData(freqs, times); in testReadDelta()
126 setFreqsAndData(freqs, newTimes1); in testReadDelta()
141 setFreqsAndData(freqs, newTimes2); in testReadDelta()
149 setFreqsAndData(freqs, newTimes3); in testReadDelta()
160 final long[] freqs = {110, 123, 145, 167, 289, 997}; in testReadAbsolute() local
161 final long[][] times1 = increaseTime(new long[mUids.length][freqs.length]); in testReadAbsolute()
163 setFreqsAndData(freqs, times1); in testReadAbsolute()
176 setFreqsAndData(freqs, times2); in testReadAbsolute()
[all …]
/frameworks/base/core/jni/
Dcom_android_internal_os_KernelCpuBpfTracking.cpp32 auto freqs = android::bpf::getCpuFreqs(); in KernelCpuBpfTracking_getFreqsInternal() local
33 if (!freqs) return nullptr; in KernelCpuBpfTracking_getFreqsInternal()
36 for (const auto &vec : *freqs) std::copy(vec.begin(), vec.end(), std::back_inserter(allFreqs)); in KernelCpuBpfTracking_getFreqsInternal()
47 auto freqs = android::bpf::getCpuFreqs(); in KernelCpuBpfTracking_getFreqsClustersInternal() local
48 if (!freqs) return nullptr; in KernelCpuBpfTracking_getFreqsClustersInternal()
51 uint32_t clusters = freqs->size(); in KernelCpuBpfTracking_getFreqsClustersInternal()
53 freqsClusters.insert(freqsClusters.end(), (*freqs)[c].size(), c); in KernelCpuBpfTracking_getFreqsClustersInternal()
/frameworks/base/core/java/com/android/internal/os/
DCpuScalingPolicyReader.java89 int[] freqs; in read() local
91 freqs = availableFreqs; in read()
93 freqs = Arrays.copyOf(availableFreqs, in read()
95 System.arraycopy(boostFreqs, 0, freqs, availableFreqs.length, in read()
98 if (freqs.length == 0) { in read()
99 freqs = readIntsFromFile(new File(policyDir, FILE_NAME_CPUINFO_CUR_FREQ)); in read()
100 if (freqs.length == 0) { in read()
101 freqs = new int[]{0}; // Unknown frequency in read()
106 freqsByPolicy.put(policy, freqs); in read()
DKernelCpuBpfTracking.java59 long[] freqs = getFreqsInternal(); in getFreqs() local
60 if (freqs == null) { in getFreqs()
63 sFreqs = freqs; in getFreqs()
/frameworks/base/core/java/android/hardware/
DConsumerIrManager.java139 int[] freqs = mService.getCarrierFrequencies(); in getCarrierFrequencies() local
140 if (freqs.length % 2 != 0) { in getCarrierFrequencies()
144 CarrierFrequencyRange[] range = new CarrierFrequencyRange[freqs.length / 2]; in getCarrierFrequencies()
146 for (int i = 0; i < freqs.length; i += 2) { in getCarrierFrequencies()
147 range[i / 2] = new CarrierFrequencyRange(freqs[i], freqs[i+1]); in getCarrierFrequencies()
/frameworks/base/core/tests/utiltests/src/com/android/internal/util/
DHeavyHitterSketchTest.java87 final List<Float> freqs = new ArrayList<>(); in getTopHeavyHitters() local
88 final List<Integer> tops = sketcher.getTopHeavyHitters(capacity - 1, null, freqs); in getTopHeavyHitters()
91 assertEquals(freqs.size(), tops.size()); in getTopHeavyHitters()
96 assertTrue(Math.abs(pair.second - freqs.get(i)) < EPSILON); in getTopHeavyHitters()
97 result.add(new Pair<>(tops.get(i), freqs.get(i))); in getTopHeavyHitters()
117 final float[] freqs) throws Exception {
130 assertTrue(Math.abs(freqs[i] - pair.second) < EPSILON);
/frameworks/base/core/java/com/android/internal/util/
DHeavyHitterSketch.java74 List<T> getTopHeavyHitters(int k, @Nullable List<T> holder, @Nullable List<Float> freqs); in getTopHeavyHitters() argument
254 final @Nullable List<Float> freqs) { in getTopHeavyHitters() argument
291 if (freqs != null) { in getTopHeavyHitters()
292 freqs.add((float) mFrequencies.valueAt(index) / mPassSize); in getTopHeavyHitters()
/frameworks/native/libs/cputimeinstate/
Dcputimeinstate.cpp114 std::vector<uint32_t> freqs; in initGlobals() local
120 freqs.insert(freqs.end(), nums->begin(), nums->end()); in initGlobals()
122 if (freqs.empty()) return false; in initGlobals()
123 std::sort(freqs.begin(), freqs.end()); in initGlobals()
124 gPolicyFreqs.emplace_back(freqs); in initGlobals()
126 for (auto freq : freqs) gAllFreqs.insert(freq); in initGlobals()
195 auto freqs = getCpuFreqs(); in isTrackingUidTimesSupported() local
196 if (!freqs || freqs->empty()) return false; in isTrackingUidTimesSupported()
Dtesttimeinstate.cpp564 auto freqs = getCpuFreqs(); in TEST_F() local
565 ASSERT_TRUE(freqs.has_value()); in TEST_F()
570 ASSERT_EQ(freqs->size(), times->size()); in TEST_F()
571 for (size_t i = 0; i < freqs->size(); ++i) EXPECT_EQ((*freqs)[i].size(), (*times)[i].size()); in TEST_F()
/frameworks/av/media/libaudiohal/impl/effectsAidlConversion/
DAidlConversionEq.cpp213 const auto& freqs = VALUE_OR_RETURN_STATUS(GET_PARAMETER_SPECIFIC_FIELD( in getParameter() local
215 if ((size_t)index >= freqs.size()) { in getParameter()
216 ALOGE("%s index %d exceed size %zu", __func__, index, freqs.size()); in getParameter()
219 return param.writeToValue(&freqs[index]); in getParameter()
/frameworks/base/wifi/java/src/android/net/wifi/nl80211/
DWifiNl80211Manager.java1079 @Nullable Set<Integer> freqs, @Nullable List<byte[]> hiddenNetworkSSIDs) { in startScan() argument
1080 return startScan(ifaceName, scanType, freqs, hiddenNetworkSSIDs, null); in startScan()
1088 @SuppressLint("NullableCollection") @Nullable Set<Integer> freqs, in startScan() argument
1096 SingleScanSettings settings = createSingleScanSettings(scanType, freqs, hiddenNetworkSSIDs, in startScan()
1132 @SuppressLint("NullableCollection") @Nullable Set<Integer> freqs, in startScan2() argument
1140 SingleScanSettings settings = createSingleScanSettings(scanType, freqs, hiddenNetworkSSIDs, in startScan2()
1155 @SuppressLint("NullableCollection") @Nullable Set<Integer> freqs, in createSingleScanSettings() argument
1172 if (freqs != null) { in createSingleScanSettings()
1173 for (Integer freq : freqs) { in createSingleScanSettings()
/frameworks/base/services/tests/powerstatstests/src/com/android/server/power/stats/
DCpuPowerStatsCollectorTest.java405 SparseArray<int[]> freqs = new SparseArray<>(); in mockCpuScalingPolicies() local
407 freqs.put(0, new int[]{300000, 1000000, 2000000}); in mockCpuScalingPolicies()
410 freqs.put(4, new int[]{300000, 1000000, 2500000, 3000000}); in mockCpuScalingPolicies()
412 mCpuScalingPolicies = new CpuScalingPolicies(cpus, freqs); in mockCpuScalingPolicies()
/frameworks/base/services/core/java/com/android/server/power/stats/
DCpuPowerCalculator.java85 int[] freqs = cpuScalingPolicies.getFrequencies(policy); in CpuPowerCalculator() local
87 new UsageBasedPowerEstimator[freqs.length]; in CpuPowerCalculator()
88 for (int step = 0; step < freqs.length; step++) { in CpuPowerCalculator()
DCpuPowerStatsProcessor.java225 int[] freqs = mCpuScalingPolicies.getFrequencies(policies[cluster]); in initEnergyConsumerToPowerBracketMaps() local
226 clusterToBrackets[cluster] = new ArraySet<>(freqs.length); in initEnergyConsumerToPowerBracketMaps()
227 for (int j = 0; j < freqs.length; j++) { in initEnergyConsumerToPowerBracketMaps()
DCpuPowerStatsCollector.java300 int[] freqs = mCpuScalingPolicies.getFrequencies(policy); in getCpuPowerBracketDescription() local
301 for (int step = 0; step < freqs.length; step++) { in getCpuPowerBracketDescription()
313 sb.append(freqs[step] / 1000); in getCpuPowerBracketDescription()
DBatteryStatsImpl.java11417 int[] freqs = mCpuScalingPolicies.getFrequencies(policies[i]); in initPowerProfile() local
11421 mKernelCpuSpeedReaders[i] = new KernelCpuSpeedReader(cpus[0], freqs.length); in initPowerProfile()
14503 final int[] freqs = mCpuScalingPolicies.getFrequencies(policies[cluster]);
14505 u.mCpuClusterSpeedTimesUs[cluster].length != freqs.length) {
14507 u.mCpuClusterSpeedTimesUs[cluster] = new LongSamplingCounter[freqs.length];
14510 mWakeLockAllocationsUs[cluster] = new long[freqs.length];
14513 for (int speed = 0; speed < freqs.length; ++speed) {
/frameworks/av/media/libeffects/dynamicsproc/aidl/
DDynamicsProcessingContext.cpp395 std::map<int, float> freqs; in validateBandConfig() local
405 if (freqs.find(band.band) != freqs.end()) { in validateBandConfig()
409 freqs[band.band] = band.cutoffFrequencyHz; in validateBandConfig()
/frameworks/av/media/libeffects/lvm/wrapper/Aidl/
DBundleContext.cpp461 std::vector<int32_t> freqs; in getEqualizerCenterFreqs() local
464 RETURN_VALUE_IF(LVM_SUCCESS != LVM_GetControlParameters(mInstance, &params), freqs, in getEqualizerCenterFreqs()
467 freqs.push_back((int32_t)params.pEQNB_BandDefinition[i].Frequency * 1000); in getEqualizerCenterFreqs()
470 return freqs; in getEqualizerCenterFreqs()
/frameworks/base/services/core/java/com/android/server/stats/pull/
DStatsPullAtomService.java1913 long[] freqs = KernelCpuBpfTracking.getFreqs();
1920 int freq = (int) freqs[freqIndex];
1970 long[] freqs = KernelCpuBpfTracking.getFreqs();
1971 double[] freqsPowers = new double[freqs.length];
1976 for (int freqIndex = 0; freqIndex < freqs.length; ++freqIndex, ++freqClusterIndex) {
2013 values[cluster * CPU_CYCLES_PER_UID_CLUSTER_VALUES] += freqs[freqIndex] * timeMs;
2143 long[] freqs = KernelCpuBpfTracking.getFreqs();
2147 aggregatedCycles[freqsClusters[i]] += freqs[i] * cpuTimesUs[i] / 1_000;
/frameworks/base/media/jni/
Dandroid_media_tv_Tuner.cpp1186 ScopedLocalRef freqs(env, env->NewLongArray(v.size())); in executeOnScanMessage() local
1187 env->SetLongArrayRegion(freqs.get(), 0, v.size(), reinterpret_cast<jlong *>(&v[0])); in executeOnScanMessage()
1189 freqs.get()); in executeOnScanMessage()