You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@kudu.apache.org by "Todd Lipcon (JIRA)" <ji...@apache.org> on 2017/03/20 02:57:41 UTC
[jira] [Commented] (KUDU-1712) Schema::EncodeComparableKey burns
CPU in compaction
[ https://issues.apache.org/jira/browse/KUDU-1712?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15932097#comment-15932097 ]
Todd Lipcon commented on KUDU-1712:
-----------------------------------
https://gerrit.cloudera.org/#/c/6431/ has an improvement in this area to at least avoid the 'div' instruction, though still caching or codegen is probably preferable.
> Schema::EncodeComparableKey burns CPU in compaction
> ---------------------------------------------------
>
> Key: KUDU-1712
> URL: https://issues.apache.org/jira/browse/KUDU-1712
> Project: Kudu
> Issue Type: Bug
> Components: perf, tablet
> Affects Versions: 1.0.1
> Reporter: Todd Lipcon
>
> Looking at a workload that is CPU-bound in compaction, the top CPU consumer is kudu::GetKeyEncoder<kudu::faststring>(kudu::TypeInfo const*). This is called for every _cell_ that is part of the compound key, and is quite expensive since it involves a 'div' instruction.
> A very easy win would be to pre-cache the key encoder objects for each of the columns in the schema. A less-easy but probably bigger win would be to codegen the comparable key encoder for the schema.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)