Skip to content

Commit

Permalink
update (microsoft#10573)
Browse files Browse the repository at this point in the history
Move FuncMgr up the class so it is destroyed later
  • Loading branch information
snnn authored Feb 17, 2022
1 parent 4f76c38 commit 09ac759
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion onnxruntime/core/framework/session_state.h
Original file line number Diff line number Diff line change
@@ -396,6 +396,9 @@ class SessionState {
// KernelCreateInfo for each node so we do kernel lookup once
KernelCreateInfoMap kernel_create_info_map_;

//fused_funcs_mgr_ must live longer than the session_kernels_, becaues a kernel could be created from this manager
FuncManager fused_funcs_mgr_;

// If we compile kernels in a minimal build we need a way to find the kernel using the hash.
// We populate this map when doing the kernel compilation in GraphPartitioner, and use it in LoadFromOrtFormat.
std::unordered_map<std::string, HashValue> compiled_kernel_hashes_;
@@ -485,7 +488,6 @@ class SessionState {
concurrency::ThreadPool* const inter_op_thread_pool_{};

bool export_fused_dll_ = false;
FuncManager fused_funcs_mgr_;
const DataTransferManager& data_transfer_mgr_;

bool use_deterministic_compute_;

0 comments on commit 09ac759

Please sign in to comment.