You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Sylvain Lebresne (JIRA)" <ji...@apache.org> on 2015/09/22 17:52:04 UTC

[jira] [Commented] (CASSANDRA-10378) Make skipping more efficient

    [ https://issues.apache.org/jira/browse/CASSANDRA-10378?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14902832#comment-14902832 ] 

Sylvain Lebresne commented on CASSANDRA-10378:
----------------------------------------------

I wonder if a simple solution wouldn't be to store the size of the row as first thing after the clustering so we can skip it all easily. We can do it only for sstable and using a vint, it will almost
always cost us just 1 byte and since, as you say, we do a shitload of row skipping within an index block so it might be worth it.

> Make skipping more efficient
> ----------------------------
>
>                 Key: CASSANDRA-10378
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-10378
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Benedict
>            Assignee: Benedict
>             Fix For: 3.x
>
>
> Following on from the impact of CASSANDRA-10322, we can improve the efficiency of our calls to skipping methods. CASSANDRA-10326 is showing our performance to be in-and-around the same ballpark except for seeks into the middle of a large partition, which suggests (possibly) that the higher density of data we're storing may simply be resulting in a more significant CPU burden as we have more data to skip over (and since CASSANDRA-10322 improves performance here really dramatically, further improvements are likely to be of similar benefit).
> I propose doing our best to flatten the skipping of macro data items into as few skip invocations as necessary. One way of doing this would be to introduce a special {{skipUnsignedVInts(int)}} method, that can efficiently skip a number of unsigned vints. Almost the entire body of a cell and row consist of vints now, each data component with their own special {{skipX}} method that invokes {{readUnsignedVint}}. This would permit more efficient despatch.
> We could also potentially avoid the construction of a new {{Columns}} instance for each row skip, since all we need is an iterator over the columns, and share the temporary space used for storing them, which should further reduce the GC burden for skipping many rows.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)