Home
last modified time | relevance | path

Searched refs:DeviceManager (Results 1 – 17 of 17) sorted by relevance

/frameworks/ml/nn/runtime/
DCompilationBuilder.cpp36 mPartitioning(explicitDeviceList ? DeviceManager::kPartitioningWithoutFallback in CompilationBuilder()
37 : DeviceManager::get()->getPartitioning()), in CompilationBuilder()
69 if (!DeviceManager::partitioningAllowsFallback(mPartitioning)) { in finish()
87 mPlan.becomeSingleStep(DeviceManager::getCpuDevice(), mModel); in finish()
DManager.cpp359 DeviceManager* DeviceManager::get() { in get()
360 static DeviceManager manager; in get()
364 std::shared_ptr<Device> DeviceManager::getCpuDevice() { in getCpuDevice()
368 std::shared_ptr<Device> DeviceManager::forTest_makeDriverDevice(const std::string& name, in forTest_makeDriverDevice()
375 void DeviceManager::findAvailableDevices() { in findAvailableDevices()
402 void DeviceManager::registerDevice(const char* name, const sp<V1_0::IDevice>& device) { in registerDevice()
409 DeviceManager::DeviceManager() { in DeviceManager() function in android::nn::DeviceManager
DManager.h82 class DeviceManager {
121 static DeviceManager* get();
158 DeviceManager();
DTypeManager.h136 const DeviceManager* mDeviceManager = DeviceManager::get();
DExecutionBuilder.cpp387 DeviceManager::getCpuDevice(), /*preparedModel=*/nullptr); in cpuFallbackFull()
567 const bool allowFallback = DeviceManager::partitioningAllowsFallback(mPartitioning); in compute()
591 if (DeviceManager::get()->syncExecRuntime()) { in compute()
927 if (DeviceManager::get()->syncExecHal()) { in startComputeOnDevice()
1055 if (DeviceManager::get()->syncExecCpu()) { in startComputeOnCpu()
DNeuralNetworks.cpp558 *numDevices = DeviceManager::get()->getDrivers().size(); in ANeuralNetworks_getDeviceCount()
567 const std::vector<std::shared_ptr<Device>>& devices = DeviceManager::get()->getDrivers(); in ANeuralNetworks_getDevice()
704 for (auto& device : DeviceManager::get()->getDrivers()) { in ANeuralNetworksCompilation_createForDevices()
985 int result = m->createCompilation(&c, DeviceManager::get()->getDrivers()); in ANeuralNetworksCompilation_create()
DExecutionPlan.cpp1217 if (DeviceManager::get()->strictSlicing()) { in invalid()
1235 CHECK(!DeviceManager::get()->strictSlicing()); in invalid()
1579 (perfVal == bestPerfVal && device == DeviceManager::getCpuDevice())) { in findBestDeviceForEachOperation()
/frameworks/ml/nn/runtime/test/
DTestExtensions.cpp28 using DeviceManager = ::android::nn::DeviceManager; typedef
67 if (DeviceManager::get()->getUseCpuOnly()) { in SetUp()
71 DeviceManager::get()->forTest_registerDevice(kTestDriverName, new TestDriver()); in SetUp()
79 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown()
DTestMain.cpp60 android::nn::DeviceManager::get()->setUseCpuOnly(useCpuOnly); in test()
61 android::nn::DeviceManager::get()->setSyncExecHal(allowSyncExecHal); in test()
DTestExecution.cpp38 using DeviceManager = nn::DeviceManager; typedef
320 auto device = DeviceManager::forTest_makeDriverDevice( in TestCompilation()
332 c->setPartitioning(DeviceManager::kPartitioningWithoutFallback); in TestCompilation()
359 if (!DeviceManager::get()->getUseCpuOnly()) { in TestIntrospectionCompilation()
380 DeviceManager::get()->forTest_registerDevice(kName.c_str(), in ExecutionTestTemplate()
395 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown()
450 if (kUseIntrospectionAPI && DeviceManager::get()->getUseCpuOnly()) { in TestWait()
DTestIntrospectionControl.cpp41 using DeviceManager = nn::DeviceManager; typedef
105 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown()
124 DeviceManager::get()->forTest_registerDevice( in registerDevices()
209 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_F()
542 if (DeviceManager::get()->getUseCpuOnly() != (kDriverKind == DriverKind::CPU)) { in TEST_P()
554 const char* name = DeviceManager::get()->getDrivers()[0]->getName(); in TEST_P()
560 DeviceManager::get()->forTest_registerDevice(name, new TestDriver11(name, kSuccess)); in TEST_P()
566 DeviceManager::get()->forTest_registerDevice(name, new TestDriver12(name, kSuccess)); in TEST_P()
760 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_F()
790 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_F()
[all …]
DTestCompilationCaching.cpp264 DeviceManager::get()->forTest_registerDevice(kDeviceName, driver); in compileModel()
295 DeviceManager::get()->forTest_reInitializeDeviceList(); in compileModel()
316 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_P()
334 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_P()
365 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_P()
DTestMemoryInternal.cpp68 mIsCpuOnly = android::nn::DeviceManager::get()->getUseCpuOnly(); in SetUp()
73 android::nn::DeviceManager::get()->setUseCpuOnly(mIsCpuOnly); in TearDown()
231 android::nn::DeviceManager::get()->setUseCpuOnly(true); in TEST_F()
DTestPartitioningRandom.cpp94 using DeviceManager = nn::DeviceManager; typedef
1060 ASSERT_EQ(c.setPartitioning(DeviceManager::kPartitioningNo), Result::NO_ERROR); in TEST_P()
1102 auto device = DeviceManager::forTest_makeDriverDevice( in TEST_P()
1107 devices.push_back(DeviceManager::getCpuDevice()); in TEST_P()
1117 ASSERT_EQ(cNoFallback.setPartitioning(DeviceManager::kPartitioningWithoutFallback), in TEST_P()
1122 ASSERT_EQ(cWithFallback.setPartitioning(DeviceManager::kPartitioningWithFallback), in TEST_P()
1127 DeviceManager::getCpuDevice()); in TEST_P()
DTestPartitioning.cpp137 using DeviceManager = ::android::nn::DeviceManager; typedef
817 auto device = DeviceManager::forTest_makeDriverDevice(specification.mName, halDriver); in makeDevices()
820 devices.push_back(DeviceManager::getCpuDevice()); in makeDevices()
1208 ASSERT_EQ(planC.forTest_simpleGetDevice(), DeviceManager::getCpuDevice()); in TEST_F()
1462 step1, &model1, DeviceManager::getCpuDevice(), in TEST_F()
1516 ASSERT_EQ(cPNo.setPartitioning(DeviceManager::kPartitioningNo), Result::NO_ERROR); in TEST_F()
1519 ASSERT_EQ(cPNo.getExecutionPlan().forTest_simpleGetDevice(), DeviceManager::getCpuDevice()); in TEST_F()
1529 …ASSERT_EQ(cPWithFallback.setPartitioning(DeviceManager::kPartitioningWithFallback), Result::NO_ERR… in TEST_F()
1533 DeviceManager::getCpuDevice()); in TEST_F()
1538 …ASSERT_EQ(cPWithoutFallback.setPartitioning(DeviceManager::kPartitioningWithoutFallback), Result::… in TEST_F()
/frameworks/ml/nn/runtime/test/fibonacci_extension/
DFibonacciExtensionTest.cpp44 if (DeviceManager::get()->getUseCpuOnly()) { in SetUp()
52 DeviceManager::get()->forTest_registerDevice(sample_driver::FibonacciDriver::kDriverName, in SetUp()
72 } else if (DeviceManager::get()->forTest_isCpuDevice(device)) { in SetUp()
89 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown()
/frameworks/ml/nn/runtime/test/fuzzing/
DTestRandomGraph.cpp113 return DeviceManager::forTest_makeDriverDevice(T_TestDriver::name, new T_TestDriver); in makeTestDevice()
151 mStandardDevices = DeviceManager::get()->forTest_getDevices(); in SetUpTestCase()
342 DeviceManager::get()->forTest_setDevices(mSyntheticDevices); in testRandomGraph()
344 DeviceManager::get()->forTest_setDevices(mStandardDevices); in testRandomGraph()