/frameworks/ml/nn/runtime/test/ |
D | TestFailingDriver.cpp | 75 DeviceManager* deviceManager = DeviceManager::get(); in SetUp() 77 !DeviceManager::partitioningAllowsFallback(deviceManager->getPartitioning())) { in SetUp() 81 DeviceManager::forTest_makeDriverDevice(kTestDriverName, new FailingTestDriver()); in SetUp() 84 DeviceManager::getCpuDevice(), in SetUp() 88 virtual void TearDown() { DeviceManager::get()->forTest_reInitializeDeviceList(); } in TearDown() 155 ASSERT_EQ(steps[1]->executionStep()->getDevice(), DeviceManager::getCpuDevice()); in TEST_F() 158 ASSERT_EQ(steps[3]->executionStep()->getDevice(), DeviceManager::getCpuDevice()); in TEST_F()
|
D | TestExtensions.cpp | 31 using DeviceManager = ::android::nn::DeviceManager; typedef 71 if (DeviceManager::get()->getUseCpuOnly()) { in SetUp() 75 DeviceManager::get()->forTest_registerDevice(kTestDriverName, new TestDriver()); in SetUp() 83 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown()
|
D | TestCompilationCaching.cpp | 324 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_P() 328 DeviceManager::get()->forTest_registerDevice(kDeviceName.data(), kDriver); in TEST_P() 330 [] { DeviceManager::get()->forTest_reInitializeDeviceList(); }); in TEST_P() 367 DeviceManager::get()->forTest_registerDevice(kDeviceName.data(), driver); in compileModel() 369 [] { DeviceManager::get()->forTest_reInitializeDeviceList(); }); in compileModel() 409 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_P() 426 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_P() 457 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_P()
|
D | TestIntrospectionControl.cpp | 48 using DeviceManager = nn::DeviceManager; typedef 116 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown() 139 DeviceManager::get()->forTest_registerDevice( in registerDevices() 224 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_F() 819 if (DeviceManager::get()->getUseCpuOnly() != (kDriverKind == DriverKind::CPU)) { in TEST_P() 831 const std::string& name = DeviceManager::get()->getDrivers()[0]->getName(); in TEST_P() 837 DeviceManager::get()->forTest_registerDevice(name, new TestDriver11(name, kSuccess)); in TEST_P() 843 DeviceManager::get()->forTest_registerDevice(name, new TestDriver13(name, kSuccess)); in TEST_P() 1147 if (DeviceManager::get()->getUseCpuOnly()) { in TEST_F() 1154 DeviceManager::get()->forTest_registerDevice(name, new TestDriver11(name, Success::PASS_BOTH)); in TEST_F() [all …]
|
D | TestMain.cpp | 72 android::nn::DeviceManager::get()->setUseCpuOnly(useCpuOnly); in test() 73 android::nn::DeviceManager::get()->setSyncExecHal(allowSyncExecHal); in test()
|
D | TestMemoryDomain.cpp | 172 if (DeviceManager::get()->getUseCpuOnly()) { in SetUp() 176 DeviceManager::get()->forTest_setDevices({}); in SetUp() 180 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown() 262 DeviceManager::get()->forTest_registerDevice(name, driver); in createAndRegisterDriver() 437 DeviceManager::get()->forTest_registerDevice("test_driver", driver); in TEST_F()
|
D | TestMemoryInternal.cpp | 68 mIsCpuOnly = android::nn::DeviceManager::get()->getUseCpuOnly(); in SetUp() 73 android::nn::DeviceManager::get()->setUseCpuOnly(mIsCpuOnly); in TearDown() 184 android::nn::DeviceManager::get()->setUseCpuOnly(true); in TEST_F()
|
D | TestRemoveDefaultArguments.cpp | 141 if (DeviceManager::get()->getUseCpuOnly()) { in SetUp() 145 DeviceManager::get()->forTest_registerDevice(kTestDriverName, mTestDriver); in SetUp() 150 virtual void TearDown() { DeviceManager::get()->forTest_reInitializeDeviceList(); } in TearDown()
|
D | TestExecution.cpp | 46 using DeviceManager = nn::DeviceManager; typedef 567 auto device = DeviceManager::forTest_makeDriverDevice( in TestCompilation() 579 c->setPartitioning(DeviceManager::kPartitioningWithoutFallback); in TestCompilation() 606 if (!DeviceManager::get()->getUseCpuOnly()) { in TestIntrospectionCompilation() 627 DeviceManager::get()->forTest_registerDevice(kName.c_str(), in ExecutionTestTemplate() 642 DeviceManager::get()->forTest_reInitializeDeviceList(); in TearDown() 698 if (kUseIntrospectionAPI && DeviceManager::get()->getUseCpuOnly()) { in TestWait()
|
D | TestPartitioningRandom.cpp | 95 using DeviceManager = nn::DeviceManager; typedef 1111 ASSERT_EQ(c.setPartitioning(DeviceManager::kPartitioningNo), Result::NO_ERROR); in TEST_P() 1153 auto device = DeviceManager::forTest_makeDriverDevice( in TEST_P() 1158 devices.push_back(DeviceManager::getCpuDevice()); in TEST_P() 1168 ASSERT_EQ(cNoFallback.setPartitioning(DeviceManager::kPartitioningWithoutFallback), in TEST_P() 1173 ASSERT_EQ(cWithFallback.setPartitioning(DeviceManager::kPartitioningWithFallback), in TEST_P() 1178 DeviceManager::getCpuDevice()); in TEST_P()
|
D | TestPartitioning.cpp | 151 using DeviceManager = ::android::nn::DeviceManager; typedef 1079 auto device = DeviceManager::forTest_makeDriverDevice(specification.mName, halDriver); in makeDevices() 1082 devices.push_back(DeviceManager::getCpuDevice()); in makeDevices() 1471 ASSERT_EQ(planC.forTest_simpleGetDevice(), DeviceManager::getCpuDevice()); in TEST_F() 1752 step1, &model1, DeviceManager::getCpuDevice(), in TEST_F() 1805 ASSERT_EQ(cPNo.setPartitioning(DeviceManager::kPartitioningNo), Result::NO_ERROR); in TEST_F() 1808 ASSERT_EQ(cPNo.getExecutionPlan().forTest_simpleGetDevice(), DeviceManager::getCpuDevice()); in TEST_F() 1818 ASSERT_EQ(cPWithFallback.setPartitioning(DeviceManager::kPartitioningWithFallback), in TEST_F() 1823 DeviceManager::getCpuDevice()); in TEST_F() 1828 ASSERT_EQ(cPWithoutFallback.setPartitioning(DeviceManager::kPartitioningWithoutFallback), in TEST_F() [all …]
|
/frameworks/ml/nn/runtime/ |
D | CompilationBuilder.cpp | 45 mPartitioning(explicitDeviceList ? DeviceManager::kPartitioningWithoutFallback in CompilationBuilder() 46 : DeviceManager::get()->getPartitioning()), in CompilationBuilder() 80 if (!DeviceManager::partitioningAllowsFallback(mPartitioning)) { in finish() 98 mPlan.becomeSingleStep(DeviceManager::getCpuDevice(), mModel); in finish()
|
D | TypeManager.h | 145 const DeviceManager* mDeviceManager = DeviceManager::get();
|
D | Manager.h | 120 class DeviceManager { 155 static DeviceManager* get(); 193 DeviceManager();
|
D | Manager.cpp | 402 const bool preferSynchronous = DeviceManager::get()->syncExecHal(); in execute() 794 if (!DeviceManager::get()->syncExecCpu()) { in execute() 810 DeviceManager* DeviceManager::get() { in get() 811 static DeviceManager manager; in get() 815 std::shared_ptr<Device> DeviceManager::getCpuDevice() { in getCpuDevice() 819 std::shared_ptr<Device> DeviceManager::forTest_makeDriverDevice(const std::string& name, in forTest_makeDriverDevice() 827 void DeviceManager::findAvailableDevices() { in findAvailableDevices() 845 void DeviceManager::registerDevice(const std::string& name, const DeviceFactory& makeDevice) { in registerDevice() 851 DeviceManager::DeviceManager() { in DeviceManager() function in android::nn::DeviceManager
|
D | ExecutionBuilder.cpp | 466 DeviceManager::getCpuDevice(), /*preparedModel=*/nullptr); in cpuFallbackFull() 770 const bool allowFallback = DeviceManager::partitioningAllowsFallback(mPartitioning); in computeFenced() 829 const bool allowFallback = DeviceManager::partitioningAllowsFallback(mPartitioning); in compute() 855 if (DeviceManager::get()->syncExecRuntime()) { in compute() 1064 return mDevice == DeviceManager::getCpuDevice(); in isCpu() 1129 mDevice = DeviceManager::getCpuDevice(); in computeOnCpuFallback()
|
D | NeuralNetworks.cpp | 625 *numDevices = DeviceManager::get()->getDrivers().size(); in ANeuralNetworks_getDeviceCount() 634 const std::vector<std::shared_ptr<Device>>& devices = DeviceManager::get()->getDrivers(); in ANeuralNetworks_getDevice() 740 const MetaModel metaModel(hidlModel, DeviceManager::get()->strictSlicing()); in ANeuralNetworksModel_getSupportedOperationsForDevices() 779 for (auto& device : DeviceManager::get()->getDrivers()) { in ANeuralNetworksCompilation_createForDevices() 1169 int result = m->createCompilation(&c, DeviceManager::get()->getDrivers()); in ANeuralNetworksCompilation_create()
|
D | ExecutionPlan.cpp | 1500 return isSimple() && simple()->mDevice == DeviceManager::getCpuDevice(); in isSimpleCpu() 1993 const MetaModel metaModel(makeHidlModel(), DeviceManager::get()->strictSlicing()); in findBestDeviceForEachOperation() 2013 std::find(devices.begin(), devices.end(), DeviceManager::getCpuDevice()); in findBestDeviceForEachOperation() 2027 (perfVal == bestPerfVal && device == DeviceManager::getCpuDevice())) { in findBestDeviceForEachOperation() 2046 } else if (devices[bestChoice] == DeviceManager::getCpuDevice() && in findBestDeviceForEachOperation()
|
/frameworks/ml/nn/runtime/test/fibonacci_extension/ |
D | FibonacciExtensionTest.cpp | 45 if (DeviceManager::get()->getUseCpuOnly()) { in SetUp() 53 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/ |
D | TestRandomGraph.cpp | 125 return DeviceManager::forTest_makeDriverDevice(T_TestDriver::name, new T_TestDriver); in makeTestDevice() 150 mStandardDevices = DeviceManager::get()->forTest_getDevices(); in SetUpTestCase() 407 DeviceManager::get()->forTest_setDevices(mSyntheticDevices); in testRandomGraph() 409 DeviceManager::get()->forTest_setDevices(mStandardDevices); in testRandomGraph()
|