Hello Adar Dembo,

I'd like you to do a code review. Please visit

    http://gerrit.cloudera.org:8080/15064

to review the following change.


Change subject: schema: use dense_hash_map instead of std::unordered_map
......................................................................

schema: use dense_hash_map instead of std::unordered_map

In a time series benchmark I'm working on, the client spent 12% of its
CPU in Schema::FindColumn. In particular, most of the CPU went to the
bucket calculation in std::unordered_map, which required a 'divq'
instruction that can take hundreds of cycles.

This switches Schema to use a dense_hash_map instead which performs
better. After this change, the percent of CPU used by my benchmark
worker thread in Schema::FindColumn dropped from ~12% to ~1.5% which
resulted in a few percent overall throughput increase.

Change-Id: I8e8f80229b2dcfad05e204a6f6e50ce7dc3f4c73
---
M src/kudu/common/schema.cc
M src/kudu/common/schema.h
2 files changed, 9 insertions(+), 5 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/64/15064/1
--
To view, visit http://gerrit.cloudera.org:8080/15064
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I8e8f80229b2dcfad05e204a6f6e50ce7dc3f4c73
Gerrit-Change-Number: 15064
Gerrit-PatchSet: 1
Gerrit-Owner: Todd Lipcon <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>

Reply via email to