| 53 | #endif |
| 54 | static std::once_flag s_flag; |
| 55 | void registerBackend() { |
| 56 | std::call_once(s_flag, [&]() { |
| 57 | #ifdef MNN_INTERNAL_ENABLED |
| 58 | LogInit(); |
| 59 | #endif |
| 60 | registerCPURuntimeCreator(); |
| 61 | #ifndef MNN_SKIPBUILD_GEOMETRY |
| 62 | SizeComputerSuite::init(); |
| 63 | GeometryComputer::init(); |
| 64 | #endif |
| 65 | #if MNN_COREML_ENABLED |
| 66 | registerCoreMLRuntimeCreator(); |
| 67 | #endif |
| 68 | #ifdef MNN_NNAPI_ENABLED |
| 69 | registerNNAPIRuntimeCreator(); |
| 70 | #endif |
| 71 | #if MNN_QNN_ENABLED |
| 72 | registerQNNRuntimeCreator(); |
| 73 | #endif |
| 74 | #if MNN_OPENCL_ENABLED |
| 75 | OpenCL::registerOpenCLRuntimeCreator(); |
| 76 | #endif |
| 77 | #if MNN_METAL_ENABLED |
| 78 | registerMetalRuntimeCreator(); |
| 79 | #endif |
| 80 | #ifdef MNN_NEUROPILOT |
| 81 | registerNeuroPilot(); |
| 82 | #endif |
| 83 | }); |
| 84 | } |
| 85 | |
| 86 | const RuntimeCreator* MNNGetExtraRuntimeCreator(MNNForwardType type) { |
| 87 | registerBackend(); |
no test coverage detected