|
|
|
@ -520,7 +520,10 @@ class MKLDNNDeviceContext : public CPUDeviceContext {
|
|
|
|
const mkldnn::engine& GetEngine() const { return engine_; }
|
|
|
|
const mkldnn::engine& GetEngine() const { return engine_; }
|
|
|
|
|
|
|
|
|
|
|
|
// Remove all entries from the blob map
|
|
|
|
// Remove all entries from the blob map
|
|
|
|
void ResetBlobMap() const;
|
|
|
|
void ResetBlobMap();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Prevent next ResetBlobMap()
|
|
|
|
|
|
|
|
void BlockNextCacheClearing();
|
|
|
|
|
|
|
|
|
|
|
|
// Get the ShapeBlob size in cur_mkldnn_session_id.
|
|
|
|
// Get the ShapeBlob size in cur_mkldnn_session_id.
|
|
|
|
size_t GetShapeBlobSize() const;
|
|
|
|
size_t GetShapeBlobSize() const;
|
|
|
|
@ -539,6 +542,7 @@ class MKLDNNDeviceContext : public CPUDeviceContext {
|
|
|
|
mkldnn::engine engine_;
|
|
|
|
mkldnn::engine engine_;
|
|
|
|
std::shared_ptr<BlobMap> p_blobmap_;
|
|
|
|
std::shared_ptr<BlobMap> p_blobmap_;
|
|
|
|
std::shared_ptr<std::mutex> p_mutex_;
|
|
|
|
std::shared_ptr<std::mutex> p_mutex_;
|
|
|
|
|
|
|
|
bool block_next_cache_clearing_ = false;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
|