From 47a09b0a88b1f1f52086aa7dc78be09c8ed2c905 Mon Sep 17 00:00:00 2001 From: Maysam Yabandeh Date: Mon, 1 May 2017 17:43:52 -0700 Subject: [PATCH] Avoid pinning when row cache is accessed Summary: With row cache being enabled, table cache is doing a short circuit for reading data. This path needs to be updated to take advantage of pinnable slice. In the meanwhile we disabling pinning in this path. Closes https://github.com/facebook/rocksdb/pull/2237 Differential Revision: D4982389 Pulled By: maysamyabandeh fbshipit-source-id: 542630d0cf23cfb1f0c397da82e7053df7966591 --- table/get_context.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/table/get_context.cc b/table/get_context.cc index cbee89038..9532f3654 100644 --- a/table/get_context.cc +++ b/table/get_context.cc @@ -182,7 +182,6 @@ bool GetContext::SaveValue(const ParsedInternalKey& parsed_key, void replayGetContextLog(const Slice& replay_log, const Slice& user_key, GetContext* get_context) { #ifndef ROCKSDB_LITE - static Cleanable nonToClean; Slice s = replay_log; while (s.size()) { auto type = static_cast(*s.data()); @@ -195,8 +194,7 @@ void replayGetContextLog(const Slice& replay_log, const Slice& user_key, // Since SequenceNumber is not stored and unknown, we will use // kMaxSequenceNumber. get_context->SaveValue( - ParsedInternalKey(user_key, kMaxSequenceNumber, type), value, - &nonToClean); + ParsedInternalKey(user_key, kMaxSequenceNumber, type), value, nullptr); } #else // ROCKSDB_LITE assert(false);