You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Adar Dembo (Code Review)" <ge...@cloudera.org> on 2019/05/01 05:26:35 UTC

[kudu-CR] [util] modernize signature of Cache interface methods

Adar Dembo has posted comments on this change. ( http://gerrit.cloudera.org:8080/13175 )

Change subject: [util] modernize signature of Cache interface methods
......................................................................


Patch Set 2:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/13175/2/src/kudu/codegen/code_cache.cc
File src/kudu/codegen/code_cache.cc:

http://gerrit.cloudera.org:8080/#/c/13175/2/src/kudu/codegen/code_cache.cc@83
PS2, Line 83:   memcpy(cache_->MutableValue(&pending), &val, val_len);
Right, I misunderstood and forgot MutableValue and friends expected pointers to the std::unique_ptr.

> So, what's the verdict?  Keep Handle and PendingHandle in the signature of methods in the Cache's interface because we don't want to incur overhead due to passing around references/pointers to UniqueHandle/UniquePendingHandle?

You tell me. :) Is there overhead to passing them around? I don't believe there is, but maybe they overload their operators in a surprising way.



-- 
To view, visit http://gerrit.cloudera.org:8080/13175
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I31518cdfa269e6806aa5dda180956896d8cb3404
Gerrit-Change-Number: 13175
Gerrit-PatchSet: 2
Gerrit-Owner: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Comment-Date: Wed, 01 May 2019 05:26:35 +0000
Gerrit-HasComments: Yes