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

Function GetDriverExecutor

tensorflow/stream_executor/cuda/cuda_driver.cc:105–109  ·  view source on GitHub ↗

CUDA driver routines may require a large amount of stack (particularly cuModuleLoadDataEx, in our experience). To avoid stack overflow when using stack-limited threads (such as those spawned by a default-argument thread::ThreadPool on some platforms), we run certain routines in this pool and wait for completion.

Source from the content-addressed store, hash-verified

103// thread::ThreadPool on some platforms), we run certain routines in this pool
104// and wait for completion.
105port::ThreadPool* GetDriverExecutor() {
106 static port::ThreadPool* thread_pool = new port::ThreadPool(
107 port::Env::Default(), port::ThreadOptions(), "cuda_driver", 1);
108 return thread_pool;
109}
110
111} // namespace
112

Callers 1

LoadPtxMethod · 0.70

Calls 2

DefaultFunction · 0.85
ThreadOptionsClass · 0.85

Tested by

no test coverage detected