MCPcopy Create free account
hub / github.com/Oneflow-Inc/oneflow / InitEagerCclOpKernelCache

Function InitEagerCclOpKernelCache

oneflow/user/kernels/eager_ccl_kernel.cpp:97–102  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

95};
96
97void InitEagerCclOpKernelCache(user_op::KernelCacheContext* ctx,
98 std::shared_ptr<user_op::OpKernelCache>* cache_ptr) {
99 // NOTE(jianhao): the cache only depends on parallel_conf, and the kernel is singleton
100 // once parallel_conf is determined, so only init the cache at the first time.
101 if (*cache_ptr == nullptr) { *cache_ptr = std::make_shared<EagerCclOpKernelCache>(ctx); }
102}
103
104} // namespace
105

Calls

no outgoing calls

Tested by

no test coverage detected