| 356 | } |
| 357 | ~ShardedLRUCache() override {} |
| 358 | Handle* Insert(const Slice& key, void* value, size_t charge, |
| 359 | void (*deleter)(const Slice& key, void* value)) override { |
| 360 | const uint32_t hash = HashSlice(key); |
| 361 | return shard_[Shard(hash)].Insert(key, hash, value, charge, deleter); |
| 362 | } |
| 363 | Handle* Lookup(const Slice& key) override { |
| 364 | const uint32_t hash = HashSlice(key); |
| 365 | return shard_[Shard(hash)].Lookup(key, hash); |