File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -1590,7 +1590,7 @@ void AnalysisPredictor::MkldnnPreSet(
15901590 if (config_.onednn_cache_capacity_ > 0 ) {
15911591 VLOG (2 ) << " In mkldnn cache clear mode." ;
15921592 phi::OneDNNContext::tls ().set_cur_mkldnn_session_id (
1593- phi::OneDNNContextThreadLocals::kMKLDNNSessionID_CacheClearing );
1593+ phi::OneDNNContextThreadLocals::kONEDNNSessionID_CacheClearing );
15941594 // Set current_input_shape for caching dynamic shape.
15951595 std::stringstream ss;
15961596 for (const auto &input_shape : inputs_shape) {
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ namespace phi {
2727
2828OneDNNContextThreadLocals::Body::Body ()
2929 : cur_engine(dnnl::engine::kind::cpu, 0 ), cur_stream(cur_engine) {
30- cur_mkldnn_session_id = kMKLDNNSessionID_Default ;
30+ cur_mkldnn_session_id = kONEDNNSessionID_Default ;
3131 cur_input_shape_str = " " ;
3232 cur_input_shape_cache_capacity = 1 ;
3333 cur_paddle_data_layout = DataLayout::kNCHW ;
@@ -208,7 +208,7 @@ struct OneDNNContext::Impl {
208208 // In cache clearing mode, cur_input_shape_cache_capacity defines
209209 // max pblob capacity
210210 if ((static_cast <size_t >(sid) ==
211- OneDNNContextThreadLocals::kMKLDNNSessionID_CacheClearing ) &&
211+ OneDNNContextThreadLocals::kONEDNNSessionID_CacheClearing ) &&
212212 !sBlob ->empty () &&
213213 (sBlob ->size () >=
214214 static_cast <size_t >(
Original file line number Diff line number Diff line change @@ -74,9 +74,9 @@ class OneDNNContextThreadLocals {
7474
7575 public:
7676 // default onednn session id
77- static constexpr size_t kMKLDNNSessionID_Default = 0 ;
77+ static constexpr size_t kONEDNNSessionID_Default = 0 ;
7878 // onednn session id for cache clearing mode
79- static constexpr size_t kMKLDNNSessionID_CacheClearing = -1 ;
79+ static constexpr size_t kONEDNNSessionID_CacheClearing = -1 ;
8080 TEST_API static Body& fetch ();
8181};
8282
You can’t perform that action at this time.
0 commit comments