You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@druid.apache.org by GitBox <gi...@apache.org> on 2019/11/06 21:32:54 UTC

[GitHub] [incubator-druid] clintropolis commented on a change in pull request #8822: optimize numeric column null value checking for low filter selectivity (more rows)

clintropolis commented on a change in pull request #8822: optimize numeric column null value checking for low filter selectivity (more rows)
URL: https://github.com/apache/incubator-druid/pull/8822#discussion_r343338943
 
 

 ##########
 File path: processing/src/main/java/org/apache/druid/segment/data/ColumnarDoubles.java
 ##########
 @@ -94,10 +95,20 @@ public void inspectRuntimeShape(RuntimeShapeInspector inspector)
     } else {
       class HistoricalDoubleColumnSelectorWithNulls implements DoubleColumnSelector, HistoricalColumnSelector<Double>
       {
+        private final PeekableIntIterator nullIterator = nullValueBitmap.peekableIterator();
+        private int nullMark = -1;
+
         @Override
         public boolean isNull()
         {
-          return nullValueBitmap.get(offset.getOffset());
+          final int i = offset.getOffset();
+          if (nullMark < i) {
 
 Review comment:
   This is a good point, I forgot about reset, will fix (hopefully without adding too many extra instructions since this is called in a hot loop :cry:)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@druid.apache.org
For additional commands, e-mail: commits-help@druid.apache.org