| 37 | } |
| 38 | |
| 39 | OpKernelInferCache::ValueType OpKernelInferCache::GetCacheValue() const { |
| 40 | size_t hash_value = std::hash<KeyType>()(cache_key_); |
| 41 | HashEqTraitPtr<const KeyType> ptr_wrapper(&cache_key_, hash_value); |
| 42 | CHECK(cached_key2value_.find(ptr_wrapper) != cached_key2value_.end()); |
| 43 | return cached_key2value_.at(ptr_wrapper); |
| 44 | } |
| 45 | |
| 46 | void OpKernelInferCache::UpdateCacheKey(KernelInferContext* ctx) { |
| 47 | auto GetSymbolOfShape = [&](const std::string& arg_name, int32_t arg_index) -> Symbol<Shape> { |
no test coverage detected