MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / BM_NAME

Function BM_NAME

tensorflow/compiler/aot/test.cc:73–88  ·  view source on GitHub ↗

Simple benchmark that repeatedly runs the generated function.

Source from the content-addressed store, hash-verified

71
72// Simple benchmark that repeatedly runs the generated function.
73void BM_NAME(int iters) {
74 testing::StopTiming();
75
76 Eigen::ThreadPool pool(port::MaxParallelism());
77 Eigen::ThreadPoolDevice device(&pool, pool.NumThreads());
78
79 CPP_CLASS computation;
80 computation.set_thread_pool(&device);
81 zero_buffers(&computation);
82
83 testing::StartTiming();
84 while (--iters) {
85 computation.Run();
86 }
87 testing::StopTiming();
88}
89BENCHMARK(BM_NAME);
90
91} // namespace

Callers

nothing calls this directly

Calls 7

StopTimingFunction · 0.85
zero_buffersFunction · 0.85
StartTimingFunction · 0.85
set_thread_poolMethod · 0.80
MaxParallelismFunction · 0.50
NumThreadsMethod · 0.45
RunMethod · 0.45

Tested by

no test coverage detected