MCPcopy Create free account
hub / github.com/alibaba/MNN / run

Method run

test/expr/ExecutorScopeMultiThreadTest.cpp:18–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

16class ExecutorScopeMultiThreadTest : public MNNTestCase {
17public:
18 virtual bool run(int precision) {
19 std::vector<std::thread> threads;
20 for (int i = 0; i < 4; ++i) {
21 threads.emplace_back([&]() {
22 ExecutorScope scope(ExecutorScope::Current());
23 });
24 }
25 for (auto& t : threads) {
26 t.join();
27 }
28 return true;
29 }
30};
31
32MNNTestSuiteRegister(ExecutorScopeMultiThreadTest, "expr/ExecutorScopeMultiThread");

Callers

nothing calls this directly

Calls 1

joinMethod · 0.80

Tested by

no test coverage detected