You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by bi...@apache.org on 2018/10/25 23:18:09 UTC

[1/4] impala git commit: IMPALA-7351: Add estimates to Exchange node

Repository: impala
Updated Branches:
  refs/heads/master 1d72c7584 -> 8cbec20ea


http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-query/queries/QueryTest/explain-level2.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-query/queries/QueryTest/explain-level2.test b/testdata/workloads/functional-query/queries/QueryTest/explain-level2.test
index aa67453..5abb80b 100644
--- a/testdata/workloads/functional-query/queries/QueryTest/explain-level2.test
+++ b/testdata/workloads/functional-query/queries/QueryTest/explain-level2.test
@@ -9,39 +9,39 @@ row_regex:.*Max Per-Host Resource Reservation: Memory=[0-9.]*MB Threads=[0-9]*.*
 row_regex:.*Per-Host Resource Estimates: Memory=[0-9.]*MB.*
 ''
 'F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1'
-'|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1'
+row_regex:.*|  Per-Host Resources: mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=1
 'PLAN-ROOT SINK'
-'|  mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*|  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '|'
 '04:EXCHANGE [UNPARTITIONED]'
-'|  mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*|  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '|  tuple-ids=0,1 row-size=454B cardinality=5757710'
 '|  in pipelines: 00(GETNEXT)'
 '|'
 'F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3'
-row_regex:.*Per-Host Resources: mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=.*
+row_regex:.*Per-Host Resources: mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=.*
 '02:HASH JOIN [INNER JOIN, BROADCAST]'
 '|  hash predicates: l_orderkey = o_orderkey'
 '|  fk/pk conjuncts: l_orderkey = o_orderkey'
 '|  runtime filters: RF000[bloom] <- o_orderkey'
-row_regex:.*|  mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB spill-buffer=[0-9.]*MB thread-reservation=0.*
+row_regex:.*|  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B spill-buffer=[0-9.]*MB thread-reservation=0.*
 '|  tuple-ids=0,1 row-size=454B cardinality=5757710'
 '|  in pipelines: 00(GETNEXT), 01(OPEN)'
 '|'
 '|--03:EXCHANGE [BROADCAST]'
-'|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*|  |  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '|  |  tuple-ids=1 row-size=191B cardinality=1500000'
 '|  |  in pipelines: 01(GETNEXT)'
 '|  |'
 '|  F01:PLAN FRAGMENT [RANDOM] hosts=2 instances=2'
-row_regex:.*|  Per-Host Resources: mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=.*
+row_regex:.*|  Per-Host Resources: mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=.*
 '|  01:SCAN HDFS [tpch.orders, RANDOM]'
 row_regex:.*partitions=1/1 files=1 size=.*
 '|     stored statistics:'
 row_regex:.*table: rows=1500000 size=.*
 '|       columns: all'
 row_regex:.*|     extrapolated-rows=disabled max-scan-range-rows=[0-9]*.*
-row_regex:.*|     mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=1.*
+row_regex:.*|     mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=1.*
 '|     tuple-ids=1 row-size=191B cardinality=1500000'
 '|     in pipelines: 01(GETNEXT)'
 '|'
@@ -52,7 +52,7 @@ row_regex:.*partitions=1/1 files=1 size=.*
 row_regex:.*table: rows=6001215 size=.*
 '     columns: all'
 row_regex:.*   extrapolated-rows=disabled max-scan-range-rows=[0-9]*.*
-row_regex:.*   mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=1.*
+row_regex:.*   mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=1.*
 '   tuple-ids=0 row-size=263B cardinality=6001215'
 '   in pipelines: 00(GETNEXT)'
 ====

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-query/queries/QueryTest/explain-level3.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-query/queries/QueryTest/explain-level3.test b/testdata/workloads/functional-query/queries/QueryTest/explain-level3.test
index f199f4e..9ac5698 100644
--- a/testdata/workloads/functional-query/queries/QueryTest/explain-level3.test
+++ b/testdata/workloads/functional-query/queries/QueryTest/explain-level3.test
@@ -9,29 +9,29 @@ row_regex:.*Max Per-Host Resource Reservation: Memory=[0-9.]*MB Threads=[0-9]*.*
 row_regex:.*Per-Host Resource Estimates: Memory=[0-9.]*MB.*
 ''
 'F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1'
-'Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1'
+row_regex:.*Per-Host Resources: mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=1
 '  PLAN-ROOT SINK'
-'  |  mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*  |  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '  |'
 '  04:EXCHANGE [UNPARTITIONED]'
-'     mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*     mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '     tuple-ids=0,1 row-size=454B cardinality=5757710'
 '     in pipelines: 00(GETNEXT)'
 ''
 'F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3'
-row_regex:.*Per-Host Resources: mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=.*
+row_regex:.*Per-Host Resources: mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=.*
 '  DATASTREAM SINK [FRAGMENT=F02, EXCHANGE=04, UNPARTITIONED]'
-'  |  mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*  |  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '  02:HASH JOIN [INNER JOIN, BROADCAST]'
 '  |  hash predicates: l_orderkey = o_orderkey'
 '  |  fk/pk conjuncts: l_orderkey = o_orderkey'
 '  |  runtime filters: RF000[bloom] <- o_orderkey'
-row_regex:.*  |  mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB spill-buffer=[0-9.]*MB thread-reservation=.*
+row_regex:.*  |  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B spill-buffer=[0-9.]*MB thread-reservation=.*
 '  |  tuple-ids=0,1 row-size=454B cardinality=5757710'
 '  |  in pipelines: 00(GETNEXT), 01(OPEN)'
 '  |'
 '  |--03:EXCHANGE [BROADCAST]'
-'  |     mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*  |     mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '  |     tuple-ids=1 row-size=191B cardinality=1500000'
 '  |     in pipelines: 01(GETNEXT)'
 '  |'
@@ -42,21 +42,21 @@ row_regex:.*partitions=1/1 files=1 size=.*
 row_regex:.*table: rows=6001215 size=.*
 '       columns: all'
 row_regex:.*|     extrapolated-rows=disabled max-scan-range-rows=[0-9]*.*
-row_regex:.*     mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=1.*
+row_regex:.*     mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=1.*
 '     tuple-ids=0 row-size=263B cardinality=6001215'
 '     in pipelines: 00(GETNEXT)'
 ''
 'F01:PLAN FRAGMENT [RANDOM] hosts=2 instances=2'
-row_regex:.*Per-Host Resources: mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=.*
+row_regex:.*Per-Host Resources: mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=.*
 '  DATASTREAM SINK [FRAGMENT=F00, EXCHANGE=03, BROADCAST]'
-'  |  mem-estimate=0B mem-reservation=0B thread-reservation=0'
+row_regex:.*  |  mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=0
 '  01:SCAN HDFS [tpch.orders, RANDOM]'
 row_regex:.*partitions=1/1 files=1 size=.*
 '     stored statistics:'
 row_regex:.*table: rows=1500000 size=.*
 '       columns: all'
 row_regex:.*   extrapolated-rows=disabled max-scan-range-rows=[0-9]*.*
-row_regex:.*     mem-estimate=[0-9.]*MB mem-reservation=[0-9.]*MB thread-reservation=.*
+row_regex:.*     mem-estimate=[0-9.]*[A-Z]*B mem-reservation=[0-9.]*[A-Z]*B thread-reservation=.*
 '     tuple-ids=1 row-size=191B cardinality=1500000'
 '     in pipelines: 01(GETNEXT)'
 ====


[4/4] impala git commit: IMPALA-7351: Add estimates to Exchange node

Posted by bi...@apache.org.
IMPALA-7351: Add estimates to Exchange node

Added rough estimates for exchange node and a justification of the
method in the in-line comments.

Testing:
Updated Planner tests.

Change-Id: I5b577f9511abc48b992e814d50bba4959f23f7fd
Reviewed-on: http://gerrit.cloudera.org:8080/11692
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>


Project: http://git-wip-us.apache.org/repos/asf/impala/repo
Commit: http://git-wip-us.apache.org/repos/asf/impala/commit/8cbec20e
Tree: http://git-wip-us.apache.org/repos/asf/impala/tree/8cbec20e
Diff: http://git-wip-us.apache.org/repos/asf/impala/diff/8cbec20e

Branch: refs/heads/master
Commit: 8cbec20ea4f1399fce14018d30050d4b7ee501bc
Parents: 1d72c75
Author: Bikramjeet Vig <bi...@cloudera.com>
Authored: Thu Oct 11 12:16:11 2018 -0700
Committer: Impala Public Jenkins <im...@cloudera.com>
Committed: Thu Oct 25 21:17:12 2018 +0000

----------------------------------------------------------------------
 be/src/util/backend-gflag-util.cc               |   3 +
 common/thrift/BackendGflags.thrift              |   2 +
 .../org/apache/impala/planner/ExchangeNode.java |  95 +-
 .../org/apache/impala/planner/PlanNode.java     |   9 +
 .../queries/PlannerTest/kudu-selectivity.test   |  16 +-
 .../queries/PlannerTest/max-row-size.test       | 104 +-
 .../PlannerTest/resource-requirements.test      | 972 +++++++++----------
 .../PlannerTest/spillable-buffer-sizing.test    | 214 ++--
 .../queries/PlannerTest/tpcds-all.test          |  60 +-
 .../queries/PlannerTest/tpch-all.test           |  64 +-
 .../queries/PlannerTest/tpch-nested.test        | 172 ++--
 .../queries/QueryTest/explain-level2.test       |  18 +-
 .../queries/QueryTest/explain-level3.test       |  22 +-
 13 files changed, 920 insertions(+), 831 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/be/src/util/backend-gflag-util.cc
----------------------------------------------------------------------
diff --git a/be/src/util/backend-gflag-util.cc b/be/src/util/backend-gflag-util.cc
index 3760c84..9f4f2d0 100644
--- a/be/src/util/backend-gflag-util.cc
+++ b/be/src/util/backend-gflag-util.cc
@@ -67,6 +67,7 @@ DECLARE_int64(kudu_scanner_thread_estimated_bytes_per_column);
 DECLARE_int64(kudu_scanner_thread_max_estimated_bytes);
 DECLARE_int32(catalog_max_parallel_partial_fetch_rpc);
 DECLARE_int64(catalog_partial_fetch_rpc_queue_timeout_s);
+DECLARE_int64(exchg_node_buffer_size_bytes);
 
 namespace impala {
 
@@ -132,6 +133,8 @@ Status GetThriftBackendGflags(JNIEnv* jni_env, jbyteArray* cfg_bytes) {
       FLAGS_catalog_max_parallel_partial_fetch_rpc);
   cfg.__set_catalog_partial_fetch_rpc_queue_timeout_s(
       FLAGS_catalog_partial_fetch_rpc_queue_timeout_s);
+  cfg.__set_exchg_node_buffer_size_bytes(
+      FLAGS_exchg_node_buffer_size_bytes);
   RETURN_IF_ERROR(SerializeThriftMsg(jni_env, &cfg, cfg_bytes));
   return Status::OK();
 }

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/common/thrift/BackendGflags.thrift
----------------------------------------------------------------------
diff --git a/common/thrift/BackendGflags.thrift b/common/thrift/BackendGflags.thrift
index 531fc2c..dff4b8c 100644
--- a/common/thrift/BackendGflags.thrift
+++ b/common/thrift/BackendGflags.thrift
@@ -107,4 +107,6 @@ struct TBackendGflags {
   40: required i32 catalog_max_parallel_partial_fetch_rpc
 
   41: required i64 catalog_partial_fetch_rpc_queue_timeout_s
+
+  42: required i64 exchg_node_buffer_size_bytes
 }

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/fe/src/main/java/org/apache/impala/planner/ExchangeNode.java
----------------------------------------------------------------------
diff --git a/fe/src/main/java/org/apache/impala/planner/ExchangeNode.java b/fe/src/main/java/org/apache/impala/planner/ExchangeNode.java
index 05184f2..356ae6b 100644
--- a/fe/src/main/java/org/apache/impala/planner/ExchangeNode.java
+++ b/fe/src/main/java/org/apache/impala/planner/ExchangeNode.java
@@ -22,12 +22,14 @@ import org.apache.impala.analysis.Expr;
 import org.apache.impala.analysis.SortInfo;
 import org.apache.impala.analysis.TupleId;
 import org.apache.impala.common.ImpalaException;
+import org.apache.impala.service.BackendConfig;
 import org.apache.impala.thrift.TExchangeNode;
 import org.apache.impala.thrift.TExplainLevel;
 import org.apache.impala.thrift.TPlanNode;
 import org.apache.impala.thrift.TPlanNodeType;
 import org.apache.impala.thrift.TQueryOptions;
 import org.apache.impala.thrift.TSortInfo;
+
 import com.google.common.base.Preconditions;
 
 /**
@@ -49,6 +51,9 @@ public class ExchangeNode extends PlanNode {
   // update this constant as well.
   private static final double PER_TUPLE_SERIALIZATION_OVERHEAD = 4.0;
 
+  // Empirically derived minimum estimate (in bytes) for the exchange node.
+  private static final int MIN_ESTIMATE_BYTES = 16 * 1024;
+
   // The parameters based on which sorted input streams are merged by this
   // exchange node. Null if this exchange does not merge sorted streams
   private SortInfo mergeInfo_;
@@ -57,6 +62,21 @@ public class ExchangeNode extends PlanNode {
   // only if mergeInfo_ is non-null, i.e. this is a merging exchange node.
   private long offset_;
 
+  private boolean isMergingExchange() {
+    return mergeInfo_ != null;
+  }
+
+  private boolean isBroadcastExchange() {
+    // If the output of the sink is not partitioned but the target fragment is
+    // partitioned, then the data exchange is broadcast.
+    Preconditions.checkState(!children_.isEmpty());
+    DataSink sink = getChild(0).getFragment().getSink();
+    if (sink == null) return false;
+    Preconditions.checkState(sink instanceof DataStreamSink);
+    DataStreamSink streamSink = (DataStreamSink) sink;
+    return !streamSink.getOutputPartition().isPartitioned() && fragment_.isPartitioned();
+  }
+
   public ExchangeNode(PlanNodeId id, PlanNode input) {
     super(id, "EXCHANGE");
     offset_ = 0;
@@ -136,7 +156,7 @@ public class ExchangeNode extends PlanNode {
       output.append(detailPrefix + "offset: ").append(offset_).append("\n");
     }
 
-    if (mergeInfo_ != null && detailLevel.ordinal() > TExplainLevel.MINIMAL.ordinal()) {
+    if (isMergingExchange() && detailLevel.ordinal() > TExplainLevel.MINIMAL.ordinal()) {
       output.append(detailPrefix + "order by: ");
       for (int i = 0; i < mergeInfo_.getSortExprs().size(); ++i) {
         if (i > 0) output.append(", ");
@@ -160,14 +180,11 @@ public class ExchangeNode extends PlanNode {
     Preconditions.checkState(!children_.isEmpty());
     DataSink sink = getChild(0).getFragment().getSink();
     if (sink == null) return "";
-    Preconditions.checkState(sink instanceof DataStreamSink);
-    DataStreamSink streamSink = (DataStreamSink) sink;
-    if (!streamSink.getOutputPartition().isPartitioned() &&
-        fragment_.isPartitioned()) {
-      // If the output of the sink is not partitioned but the target fragment is
-      // partitioned, then the data exchange is broadcast.
+    if (isBroadcastExchange()) {
       return "BROADCAST";
     } else {
+      Preconditions.checkState(sink instanceof DataStreamSink);
+      DataStreamSink streamSink = (DataStreamSink) sink;
       return streamSink.getOutputPartition().getExplainString();
     }
   }
@@ -183,8 +200,66 @@ public class ExchangeNode extends PlanNode {
 
   @Override
   public void computeNodeResourceProfile(TQueryOptions queryOptions) {
-    // TODO: add an estimate
-    nodeResourceProfile_ =  ResourceProfile.noReservation(0);
+    // For non-merging exchanges, one row batch queue is maintained for row
+    // batches from all sender fragment instances. For merging exchange, one
+    // queue is created for the batches from each distinct sender. There is a
+    // soft limit on every row batch queue of FLAGS_exchg_node_buffer_size_bytes
+    // (default 10MB). There is also a deferred rpc queue which queues at max
+    // one rpc payload (containing the rowbatch) per sender in-case the row
+    // batch queue hits the previously mentioned soft limit. Actual memory used
+    // depends on the row size (that can vary a lot due to presence of var len
+    // strings) and on the rate at which rows are received and consumed from the
+    // exchange node which in turn depends on the complexity of the query and
+    // the system load. This makes it difficult to accurately estimate the
+    // memory usage at runtime. The following estimates assume that memory usage will
+    // lean towards the soft limits.
+    Preconditions.checkState(!children_.isEmpty());
+    Preconditions.checkNotNull(children_.get(0).getFragment());
+    int numSenders = children_.get(0).getFragment().getNumInstances(queryOptions.mt_dop);
+    long estimatedTotalQueueByteSize = estimateTotalQueueByteSize(numSenders);
+    long estimatedDeferredRPCQueueSize = estimateDeferredRPCQueueSize(queryOptions,
+        numSenders);
+    long estimatedMem = Math.max(
+        checkedAdd(estimatedTotalQueueByteSize, estimatedDeferredRPCQueueSize),
+        MIN_ESTIMATE_BYTES);
+    nodeResourceProfile_ = ResourceProfile.noReservation(estimatedMem);
+  }
+
+  // Returns the estimated size of the deferred batch queue (in bytes) by
+  // assuming that at least one row batch rpc payload per sender is queued.
+  private long estimateDeferredRPCQueueSize(TQueryOptions queryOptions,
+      int numSenders) {
+    long rowBatchSize = queryOptions.isSetBatch_size() && queryOptions.batch_size > 0
+        ? queryOptions.batch_size : DEFAULT_ROWBATCH_SIZE;
+    // Set an upper limit based on estimated cardinality.
+    if (getCardinality() > 0) rowBatchSize = Math.min(rowBatchSize, getCardinality());
+    long avgRowBatchByteSize = Math.min(
+        (long) Math.ceil(rowBatchSize * getAvgSerializedRowSize(this)),
+        ROWBATCH_MAX_MEM_USAGE);
+    long deferredBatchQueueSize = avgRowBatchByteSize * numSenders;
+    return deferredBatchQueueSize;
+  }
+
+  // Returns the total estimated size (in bytes) of the row batch queues by
+  // assuming enough batches can be queued such that it hits the row batch
+  // queue's soft mem limit.
+  private long estimateTotalQueueByteSize(int numSenders) {
+    int numQueues = isMergingExchange() ? numSenders : 1;
+    long maxQueueByteSize = BackendConfig.INSTANCE.getBackendCfg().
+        exchg_node_buffer_size_bytes;
+    // TODO: Should we set a better default size here? This might be alot for
+    // queries without stats.
+    long estimatedTotalQueueByteSize = numQueues * maxQueueByteSize;
+    // Set an upper limit based on estimated cardinality.
+    if (hasValidStats()) {
+      long totalBytesToReceive = (long) Math.ceil(getAvgRowSize() * getCardinality());
+      // Assuming no skew in distribution during data shuffling.
+      long bytesToReceivePerExchNode = isBroadcastExchange() ? totalBytesToReceive
+          : totalBytesToReceive / getNumNodes();
+      estimatedTotalQueueByteSize = Math.min(bytesToReceivePerExchNode,
+          estimatedTotalQueueByteSize);
+    }
+    return estimatedTotalQueueByteSize;
   }
 
   @Override
@@ -202,7 +277,7 @@ public class ExchangeNode extends PlanNode {
       msg.exchange_node.addToInput_row_tuples(tid.asInt());
     }
 
-    if (mergeInfo_ != null) {
+    if (isMergingExchange()) {
       TSortInfo sortInfo = new TSortInfo(
           Expr.treesToThrift(mergeInfo_.getSortExprs()), mergeInfo_.getIsAscOrder(),
           mergeInfo_.getNullsFirst());

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/fe/src/main/java/org/apache/impala/planner/PlanNode.java
----------------------------------------------------------------------
diff --git a/fe/src/main/java/org/apache/impala/planner/PlanNode.java b/fe/src/main/java/org/apache/impala/planner/PlanNode.java
index 927cc18..744aa09 100644
--- a/fe/src/main/java/org/apache/impala/planner/PlanNode.java
+++ b/fe/src/main/java/org/apache/impala/planner/PlanNode.java
@@ -68,6 +68,15 @@ import com.google.common.math.LongMath;
 abstract public class PlanNode extends TreeNode<PlanNode> {
   private final static Logger LOG = LoggerFactory.getLogger(PlanNode.class);
 
+  // The default row batch size used if the BATCH_SIZE query option is not set
+  // or is less than 1. Must be in sync with QueryState::DEFAULT_BATCH_SIZE.
+  protected final static int DEFAULT_ROWBATCH_SIZE = 1024;
+
+  // Max memory that a row batch can accumulate before it is considered at capacity.
+  // This is a soft capacity: row batches may exceed the capacity, preferably only by a
+  // row's worth of data. Must be in sync with RowBatch::AT_CAPACITY_MEM_USAGE.
+  protected final static int ROWBATCH_MAX_MEM_USAGE = 8 * 1024 * 1024;
+
   // String used for this node in getExplainString().
   protected String displayName_;
 

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-planner/queries/PlannerTest/kudu-selectivity.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-planner/queries/PlannerTest/kudu-selectivity.test b/testdata/workloads/functional-planner/queries/PlannerTest/kudu-selectivity.test
index 8a59968..6ae50f3 100644
--- a/testdata/workloads/functional-planner/queries/PlannerTest/kudu-selectivity.test
+++ b/testdata/workloads/functional-planner/queries/PlannerTest/kudu-selectivity.test
@@ -12,12 +12,12 @@ Per-Host Resources: mem-estimate=1.88MB mem-reservation=0B thread-reservation=2
      in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+Per-Host Resources: mem-estimate=16.00KB mem-reservation=0B thread-reservation=1
   PLAN-ROOT SINK
   |  mem-estimate=0B mem-reservation=0B thread-reservation=0
   |
   01:EXCHANGE [UNPARTITIONED]
-     mem-estimate=0B mem-reservation=0B thread-reservation=0
+     mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
      tuple-ids=0 row-size=124B cardinality=1
      in pipelines: 00(GETNEXT)
 
@@ -47,12 +47,12 @@ Per-Host Resources: mem-estimate=3.75MB mem-reservation=0B thread-reservation=2
      in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+Per-Host Resources: mem-estimate=16.00KB mem-reservation=0B thread-reservation=1
   PLAN-ROOT SINK
   |  mem-estimate=0B mem-reservation=0B thread-reservation=0
   |
   01:EXCHANGE [UNPARTITIONED]
-     mem-estimate=0B mem-reservation=0B thread-reservation=0
+     mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
      tuple-ids=0 row-size=124B cardinality=1
      in pipelines: 00(GETNEXT)
 
@@ -81,12 +81,12 @@ Per-Host Resources: mem-estimate=3.75MB mem-reservation=0B thread-reservation=2
      in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+Per-Host Resources: mem-estimate=517.89KB mem-reservation=0B thread-reservation=1
   PLAN-ROOT SINK
   |  mem-estimate=0B mem-reservation=0B thread-reservation=0
   |
   01:EXCHANGE [UNPARTITIONED]
-     mem-estimate=0B mem-reservation=0B thread-reservation=0
+     mem-estimate=517.89KB mem-reservation=0B thread-reservation=0
      tuple-ids=0 row-size=124B cardinality=3317
      in pipelines: 00(GETNEXT)
 
@@ -114,12 +114,12 @@ Per-Host Resources: mem-estimate=3.75MB mem-reservation=0B thread-reservation=2
      in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+Per-Host Resources: mem-estimate=16.00KB mem-reservation=0B thread-reservation=1
   PLAN-ROOT SINK
   |  mem-estimate=0B mem-reservation=0B thread-reservation=0
   |
   01:EXCHANGE [UNPARTITIONED]
-     mem-estimate=0B mem-reservation=0B thread-reservation=0
+     mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
      tuple-ids=0 row-size=124B cardinality=3
      in pipelines: 00(GETNEXT)
 

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-planner/queries/PlannerTest/max-row-size.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-planner/queries/PlannerTest/max-row-size.test b/testdata/workloads/functional-planner/queries/PlannerTest/max-row-size.test
index f82f1be..e1d8119 100644
--- a/testdata/workloads/functional-planner/queries/PlannerTest/max-row-size.test
+++ b/testdata/workloads/functional-planner/queries/PlannerTest/max-row-size.test
@@ -5,20 +5,20 @@ from tpch_parquet.customer
     inner join tpch_parquet.nation on c_nationkey = n_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=33.97MB Threads=5
-Per-Host Resource Estimates: Memory=58MB
+Per-Host Resource Estimates: Memory=68MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.35MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.35MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=355B cardinality=150000
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=1 instances=1
-Per-Host Resources: mem-estimate=41.94MB mem-reservation=33.94MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=41.95MB mem-reservation=33.94MB thread-reservation=2 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: c_nationkey = n_nationkey
 |  fk/pk conjuncts: c_nationkey = n_nationkey
@@ -28,7 +28,7 @@ Per-Host Resources: mem-estimate=41.94MB mem-reservation=33.94MB thread-reservat
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=117B cardinality=25
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -62,20 +62,20 @@ from tpch_parquet.lineitem
     left join tpch_parquet.orders on l_orderkey = o_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=110.00MB Threads=5
-Per-Host Resource Estimates: Memory=420MB
+Per-Host Resource Estimates: Memory=442MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.35MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.35MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1N row-size=454B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
-Per-Host Resources: mem-estimate=380.41MB mem-reservation=86.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=390.80MB mem-reservation=86.00MB thread-reservation=2
 02:HASH JOIN [LEFT OUTER JOIN, BROADCAST]
 |  hash predicates: l_orderkey = o_orderkey
 |  fk/pk conjuncts: l_orderkey = o_orderkey
@@ -84,7 +84,7 @@ Per-Host Resources: mem-estimate=380.41MB mem-reservation=86.00MB thread-reserva
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.38MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -101,11 +101,11 @@ Per-Host Resources: mem-estimate=380.41MB mem-reservation=86.00MB thread-reserva
 |     in pipelines: 01(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -116,20 +116,20 @@ select * from tpch_parquet.lineitem
 where l_orderkey not in (select o_orderkey from tpch_parquet.orders)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=78.00MB Threads=5
-Per-Host Resource Estimates: Memory=154MB
+Per-Host Resource Estimates: Memory=175MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.78MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
-Per-Host Resources: mem-estimate=114.00MB mem-reservation=74.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=124.02MB mem-reservation=74.00MB thread-reservation=2
 02:HASH JOIN [NULL AWARE LEFT ANTI JOIN, BROADCAST]
 |  hash predicates: l_orderkey = o_orderkey
 |  mem-estimate=34.00MB mem-reservation=34.00MB spill-buffer=1.00MB thread-reservation=0
@@ -137,7 +137,7 @@ Per-Host Resources: mem-estimate=114.00MB mem-reservation=74.00MB thread-reserva
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.02MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=8B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -154,11 +154,11 @@ Per-Host Resources: mem-estimate=114.00MB mem-reservation=74.00MB thread-reserva
 |     in pipelines: 01(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -172,20 +172,20 @@ group by 1, 2
 having count(*) = 1
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=125.00MB Threads=7
-Per-Host Resource Estimates: Memory=253MB
+Per-Host Resource Estimates: Memory=293MB
 
 F04:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.11MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 08:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.11MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=33B cardinality=4690314
 |  in pipelines: 07(GETNEXT)
 |
 F03:PLAN FRAGMENT [HASH(l_orderkey,o_orderstatus)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=46.00MB mem-reservation=46.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=56.11MB mem-reservation=46.00MB thread-reservation=1
 07:AGGREGATE [FINALIZE]
 |  output: count:merge(*)
 |  group by: l_orderkey, o_orderstatus
@@ -195,12 +195,12 @@ Per-Host Resources: mem-estimate=46.00MB mem-reservation=46.00MB thread-reservat
 |  in pipelines: 07(GETNEXT), 00(OPEN)
 |
 06:EXCHANGE [HASH(l_orderkey,o_orderstatus)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.11MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=33B cardinality=4690314
 |  in pipelines: 00(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=86.12MB mem-reservation=66.00MB thread-reservation=1 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=106.22MB mem-reservation=66.00MB thread-reservation=1 runtime-filters-memory=1.00MB
 03:AGGREGATE [STREAMING]
 |  output: count(*)
 |  group by: l_orderkey, o_orderstatus
@@ -217,7 +217,7 @@ Per-Host Resources: mem-estimate=86.12MB mem-reservation=66.00MB thread-reservat
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--05:EXCHANGE [HASH(o_orderkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.06MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=25B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -234,19 +234,19 @@ Per-Host Resources: mem-estimate=86.12MB mem-reservation=66.00MB thread-reservat
 |     in pipelines: 01(GETNEXT)
 |
 04:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.04MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=8B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=81.00MB mem-reservation=5.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    runtime filters: RF000[bloom] -> l_orderkey
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -257,20 +257,20 @@ select distinct *
 from tpch_parquet.lineitem
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=120.00MB Threads=4
-Per-Host Resource Estimates: Memory=3.31GB
+Per-Host Resource Estimates: Memory=3.33GB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.78MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(tpch_parquet.lineitem.l_orderkey,tpch_parquet.lineitem.l_partkey,tpch_parquet.lineitem.l_suppkey,tpch_parquet.lineitem.l_linenumber,tpch_parquet.lineitem.l_quantity,tpch_parquet.lineitem.l_extendedprice,tpch_parquet.lineitem.l_discount,tpch_parquet.lineitem.l_tax,tpch_parquet.lineitem.l_returnflag,tpch_parquet.lineitem.l_linestatus,tpch_parquet.lineitem.l_shipdate,tpch_parquet.lineitem.l_commitdate,tpch_parquet.lineitem.l_receiptdate,tpch_parquet.lineitem.l_shipinstruct,tpch_parquet.lineitem.l_shipmode,tpch_parquet.lineitem.l_comment)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=1.62GB mem-reservation=46.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=1.63GB mem-reservation=46.00MB thread-reservation=1
 03:AGGREGATE [FINALIZE]
 |  group by: tpch_parquet.lineitem.l_orderkey, tpch_parquet.lineitem.l_partkey, tpch_parquet.lineitem.l_suppkey, tpch_parquet.lineitem.l_linenumber, tpch_parquet.lineitem.l_quantity, tpch_parquet.lineitem.l_extendedprice, tpch_parquet.lineitem.l_discount, tpch_parquet.lineitem.l_tax, tpch_parquet.lineitem.l_returnflag, tpch_parquet.lineitem.l_linestatus, tpch_parquet.lineitem.l_shipdate, tpch_parquet.lineitem.l_commitdate, tpch_parquet.lineitem.l_receiptdate, tpch_parquet.lineitem.l_shipinstruct, tpch_parquet.lineitem.l_shipmode, tpch_parquet.lineitem.l_comment
 |  mem-estimate=1.62GB mem-reservation=46.00MB spill-buffer=2.00MB thread-reservation=0
@@ -278,7 +278,7 @@ Per-Host Resources: mem-estimate=1.62GB mem-reservation=46.00MB thread-reservati
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(tpch_parquet.lineitem.l_orderkey,tpch_parquet.lineitem.l_partkey,tpch_parquet.lineitem.l_suppkey,tpch_parquet.lineitem.l_linenumber,tpch_parquet.lineitem.l_quantity,tpch_parquet.lineitem.l_extendedprice,tpch_parquet.lineitem.l_discount,tpch_parquet.lineitem.l_tax,tpch_parquet.lineitem.l_returnflag,tpch_parquet.lineitem.l_linestatus,tpch_parquet.lineitem.l_shipdate,tpch_parquet.lineitem.l_commitdate,tpch_parquet.lineitem.l_receiptdate,tpch_parquet.lineitem.l_shipinstruct,tpch_parquet.lineitem.l_shipmode,tpch_parquet.lineitem.l_comment)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -291,11 +291,11 @@ Per-Host Resources: mem-estimate=1.69GB mem-reservation=74.00MB thread-reservati
 |  in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -307,20 +307,20 @@ from tpch_parquet.lineitem
 group by 1, 2
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=98.00MB Threads=4
-Per-Host Resource Estimates: Memory=483MB
+Per-Host Resource Estimates: Memory=503MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.11MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.11MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=32B cardinality=6001215
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(l_orderkey,l_partkey)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=201.46MB mem-reservation=48.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=211.56MB mem-reservation=48.00MB thread-reservation=1
 03:AGGREGATE [FINALIZE]
 |  output: group_concat:merge(l_linestatus, ',')
 |  group by: l_orderkey, l_partkey
@@ -329,7 +329,7 @@ Per-Host Resources: mem-estimate=201.46MB mem-reservation=48.00MB thread-reserva
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(l_orderkey,l_partkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.11MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=32B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -343,11 +343,11 @@ Per-Host Resources: mem-estimate=281.46MB mem-reservation=50.00MB thread-reserva
 |  in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=16.00MB thread-reservation=1
    tuple-ids=0 row-size=33B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -362,17 +362,17 @@ Per-Host Resource Estimates: Memory=56MB
 Codegen disabled by planner
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=56.26KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=56.26KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=3,2 row-size=6B cardinality=7300
 |  in pipelines: 01(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(int_col)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=40.00MB mem-reservation=40.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=40.04MB mem-reservation=40.00MB thread-reservation=1
 02:ANALYTIC
 |  functions: max(tinyint_col)
 |  partition by: int_col
@@ -387,7 +387,7 @@ Per-Host Resources: mem-estimate=40.00MB mem-reservation=40.00MB thread-reservat
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 03:EXCHANGE [HASH(int_col)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=38.88KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=5B cardinality=7300
 |  in pipelines: 00(GETNEXT)
 |


[3/4] impala git commit: IMPALA-7351: Add estimates to Exchange node

Posted by bi...@apache.org.
http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-planner/queries/PlannerTest/resource-requirements.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-planner/queries/PlannerTest/resource-requirements.test b/testdata/workloads/functional-planner/queries/PlannerTest/resource-requirements.test
index 6eb42ef..71040ad 100644
--- a/testdata/workloads/functional-planner/queries/PlannerTest/resource-requirements.test
+++ b/testdata/workloads/functional-planner/queries/PlannerTest/resource-requirements.test
@@ -10,61 +10,61 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [tpch_parquet.lineitem]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=40.00MB Threads=3
-Per-Host Resource Estimates: Memory=80MB
+Per-Host Resource Estimates: Memory=91MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.78MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=2
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=80.00MB Threads=3
-Per-Host Resource Estimates: Memory=160MB
+Per-Host Resource Estimates: Memory=172MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.56MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.56MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=160.00MB mem-reservation=80.00MB thread-reservation=2
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=0
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -82,61 +82,61 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [tpch_parquet.lineitem]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=42B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=4.00MB Threads=3
-Per-Host Resource Estimates: Memory=80MB
+Per-Host Resource Estimates: Memory=90MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.14MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.14MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=42B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=2
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=42B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=8.00MB Threads=3
-Per-Host Resource Estimates: Memory=160MB
+Per-Host Resource Estimates: Memory=170MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.27MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.27MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=42B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=160.00MB mem-reservation=8.00MB thread-reservation=2
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=0
    tuple-ids=0 row-size=42B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -155,7 +155,7 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [functional_parquet.alltypes]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -171,19 +171,19 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=60.00KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=60.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=16B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=16.00MB mem-reservation=16.00KB thread-reservation=2
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -199,19 +199,19 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=120.00KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=120.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=16B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=32.00MB mem-reservation=32.00KB thread-reservation=2
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -236,7 +236,7 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [functional_parquet.alltypes]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -252,19 +252,19 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=83.99KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=83.99KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=24B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=16.00MB mem-reservation=24.00KB thread-reservation=2
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -280,19 +280,19 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=167.99KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=167.99KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=24B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=32.00MB mem-reservation=48.00KB thread-reservation=2
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -317,7 +317,7 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [functional_parquet.alltypes]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -333,19 +333,19 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=16.00KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=0B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=1.00MB mem-reservation=16.00KB thread-reservation=2
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -361,19 +361,19 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=24.00KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=24.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=0B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=32.00MB mem-reservation=32.00KB thread-reservation=2
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=199.69KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -396,9 +396,9 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [tpch_parquet.customer]
-   partitions=1/1 files=1 size=12.34MB
+   partitions=1/1 files=1 size=12.31MB
    stored statistics:
-     table: rows=150000 size=12.34MB
+     table: rows=150000 size=12.31MB
      columns: all
    extrapolated-rows=disabled max-scan-range-rows=150000
    mem-estimate=24.00MB mem-reservation=128.00KB thread-reservation=1
@@ -418,9 +418,9 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [tpch_parquet.customer]
-   partitions=1/1 files=1 size=12.34MB
+   partitions=1/1 files=1 size=12.31MB
    stored statistics:
-     table: rows=150000 size=12.34MB
+     table: rows=150000 size=12.31MB
      columns: all
    extrapolated-rows=disabled max-scan-range-rows=150000
    mem-estimate=24.00MB mem-reservation=2.00MB thread-reservation=1
@@ -465,11 +465,11 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=24.00MB thread-reservation=1
    tuple-ids=0 row-size=80B cardinality=1500000
    in pipelines: 00(GETNEXT)
@@ -488,11 +488,11 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=16B cardinality=1500000
    in pipelines: 00(GETNEXT)
@@ -511,11 +511,11 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=8B cardinality=1500000
    in pipelines: 00(GETNEXT)
@@ -559,12 +559,12 @@ PLAN-ROOT SINK
 |     in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns missing stats: c_orders
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=32.00MB thread-reservation=1
    tuple-ids=0 row-size=24B cardinality=150000
    in pipelines: 00(GETNEXT)
@@ -607,12 +607,12 @@ PLAN-ROOT SINK
 |     in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns missing stats: c_orders
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=8.00MB thread-reservation=1
    tuple-ids=0 row-size=24B cardinality=150000
    in pipelines: 00(GETNEXT)
@@ -656,12 +656,12 @@ PLAN-ROOT SINK
 |     in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns missing stats: c_orders
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=8.00MB thread-reservation=1
    tuple-ids=0 row-size=24B cardinality=150000
    in pipelines: 00(GETNEXT)
@@ -705,12 +705,12 @@ PLAN-ROOT SINK
 |     in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns missing stats: c_orders
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=8.00MB thread-reservation=1
    tuple-ids=0 row-size=24B cardinality=150000
    in pipelines: 00(GETNEXT)
@@ -753,12 +753,12 @@ PLAN-ROOT SINK
 |     in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns: unavailable
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=16B cardinality=150000
    in pipelines: 00(GETNEXT)
@@ -823,13 +823,13 @@ PLAN-ROOT SINK
 |     in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=289.00MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems)
    stored statistics:
-     table: rows=150000 size=289.00MB
+     table: rows=150000 size=288.99MB
      columns missing stats: c_orders
-   extrapolated-rows=disabled max-scan-range-rows=44227
+   extrapolated-rows=disabled max-scan-range-rows=44232
    mem-estimate=88.00MB mem-reservation=16.00MB thread-reservation=1
    tuple-ids=0 row-size=24B cardinality=150000
    in pipelines: 00(GETNEXT)
@@ -856,15 +856,15 @@ PLAN-ROOT SINK
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=8.00MB Threads=3
-Per-Host Resource Estimates: Memory=88MB
+Per-Host Resource Estimates: Memory=99MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.78MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -881,15 +881,15 @@ Per-Host Resources: mem-estimate=88.00MB mem-reservation=8.00MB thread-reservati
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=16.00MB Threads=3
-Per-Host Resource Estimates: Memory=176MB
+Per-Host Resource Estimates: Memory=188MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.56MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.56MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -927,15 +927,15 @@ PLAN-ROOT SINK
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=8.00MB Threads=3
-Per-Host Resource Estimates: Memory=88MB
+Per-Host Resource Estimates: Memory=98MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.14MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.14MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=42B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -952,15 +952,15 @@ Per-Host Resources: mem-estimate=88.00MB mem-reservation=8.00MB thread-reservati
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=16.00MB Threads=3
-Per-Host Resource Estimates: Memory=176MB
+Per-Host Resource Estimates: Memory=186MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.27MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.27MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=42B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -1000,16 +1000,16 @@ PLAN-ROOT SINK
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=32.00KB Threads=3
-Per-Host Resource Estimates: Memory=16MB
+Per-Host Resource Estimates: Memory=17MB
 Codegen disabled by planner
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=533.50KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=533.50KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=97B cardinality=7300
 |  in pipelines: 00(GETNEXT)
 |
@@ -1027,16 +1027,16 @@ Per-Host Resources: mem-estimate=16.00MB mem-reservation=32.00KB thread-reservat
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=64.00KB Threads=3
-Per-Host Resource Estimates: Memory=32MB
+Per-Host Resource Estimates: Memory=33MB
 Codegen disabled by planner
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=836.50KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=836.50KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=97B cardinality=7300
 |  in pipelines: 00(GETNEXT)
 |
@@ -1082,12 +1082,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 tpch_avro.orders
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=223.95KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=223.95KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=108B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -1109,12 +1109,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 tpch_avro.orders
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=447.95KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=447.95KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=108B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -1159,12 +1159,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 tpch_rc.customer
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=101.90KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=101.90KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=98B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -1186,12 +1186,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 tpch_rc.customer
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=203.90KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=203.90KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=98B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -1236,12 +1236,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 tpcds_seq_snap.web_returns
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=107.90KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=107.90KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=104B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -1263,12 +1263,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 tpcds_seq_snap.web_returns
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=215.90KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=215.90KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=104B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -1364,7 +1364,7 @@ PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 00:SCAN HDFS [functional.alltypesmixedformat]
-   partitions=4/4 files=4 size=66.48KB
+   partitions=4/4 files=4 size=66.06KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/4 rows=unavailable
@@ -1380,19 +1380,19 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional.alltypesmixedformat
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=275.97KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=275.97KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=88B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=16.00MB mem-reservation=88.00KB thread-reservation=2
 00:SCAN HDFS [functional.alltypesmixedformat, RANDOM]
-   partitions=4/4 files=4 size=66.48KB
+   partitions=4/4 files=4 size=66.06KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/4 rows=unavailable
@@ -1403,24 +1403,24 @@ Per-Host Resources: mem-estimate=16.00MB mem-reservation=88.00KB thread-reservat
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=176.00KB Threads=5
-Per-Host Resource Estimates: Memory=32MB
+Per-Host Resource Estimates: Memory=33MB
 WARNING: The following tables are missing relevant table and/or column statistics.
 functional.alltypesmixedformat
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=551.97KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=551.97KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=88B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=32.00MB mem-reservation=176.00KB thread-reservation=4
 00:SCAN HDFS [functional.alltypesmixedformat, RANDOM]
-   partitions=4/4 files=4 size=66.48KB
+   partitions=4/4 files=4 size=66.06KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/4 rows=unavailable
@@ -1457,12 +1457,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_hbase.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=1.29MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=1.29MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=88B cardinality=14298
 |  in pipelines: 00(GETNEXT)
 |
@@ -1482,12 +1482,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_hbase.alltypes
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=1.38MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=1.38MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=88B cardinality=14298
 |  in pipelines: 00(GETNEXT)
 |
@@ -1526,12 +1526,12 @@ Per-Host Resource Estimates: Memory=10MB
 Codegen disabled by planner
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=16.37KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.37KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=97B cardinality=50
 |  in pipelines: 00(GETNEXT)
 |
@@ -1550,12 +1550,12 @@ Per-Host Resource Estimates: Memory=10MB
 Codegen disabled by planner
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=31.17KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=31.17KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=97B cardinality=50
 |  in pipelines: 00(GETNEXT)
 |
@@ -1593,12 +1593,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional.alltypes_datasource
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=686.41KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=686.41KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=116B cardinality=5000
 |  in pipelines: 00(GETNEXT)
 |
@@ -1615,12 +1615,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional.alltypes_datasource
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=806.41KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 01:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=806.41KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=116B cardinality=5000
 |  in pipelines: 00(GETNEXT)
 |
@@ -1671,15 +1671,15 @@ PLAN-ROOT SINK
    in pipelines: 01(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=8.00MB Threads=3
-Per-Host Resource Estimates: Memory=88MB
+Per-Host Resource Estimates: Memory=99MB
 
 F03:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.78MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 03:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=263B cardinality=12002430
 |  in pipelines: 01(GETNEXT), 02(GETNEXT)
 |
@@ -1712,15 +1712,15 @@ Per-Host Resources: mem-estimate=88.00MB mem-reservation=8.00MB thread-reservati
    in pipelines: 01(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=16.00MB Threads=3
-Per-Host Resource Estimates: Memory=176MB
+Per-Host Resource Estimates: Memory=188MB
 
 F03:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.56MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 03:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.56MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=263B cardinality=12002430
 |  in pipelines: 01(GETNEXT), 02(GETNEXT)
 |
@@ -1773,30 +1773,30 @@ PLAN-ROOT SINK
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=46.50MB Threads=4
-Per-Host Resource Estimates: Memory=124MB
+Per-Host Resource Estimates: Memory=140MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=8.01MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=8.01MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=16B cardinality=1563438
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=10.00MB mem-reservation=8.50MB thread-reservation=1
+Per-Host Resources: mem-estimate=18.01MB mem-reservation=8.50MB thread-reservation=1
 03:AGGREGATE [FINALIZE]
 |  output: count:merge(*)
 |  group by: l_orderkey
@@ -1805,7 +1805,7 @@ Per-Host Resources: mem-estimate=10.00MB mem-reservation=8.50MB thread-reservati
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=8.01MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=16B cardinality=1563438
 |  in pipelines: 00(GETNEXT)
 |
@@ -1819,30 +1819,30 @@ Per-Host Resources: mem-estimate=114.00MB mem-reservation=38.00MB thread-reserva
 |  in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=85.50MB Threads=5
-Per-Host Resource Estimates: Memory=248MB
+Per-Host Resource Estimates: Memory=272MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=8.07MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=8.07MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=16B cardinality=1563438
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=20.00MB mem-reservation=9.50MB thread-reservation=2
+Per-Host Resources: mem-estimate=36.14MB mem-reservation=9.50MB thread-reservation=2
 03:AGGREGATE [FINALIZE]
 |  output: count:merge(*)
 |  group by: l_orderkey
@@ -1851,7 +1851,7 @@ Per-Host Resources: mem-estimate=20.00MB mem-reservation=9.50MB thread-reservati
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=8.07MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=16B cardinality=1563438
 |  in pipelines: 00(GETNEXT)
 |
@@ -1865,11 +1865,11 @@ Per-Host Resources: mem-estimate=228.00MB mem-reservation=76.00MB thread-reserva
 |  in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=0
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -1892,11 +1892,11 @@ PLAN-ROOT SINK
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=1.00MB mem-reservation=128.00KB thread-reservation=1
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -1905,7 +1905,7 @@ Max Per-Host Resource Reservation: Memory=128.00KB Threads=3
 Per-Host Resource Estimates: Memory=21MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=10.00MB mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.02MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
@@ -1916,7 +1916,7 @@ PLAN-ROOT SINK
 |  in pipelines: 03(GETNEXT), 01(OPEN)
 |
 02:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=8B cardinality=1
 |  in pipelines: 01(GETNEXT)
 |
@@ -1929,11 +1929,11 @@ Per-Host Resources: mem-estimate=11.00MB mem-reservation=128.00KB thread-reserva
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=1.00MB mem-reservation=128.00KB thread-reservation=1
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -1942,7 +1942,7 @@ Max Per-Host Resource Reservation: Memory=256.00KB Threads=3
 Per-Host Resource Estimates: Memory=190MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=10.00MB mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.02MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
@@ -1953,7 +1953,7 @@ PLAN-ROOT SINK
 |  in pipelines: 03(GETNEXT), 01(OPEN)
 |
 02:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=8B cardinality=1
 |  in pipelines: 01(GETNEXT)
 |
@@ -1966,11 +1966,11 @@ Per-Host Resources: mem-estimate=180.00MB mem-reservation=256.00KB thread-reserv
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=128.00KB thread-reservation=0
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -1995,26 +1995,26 @@ PLAN-ROOT SINK
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=52.00MB Threads=3
-Per-Host Resource Estimates: Memory=120MB
+Per-Host Resource Estimates: Memory=151MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=30.78MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 02:MERGING-EXCHANGE [UNPARTITIONED]
 |  order by: l_comment ASC
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=30.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 01(GETNEXT)
 |
@@ -2027,26 +2027,26 @@ Per-Host Resources: mem-estimate=120.00MB mem-reservation=52.00MB thread-reserva
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=104.00MB Threads=3
-Per-Host Resource Estimates: Memory=240MB
+Per-Host Resource Estimates: Memory=302MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=61.56MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 02:MERGING-EXCHANGE [UNPARTITIONED]
 |  order by: l_comment ASC
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=61.56MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 01(GETNEXT)
 |
@@ -2059,11 +2059,11 @@ Per-Host Resources: mem-estimate=240.00MB mem-reservation=104.00MB thread-reserv
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=0
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -2089,11 +2089,11 @@ PLAN-ROOT SINK
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -2102,14 +2102,14 @@ Max Per-Host Resource Reservation: Memory=40.00MB Threads=3
 Per-Host Resource Estimates: Memory=80MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=86.71KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 02:MERGING-EXCHANGE [UNPARTITIONED]
 |  order by: l_comment ASC
 |  limit: 100
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=86.71KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=100
 |  in pipelines: 01(GETNEXT)
 |
@@ -2122,11 +2122,11 @@ Per-Host Resources: mem-estimate=80.03MB mem-reservation=40.00MB thread-reservat
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -2135,14 +2135,14 @@ Max Per-Host Resource Reservation: Memory=80.00MB Threads=3
 Per-Host Resource Estimates: Memory=160MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=164.87KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 02:MERGING-EXCHANGE [UNPARTITIONED]
 |  order by: l_comment ASC
 |  limit: 100
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=164.87KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=100
 |  in pipelines: 01(GETNEXT)
 |
@@ -2155,11 +2155,11 @@ Per-Host Resources: mem-estimate=160.05MB mem-reservation=80.00MB thread-reserva
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=0
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -2206,20 +2206,20 @@ PLAN-ROOT SINK
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=51.00MB Threads=5
-Per-Host Resource Estimates: Memory=477MB
+Per-Host Resource Estimates: Memory=499MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.35MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.35MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=454B cardinality=5757710
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
-Per-Host Resources: mem-estimate=389.41MB mem-reservation=43.00MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=399.80MB mem-reservation=43.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: l_orderkey = o_orderkey
 |  fk/pk conjuncts: l_orderkey = o_orderkey
@@ -2229,7 +2229,7 @@ Per-Host Resources: mem-estimate=389.41MB mem-reservation=43.00MB thread-reserva
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.38MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -2257,15 +2257,15 @@ Per-Host Resources: mem-estimate=389.41MB mem-reservation=43.00MB thread-reserva
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=102.00MB Threads=5
-Per-Host Resource Estimates: Memory=955MB
+Per-Host Resource Estimates: Memory=968MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=12.71MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=12.71MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=454B cardinality=5757710
 |  in pipelines: 00(GETNEXT)
 |
@@ -2288,7 +2288,7 @@ Per-Host Resources: mem-estimate=778.83MB mem-reservation=86.00MB thread-reserva
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.76MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -2357,20 +2357,20 @@ PLAN-ROOT SINK
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=52.00MB Threads=6
-Per-Host Resource Estimates: Memory=278MB
+Per-Host Resource Estimates: Memory=311MB
 
 F03:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.35MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 05:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.35MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=454B cardinality=5757710
 |  in pipelines: 00(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=101.14MB mem-reservation=35.00MB thread-reservation=1 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=122.30MB mem-reservation=35.00MB thread-reservation=1 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, PARTITIONED]
 |  hash predicates: l_orderkey = o_orderkey
 |  fk/pk conjuncts: l_orderkey = o_orderkey
@@ -2380,7 +2380,7 @@ Per-Host Resources: mem-estimate=101.14MB mem-reservation=35.00MB thread-reserva
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--04:EXCHANGE [HASH(o_orderkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.38MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -2397,7 +2397,7 @@ Per-Host Resources: mem-estimate=101.14MB mem-reservation=35.00MB thread-reserva
 |     in pipelines: 01(GETNEXT)
 |
 03:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -2415,20 +2415,20 @@ Per-Host Resources: mem-estimate=89.00MB mem-reservation=9.00MB thread-reservati
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=104.00MB Threads=7
-Per-Host Resource Estimates: Memory=456MB
+Per-Host Resource Estimates: Memory=492MB
 
 F03:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=12.71MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 05:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=12.71MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=454B cardinality=5757710
 |  in pipelines: 00(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=102.14MB mem-reservation=70.00MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=125.26MB mem-reservation=70.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, PARTITIONED]
 |  hash-table-id=00
 |  hash predicates: l_orderkey = o_orderkey
@@ -2446,7 +2446,7 @@ Per-Host Resources: mem-estimate=102.14MB mem-reservation=70.00MB thread-reserva
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  04:EXCHANGE [HASH(o_orderkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.76MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -2463,7 +2463,7 @@ Per-Host Resources: mem-estimate=102.14MB mem-reservation=70.00MB thread-reserva
 |     in pipelines: 01(GETNEXT)
 |
 03:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.56MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -2518,27 +2518,27 @@ PLAN-ROOT SINK
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=16.00MB Threads=5
-Per-Host Resource Estimates: Memory=449MB
+Per-Host Resource Estimates: Memory=471MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.35MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.35MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=454B cardinality=9001822500000
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
-Per-Host Resources: mem-estimate=361.10MB mem-reservation=8.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=371.49MB mem-reservation=8.00MB thread-reservation=2
 02:NESTED LOOP JOIN [CROSS JOIN, BROADCAST]
 |  mem-estimate=273.10MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=454B cardinality=9001822500000
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.38MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -2565,20 +2565,20 @@ Per-Host Resources: mem-estimate=361.10MB mem-reservation=8.00MB thread-reservat
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=32.00MB Threads=5
-Per-Host Resource Estimates: Memory=898MB
+Per-Host Resource Estimates: Memory=932MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=12.71MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=12.71MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=454B cardinality=9001822500000
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
-Per-Host Resources: mem-estimate=722.21MB mem-reservation=16.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=743.73MB mem-reservation=16.00MB thread-reservation=2
 02:NESTED LOOP JOIN [CROSS JOIN, BROADCAST]
 |  join table id: 00
 |  mem-estimate=273.10MB mem-reservation=0B thread-reservation=0
@@ -2592,7 +2592,7 @@ Per-Host Resources: mem-estimate=722.21MB mem-reservation=16.00MB thread-reserva
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.76MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -2705,17 +2705,17 @@ Per-Host Resource Estimates: Memory=26MB
 Codegen disabled by planner
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=56.26KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=56.26KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=3,2 row-size=6B cardinality=7300
 |  in pipelines: 01(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(int_col)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=10.00MB mem-reservation=10.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=10.04MB mem-reservation=10.00MB thread-reservation=1
 02:ANALYTIC
 |  functions: max(tinyint_col)
 |  partition by: int_col
@@ -2730,7 +2730,7 @@ Per-Host Resources: mem-estimate=10.00MB mem-reservation=10.00MB thread-reservat
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 03:EXCHANGE [HASH(int_col)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=38.88KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=5B cardinality=7300
 |  in pipelines: 00(GETNEXT)
 |
@@ -2752,17 +2752,17 @@ Per-Host Resource Estimates: Memory=52MB
 Codegen disabled by planner
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=98.26KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=98.26KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=3,2 row-size=6B cardinality=7300
 |  in pipelines: 01(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(int_col)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=20.00MB mem-reservation=20.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=20.13MB mem-reservation=20.00MB thread-reservation=2
 02:ANALYTIC
 |  functions: max(tinyint_col)
 |  partition by: int_col
@@ -2777,7 +2777,7 @@ Per-Host Resources: mem-estimate=20.00MB mem-reservation=20.00MB thread-reservat
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 03:EXCHANGE [HASH(int_col)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=65.88KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=5B cardinality=7300
 |  in pipelines: 00(GETNEXT)
 |
@@ -2852,20 +2852,20 @@ PLAN-ROOT SINK
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.orders]
-   partitions=1/1 files=2 size=54.21MB
+   partitions=1/1 files=2 size=54.07MB
    stored statistics:
-     table: rows=1500000 size=54.21MB
+     table: rows=1500000 size=54.07MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=1177197
+   extrapolated-rows=disabled max-scan-range-rows=1177135
    mem-estimate=40.00MB mem-reservation=24.00MB thread-reservation=1
    tuple-ids=0 row-size=191B cardinality=1500000
    in pipelines: 00(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=68.00MB Threads=3
-Per-Host Resource Estimates: Memory=102MB
+Per-Host Resource Estimates: Memory=108MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=44.00MB mem-reservation=32.00MB thread-reservation=1
+|  Per-Host Resources: mem-estimate=50.38MB mem-reservation=32.00MB thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
@@ -2907,7 +2907,7 @@ PLAN-ROOT SINK
 |
 07:MERGING-EXCHANGE [UNPARTITIONED]
 |  order by: o_totalprice ASC
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=20.38MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=6 row-size=191B cardinality=1500000
 |  in pipelines: 01(GETNEXT)
 |
@@ -2920,20 +2920,20 @@ Per-Host Resources: mem-estimate=58.00MB mem-reservation=36.00MB thread-reservat
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.orders, RANDOM]
-   partitions=1/1 files=2 size=54.21MB
+   partitions=1/1 files=2 size=54.07MB
    stored statistics:
-     table: rows=1500000 size=54.21MB
+     table: rows=1500000 size=54.07MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=1177197
+   extrapolated-rows=disabled max-scan-range-rows=1177135
    mem-estimate=40.00MB mem-reservation=24.00MB thread-reservation=1
    tuple-ids=0 row-size=191B cardinality=1500000
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=104.00MB Threads=3
-Per-Host Resource Estimates: Memory=160MB
+Per-Host Resource Estimates: Memory=187MB
 
 F01:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=44.00MB mem-reservation=32.00MB thread-reservation=1
+|  Per-Host Resources: mem-estimate=70.76MB mem-reservation=32.00MB thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
@@ -2975,7 +2975,7 @@ PLAN-ROOT SINK
 |
 07:MERGING-EXCHANGE [UNPARTITIONED]
 |  order by: o_totalprice ASC
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=40.76MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=6 row-size=191B cardinality=1500000
 |  in pipelines: 01(GETNEXT)
 |
@@ -2988,11 +2988,11 @@ Per-Host Resources: mem-estimate=116.00MB mem-reservation=72.00MB thread-reserva
 |  in pipelines: 01(GETNEXT), 00(OPEN)
 |
 00:SCAN HDFS [tpch_parquet.orders, RANDOM]
-   partitions=1/1 files=2 size=54.21MB
+   partitions=1/1 files=2 size=54.07MB
    stored statistics:
-     table: rows=1500000 size=54.21MB
+     table: rows=1500000 size=54.07MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=1177197
+   extrapolated-rows=disabled max-scan-range-rows=1177135
    mem-estimate=40.00MB mem-reservation=24.00MB thread-reservation=0
    tuple-ids=0 row-size=191B cardinality=1500000
    in pipelines: 00(GETNEXT)
@@ -3033,23 +3033,23 @@ PLAN-ROOT SINK
 |  |  in pipelines: 08(GETNEXT), 09(OPEN)
 |  |
 |  |--09:SCAN HDFS [tpch_parquet.orders]
-|  |     partitions=1/1 files=2 size=54.21MB
+|  |     partitions=1/1 files=2 size=54.07MB
 |  |     stored statistics:
-|  |       table: rows=1500000 size=54.21MB
+|  |       table: rows=1500000 size=54.07MB
 |  |       columns: all
-|  |     extrapolated-rows=disabled max-scan-range-rows=1177197
+|  |     extrapolated-rows=disabled max-scan-range-rows=1177135
 |  |     mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=1
 |  |     tuple-ids=6 row-size=8B cardinality=1500000
 |  |     in pipelines: 09(GETNEXT)
 |  |
 |  08:SCAN HDFS [tpch_parquet.lineitem]
-|     partitions=1/1 files=3 size=193.99MB
+|     partitions=1/1 files=3 size=193.72MB
 |     predicates: l_shipmode = 'F'
 |     runtime filters: RF004[bloom] -> l_orderkey
 |     stored statistics:
-|       table: rows=6001215 size=193.99MB
+|       table: rows=6001215 size=193.72MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=2141664
+|     extrapolated-rows=disabled max-scan-range-rows=2141530
 |     parquet statistics predicates: l_shipmode = 'F'
 |     parquet dictionary predicates: l_shipmode = 'F'
 |     mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=1
@@ -3065,12 +3065,12 @@ PLAN-ROOT SINK
 |  |  in pipelines: 05(GETNEXT), 06(OPEN)
 |  |
 |  |--06:SCAN HDFS [tpch_parquet.orders]
-|  |     partitions=1/1 files=2 size=54.21MB
+|  |     partitions=1/1 files=2 size=54.07MB
 |  |     predicates: o_orderpriority = '2-HIGH'
 |  |     stored statistics:
-|  |       table: rows=1500000 size=54.21MB
+|  |       table: rows=1500000 size=54.07MB
 |  |       columns: all
-|  |     extrapolated-rows=disabled max-scan-range-rows=1177197
+|  |     extrapolated-rows=disabled max-scan-range-rows=1177135
 |  |     parquet statistics predicates: o_orderpriority = '2-HIGH'
 |  |     parquet dictionary predicates: o_orderpriority = '2-HIGH'
 |  |     mem-estimate=40.00MB mem-reservation=8.00MB thread-reservation=1
@@ -3078,12 +3078,12 @@ PLAN-ROOT SINK
 |  |     in pipelines: 06(GETNEXT)
 |  |
 |  05:SCAN HDFS [tpch_parquet.lineitem]
-|     partitions=1/1 files=3 size=193.99MB
+|     partitions=1/1 files=3 size=193.72MB
 |     runtime filters: RF002[bloom] -> l_orderkey
 |     stored statistics:
-|       table: rows=6001215 size=193.99MB
+|       table: rows=6001215 size=193.72MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=2141664
+|     extrapolated-rows=disabled max-scan-range-rows=2141530
 |     mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=1
 |     tuple-ids=3 row-size=70B cardinality=6001215
 |     in pipelines: 05(GETNEXT)
@@ -3103,23 +3103,23 @@ PLAN-ROOT SINK
 |  in pipelines: 01(GETNEXT), 02(OPEN)
 |
 |--02:SCAN HDFS [tpch_parquet.orders]
-|     partitions=1/1 files=2 size=54.21MB
+|     partitions=1/1 files=2 size=54.07MB
 |     stored statistics:
-|       table: rows=1500000 size=54.21MB
+|       table: rows=1500000 size=54.07MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=1177197
+|     extrapolated-rows=disabled max-scan-range-rows=1177135
 |     mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=1
 |     tuple-ids=1 row-size=8B cardinality=1500000
 |     in pipelines: 02(GETNEXT)
 |
 01:SCAN HDFS [tpch_parquet.lineitem]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    predicates: l_tax > 10
    runtime filters: RF000[bloom] -> l_orderkey
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    parquet statistics predicates: l_tax > 10
    parquet dictionary predicates: l_tax > 10
    mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=1
@@ -3127,20 +3127,20 @@ PLAN-ROOT SINK
    in pipelines: 01(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=123.75MB Threads=12
-Per-Host Resource Estimates: Memory=348MB
+Per-Host Resource Estimates: Memory=385MB
 
 F09:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.22MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 17:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.22MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=7 row-size=70B cardinality=2549844
 |  in pipelines: 14(GETNEXT), 05(GETNEXT), 08(GETNEXT)
 |
 F08:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
-Per-Host Resources: mem-estimate=99.00MB mem-reservation=43.00MB thread-reservation=2 runtime-filters-memory=2.00MB
+Per-Host Resources: mem-estimate=109.02MB mem-reservation=43.00MB thread-reservation=2 runtime-filters-memory=2.00MB
 00:UNION
 |  pass-through-operands: 14
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
@@ -3156,30 +3156,30 @@ Per-Host Resources: mem-estimate=99.00MB mem-reservation=43.00MB thread-reservat
 |  |  in pipelines: 08(GETNEXT), 09(OPEN)
 |  |
 |  |--16:EXCHANGE [BROADCAST]
-|  |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  |  mem-estimate=10.02MB mem-reservation=0B thread-reservation=0
 |  |  |  tuple-ids=6 row-size=8B cardinality=1500000
 |  |  |  in pipelines: 09(GETNEXT)
 |  |  |
 |  |  F07:PLAN FRAGMENT [RANDOM] hosts=2 instances=2
 |  |  Per-Host Resources: mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=2
 |  |  09:SCAN HDFS [tpch_parquet.orders, RANDOM]
-|  |     partitions=1/1 files=2 size=54.21MB
+|  |     partitions=1/1 files=2 size=54.07MB
 |  |     stored statistics:
-|  |       table: rows=1500000 size=54.21MB
+|  |       table: rows=1500000 size=54.07MB
 |  |       columns: all
-|  |     extrapolated-rows=disabled max-scan-range-rows=1177197
+|  |     extrapolated-rows=disabled max-scan-range-rows=1177135
 |  |     mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=1
 |  |     tuple-ids=6 row-size=8B cardinality=1500000
 |  |     in pipelines: 09(GETNEXT)
 |  |
 |  08:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-|     partitions=1/1 files=3 size=193.99MB
+|     partitions=1/1 files=3 size=193.72MB
 |     predicates: l_shipmode = 'F'
 |     runtime filters: RF004[bloom] -> l_orderkey
 |     stored statistics:
-|       table: rows=6001215 size=193.99MB
+|       table: rows=6001215 size=193.72MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=2141664
+|     extrapolated-rows=disabled max-scan-range-rows=2141530
 |     parquet statistics predicates: l_shipmode = 'F'
 |     parquet dictionary predicates: l_shipmode = 'F'
 |     mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=1
@@ -3195,19 +3195,19 @@ Per-Host Resources: mem-estimate=99.00MB mem-reservation=43.00MB thread-reservat
 |  |  in pipelines: 05(GETNEXT), 06(OPEN)
 |  |
 |  |--15:EXCHANGE [BROADCAST]
-|  |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  |  mem-estimate=9.34MB mem-reservation=0B thread-reservation=0
 |  |  |  tuple-ids=4 row-size=32B cardinality=300000
 |  |  |  in pipelines: 06(GETNEXT)
 |  |  |
 |  |  F05:PLAN FRAGMENT [RANDOM] hosts=2 instances=2
 |  |  Per-Host Resources: mem-estimate=40.00MB mem-reservation=8.00MB thread-reservation=2
 |  |  06:SCAN HDFS [tpch_parquet.orders, RANDOM]
-|  |     partitions=1/1 files=2 size=54.21MB
+|  |     partitions=1/1 files=2 size=54.07MB
 |  |     predicates: o_orderpriority = '2-HIGH'
 |  |     stored statistics:
-|  |       table: rows=1500000 size=54.21MB
+|  |       table: rows=1500000 size=54.07MB
 |  |       columns: all
-|  |     extrapolated-rows=disabled max-scan-range-rows=1177197
+|  |     extrapolated-rows=disabled max-scan-range-rows=1177135
 |  |     parquet statistics predicates: o_orderpriority = '2-HIGH'
 |  |     parquet dictionary predicates: o_orderpriority = '2-HIGH'
 |  |     mem-estimate=40.00MB mem-reservation=8.00MB thread-reservation=1
@@ -3215,12 +3215,12 @@ Per-Host Resources: mem-estimate=99.00MB mem-reservation=43.00MB thread-reservat
 |  |     in pipelines: 06(GETNEXT)
 |  |
 |  05:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-|     partitions=1/1 files=3 size=193.99MB
+|     partitions=1/1 files=3 size=193.72MB
 |     runtime filters: RF002[bloom] -> l_orderkey
 |     stored statistics:
-|       table: rows=6001215 size=193.99MB
+|       table: rows=6001215 size=193.72MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=2141664
+|     extrapolated-rows=disabled max-scan-range-rows=2141530
 |     mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=1
 |     tuple-ids=3 row-size=70B cardinality=6001215
 |     in pipelines: 05(GETNEXT)
@@ -3232,12 +3232,12 @@ Per-Host Resources: mem-estimate=99.00MB mem-reservation=43.00MB thread-reservat
 |  in pipelines: 14(GETNEXT), 01(OPEN)
 |
 13:EXCHANGE [HASH(l_orderkey,l_partkey,l_suppkey,l_linenumber,l_comment)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.22MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=70B cardinality=575772
 |  in pipelines: 01(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=48.33MB mem-reservation=39.75MB thread-reservation=1 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=64.32MB mem-reservation=39.75MB thread-reservation=1 runtime-filters-memory=1.00MB
 04:AGGREGATE [STREAMING]
 |  group by: l_orderkey, l_partkey, l_suppkey, l_linenumber, l_comment
 |  mem-estimate=42.58MB mem-reservation=34.00MB spill-buffer=2.00MB thread-reservation=0
@@ -3253,37 +3253,37 @@ Per-Host Resources: mem-estimate=48.33MB mem-reservation=39.75MB thread-reservat
 |  in pipelines: 01(GETNEXT), 02(OPEN)
 |
 |--12:EXCHANGE [HASH(o_orderkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=5.75MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=8B cardinality=1500000
 |  |  in pipelines: 02(GETNEXT)
 |  |
 |  F01:PLAN FRAGMENT [RANDOM] hosts=2 instances=2
 |  Per-Host Resources: mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=2
 |  02:SCAN HDFS [tpch_parquet.orders, RANDOM]
-|     partitions=1/1 files=2 size=54.21MB
+|     partitions=1/1 files=2 size=54.07MB
 |     stored statistics:
-|       table: rows=1500000 size=54.21MB
+|       table: rows=1500000 size=54.07MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=1177197
+|     extrapolated-rows=disabled max-scan-range-rows=1177135
 |     mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=1
 |     tuple-ids=1 row-size=8B cardinality=1500000
 |     in pipelines: 02(GETNEXT)
 |
 11:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.24MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=78B cardinality=600122
 |  in pipelines: 01(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=81.00MB mem-reservation=25.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 01:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    predicates: l_tax > 10
    runtime filters: RF000[bloom] -> l_orderkey
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    parquet statistics predicates: l_tax > 10
    parquet dictionary predicates: l_tax > 10
    mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=1
@@ -3291,15 +3291,15 @@ Per-Host Resources: mem-estimate=81.00MB mem-reservation=25.00MB thread-reservat
    in pipelines: 01(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=243.75MB Threads=13
-Per-Host Resource Estimates: Memory=693MB
+Per-Host Resource Estimates: Memory=724MB
 
 F09:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.44MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 17:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.44MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=7 row-size=70B cardinality=2549844
 |  in pipelines: 14(GETNEXT), 05(GETNEXT), 08(GETNEXT)
 |
@@ -3328,30 +3328,30 @@ Per-Host Resources: mem-estimate=198.00MB mem-reservation=86.00MB thread-reserva
 |  |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |  |
 |  |  16:EXCHANGE [BROADCAST]
-|  |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  |  mem-estimate=10.05MB mem-reservation=0B thread-reservation=0
 |  |  |  tuple-ids=6 row-size=8B cardinality=1500000
 |  |  |  in pipelines: 09(GETNEXT)
 |  |  |
 |  |  F07:PLAN FRAGMENT [RANDOM] hosts=2 instances=4
 |  |  Per-Host Resources: mem-estimate=80.00MB mem-reservation=8.00MB thread-reservation=2
 |  |  09:SCAN HDFS [tpch_parquet.orders, RANDOM]
-|  |     partitions=1/1 files=2 size=54.21MB
+|  |     partitions=1/1 files=2 size=54.07MB
 |  |     stored statistics:
-|  |       table: rows=1500000 size=54.21MB
+|  |       table: rows=1500000 size=54.07MB
 |  |       columns: all
-|  |     extrapolated-rows=disabled max-scan-range-rows=1177197
+|  |     extrapolated-rows=disabled max-scan-range-rows=1177135
 |  |     mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=0
 |  |     tuple-ids=6 row-size=8B cardinality=1500000
 |  |     in pipelines: 09(GETNEXT)
 |  |
 |  08:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-|     partitions=1/1 files=3 size=193.99MB
+|     partitions=1/1 files=3 size=193.72MB
 |     predicates: l_shipmode = 'F'
 |     runtime filters: RF004[bloom] -> l_orderkey
 |     stored statistics:
-|       table: rows=6001215 size=193.99MB
+|       table: rows=6001215 size=193.72MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=2141664
+|     extrapolated-rows=disabled max-scan-range-rows=2141530
 |     parquet statistics predicates: l_shipmode = 'F'
 |     parquet dictionary predicates: l_shipmode = 'F'
 |     mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=0
@@ -3375,19 +3375,19 @@ Per-Host Resources: mem-estimate=198.00MB mem-reservation=86.00MB thread-reserva
 |  |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |  |
 |  |  15:EXCHANGE [BROADCAST]
-|  |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  |  mem-estimate=9.41MB mem-reservation=0B thread-reservation=0
 |  |  |  tuple-ids=4 row-size=32B cardinality=300000
 |  |  |  in pipelines: 06(GETNEXT)
 |  |  |
 |  |  F05:PLAN FRAGMENT [RANDOM] hosts=2 instances=4
 |  |  Per-Host Resources: mem-estimate=80.00MB mem-reservation=16.00MB thread-reservation=2
 |  |  06:SCAN HDFS [tpch_parquet.orders, RANDOM]
-|  |     partitions=1/1 files=2 size=54.21MB
+|  |     partitions=1/1 files=2 size=54.07MB
 |  |     predicates: o_orderpriority = '2-HIGH'
 |  |     stored statistics:
-|  |       table: rows=1500000 size=54.21MB
+|  |       table: rows=1500000 size=54.07MB
 |  |       columns: all
-|  |     extrapolated-rows=disabled max-scan-range-rows=1177197
+|  |     extrapolated-rows=disabled max-scan-range-rows=1177135
 |  |     parquet statistics predicates: o_orderpriority = '2-HIGH'
 |  |     parquet dictionary predicates: o_orderpriority = '2-HIGH'
 |  |     mem-estimate=40.00MB mem-reservation=8.00MB thread-reservation=0
@@ -3395,12 +3395,12 @@ Per-Host Resources: mem-estimate=198.00MB mem-reservation=86.00MB thread-reserva
 |  |     in pipelines: 06(GETNEXT)
 |  |
 |  05:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-|     partitions=1/1 files=3 size=193.99MB
+|     partitions=1/1 files=3 size=193.72MB
 |     runtime filters: RF002[bloom] -> l_orderkey
 |     stored statistics:
-|       table: rows=6001215 size=193.99MB
+|       table: rows=6001215 size=193.72MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=2141664
+|     extrapolated-rows=disabled max-scan-range-rows=2141530
 |     mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=0
 |     tuple-ids=3 row-size=70B cardinality=6001215
 |     in pipelines: 05(GETNEXT)
@@ -3412,12 +3412,12 @@ Per-Host Resources: mem-estimate=198.00MB mem-reservation=86.00MB thread-reserva
 |  in pipelines: 14(GETNEXT), 01(OPEN)
 |
 13:EXCHANGE [HASH(l_orderkey,l_partkey,l_suppkey,l_linenumber,l_comment)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.44MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=70B cardinality=575772
 |  in pipelines: 01(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=92.91MB mem-reservation=75.75MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=113.87MB mem-reservation=75.75MB thread-reservation=2 runtime-filters-memory=1.00MB
 04:AGGREGATE [STREAMING]
 |  group by: l_orderkey, l_partkey, l_suppkey, l_linenumber, l_comment
 |  mem-estimate=42.58MB mem-reservation=34.00MB spill-buffer=2.00MB thread-reservation=0
@@ -3441,37 +3441,37 @@ Per-Host Resources: mem-estimate=92.91MB mem-reservation=75.75MB thread-reservat
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  12:EXCHANGE [HASH(o_orderkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=5.77MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=8B cardinality=1500000
 |  |  in pipelines: 02(GETNEXT)
 |  |
 |  F01:PLAN FRAGMENT [RANDOM] hosts=2 instances=4
 |  Per-Host Resources: mem-estimate=80.00MB mem-reservation=8.00MB thread-reservation=2
 |  02:SCAN HDFS [tpch_parquet.orders, RANDOM]
-|     partitions=1/1 files=2 size=54.21MB
+|     partitions=1/1 files=2 size=54.07MB
 |     stored statistics:
-|       table: rows=1500000 size=54.21MB
+|       table: rows=1500000 size=54.07MB
 |       columns: all
-|     extrapolated-rows=disabled max-scan-range-rows=1177197
+|     extrapolated-rows=disabled max-scan-range-rows=1177135
 |     mem-estimate=40.00MB mem-reservation=4.00MB thread-reservation=0
 |     tuple-ids=1 row-size=8B cardinality=1500000
 |     in pipelines: 02(GETNEXT)
 |
 11:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.48MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=78B cardinality=600122
 |  in pipelines: 01(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=162.00MB mem-reservation=50.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 01:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.99MB
+   partitions=1/1 files=3 size=193.72MB
    predicates: l_tax > 10
    runtime filters: RF000[bloom] -> l_orderkey
    stored statistics:
-     table: rows=6001215 size=193.99MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141664
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    parquet statistics predicates: l_tax > 10
    parquet dictionary predicates: l_tax > 10
    mem-estimate=80.00MB mem-reservation=24.00MB thread-reservation=0
@@ -3609,22 +3609,22 @@ PLAN-ROOT SINK
    in pipelines: 02(GETNEXT)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=191.12MB Threads=11
-Per-Host Resource Estimates: Memory=524MB
+Per-Host Resource Estimates: Memory=567MB
 
 F07:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-es

<TRUNCATED>

[2/4] impala git commit: IMPALA-7351: Add estimates to Exchange node

Posted by bi...@apache.org.
http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-planner/queries/PlannerTest/spillable-buffer-sizing.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-planner/queries/PlannerTest/spillable-buffer-sizing.test b/testdata/workloads/functional-planner/queries/PlannerTest/spillable-buffer-sizing.test
index b33a2c7..4e92766 100644
--- a/testdata/workloads/functional-planner/queries/PlannerTest/spillable-buffer-sizing.test
+++ b/testdata/workloads/functional-planner/queries/PlannerTest/spillable-buffer-sizing.test
@@ -4,20 +4,20 @@ from tpch_parquet.customer
     inner join tpch_parquet.nation on c_nationkey = n_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=18.97MB Threads=5
-Per-Host Resource Estimates: Memory=43MB
+Per-Host Resource Estimates: Memory=53MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.35MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.35MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=355B cardinality=150000
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=1 instances=1
-Per-Host Resources: mem-estimate=26.94MB mem-reservation=18.94MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=26.95MB mem-reservation=18.94MB thread-reservation=2 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: c_nationkey = n_nationkey
 |  fk/pk conjuncts: c_nationkey = n_nationkey
@@ -27,7 +27,7 @@ Per-Host Resources: mem-estimate=26.94MB mem-reservation=18.94MB thread-reservat
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=117B cardinality=25
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -55,15 +55,15 @@ Per-Host Resources: mem-estimate=26.94MB mem-reservation=18.94MB thread-reservat
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=37.94MB Threads=5
-Per-Host Resource Estimates: Memory=86MB
+Per-Host Resource Estimates: Memory=97MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.71MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.71MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=355B cardinality=150000
 |  in pipelines: 00(GETNEXT)
 |
@@ -86,7 +86,7 @@ Per-Host Resources: mem-estimate=53.88MB mem-reservation=37.88MB thread-reservat
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=117B cardinality=25
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -119,20 +119,20 @@ from tpch_parquet.lineitem
     left join tpch_parquet.orders on l_orderkey = o_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=98.00MB Threads=5
-Per-Host Resource Estimates: Memory=420MB
+Per-Host Resource Estimates: Memory=442MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.35MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.35MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1N row-size=454B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
-Per-Host Resources: mem-estimate=380.41MB mem-reservation=74.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=390.80MB mem-reservation=74.00MB thread-reservation=2
 02:HASH JOIN [LEFT OUTER JOIN, BROADCAST]
 |  hash predicates: l_orderkey = o_orderkey
 |  fk/pk conjuncts: l_orderkey = o_orderkey
@@ -141,7 +141,7 @@ Per-Host Resources: mem-estimate=380.41MB mem-reservation=74.00MB thread-reserva
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.38MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -158,25 +158,25 @@ Per-Host Resources: mem-estimate=380.41MB mem-reservation=74.00MB thread-reserva
 |     in pipelines: 01(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=196.00MB Threads=5
-Per-Host Resource Estimates: Memory=841MB
+Per-Host Resource Estimates: Memory=854MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=12.71MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=12.71MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1N row-size=454B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -198,7 +198,7 @@ Per-Host Resources: mem-estimate=760.83MB mem-reservation=148.00MB thread-reserv
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.76MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=191B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -215,11 +215,11 @@ Per-Host Resources: mem-estimate=760.83MB mem-reservation=148.00MB thread-reserv
 |     in pipelines: 01(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=0
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -230,20 +230,20 @@ from tpch_parquet.orders
     join /*+shuffle*/ tpch_parquet.customer on o_custkey = c_custkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=76.00MB Threads=6
-Per-Host Resource Estimates: Memory=100MB
+Per-Host Resource Estimates: Memory=131MB
 
 F03:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.85MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 05:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.85MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=428B cardinality=1500000
 |  in pipelines: 00(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(o_custkey)] hosts=2 instances=2
-Per-Host Resources: mem-estimate=35.00MB mem-reservation=35.00MB thread-reservation=1 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=55.62MB mem-reservation=35.00MB thread-reservation=1 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, PARTITIONED]
 |  hash predicates: o_custkey = c_custkey
 |  fk/pk conjuncts: o_custkey = c_custkey
@@ -253,7 +253,7 @@ Per-Host Resources: mem-estimate=35.00MB mem-reservation=35.00MB thread-reservat
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--04:EXCHANGE [HASH(c_custkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.24MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=238B cardinality=150000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -270,7 +270,7 @@ Per-Host Resources: mem-estimate=35.00MB mem-reservation=35.00MB thread-reservat
 |     in pipelines: 01(GETNEXT)
 |
 03:EXCHANGE [HASH(o_custkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.38MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=191B cardinality=1500000
 |  in pipelines: 00(GETNEXT)
 |
@@ -288,20 +288,20 @@ Per-Host Resources: mem-estimate=41.00MB mem-reservation=25.00MB thread-reservat
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=118.00MB Threads=7
-Per-Host Resource Estimates: Memory=166MB
+Per-Host Resource Estimates: Memory=199MB
 
 F03:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.70MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 05:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.70MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=428B cardinality=1500000
 |  in pipelines: 00(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(o_custkey)] hosts=2 instances=4
-Per-Host Resources: mem-estimate=36.00MB mem-reservation=36.00MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=57.52MB mem-reservation=36.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, PARTITIONED]
 |  hash-table-id=00
 |  hash predicates: o_custkey = c_custkey
@@ -319,7 +319,7 @@ Per-Host Resources: mem-estimate=36.00MB mem-reservation=36.00MB thread-reservat
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  04:EXCHANGE [HASH(c_custkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.47MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=238B cardinality=150000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -336,7 +336,7 @@ Per-Host Resources: mem-estimate=36.00MB mem-reservation=36.00MB thread-reservat
 |     in pipelines: 01(GETNEXT)
 |
 03:EXCHANGE [HASH(o_custkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.76MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=191B cardinality=1500000
 |  in pipelines: 00(GETNEXT)
 |
@@ -359,20 +359,20 @@ from tpch_parquet.orders
     join /*+broadcast*/ tpch_parquet.customer on o_custkey = c_custkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=75.00MB Threads=5
-Per-Host Resource Estimates: Memory=102MB
+Per-Host Resource Estimates: Memory=123MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.85MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.85MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=428B cardinality=1500000
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=2 instances=2
-Per-Host Resources: mem-estimate=78.38MB mem-reservation=59.00MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=88.62MB mem-reservation=59.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 02:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: o_custkey = c_custkey
 |  fk/pk conjuncts: o_custkey = c_custkey
@@ -382,7 +382,7 @@ Per-Host Resources: mem-estimate=78.38MB mem-reservation=59.00MB thread-reservat
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.24MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=238B cardinality=150000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -410,15 +410,15 @@ Per-Host Resources: mem-estimate=78.38MB mem-reservation=59.00MB thread-reservat
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=150.00MB Threads=5
-Per-Host Resource Estimates: Memory=205MB
+Per-Host Resource Estimates: Memory=216MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.70MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.70MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1 row-size=428B cardinality=1500000
 |  in pipelines: 00(GETNEXT)
 |
@@ -441,7 +441,7 @@ Per-Host Resources: mem-estimate=156.76MB mem-reservation=118.00MB thread-reserv
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.47MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=238B cardinality=150000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -479,12 +479,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypes, functional_parquet.alltypestiny
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=551.94KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=551.94KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1N row-size=176B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -498,7 +498,7 @@ Per-Host Resources: mem-estimate=2.02GB mem-reservation=34.09MB thread-reservati
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=275.91KB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=88B cardinality=unavailable
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -516,7 +516,7 @@ Per-Host Resources: mem-estimate=2.02GB mem-reservation=34.09MB thread-reservati
 |     in pipelines: 01(GETNEXT)
 |
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=188.92KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -532,12 +532,12 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypestiny
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=1.08MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=1.08MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0,1N row-size=176B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -559,7 +559,7 @@ Per-Host Resources: mem-estimate=4.03GB mem-reservation=68.17MB thread-reservati
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  03:EXCHANGE [BROADCAST]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=551.91KB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=88B cardinality=unavailable
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -577,7 +577,7 @@ Per-Host Resources: mem-estimate=4.03GB mem-reservation=68.17MB thread-reservati
 |     in pipelines: 01(GETNEXT)
 |
 00:SCAN HDFS [functional_parquet.alltypes, RANDOM]
-   partitions=24/24 files=24 size=188.92KB
+   partitions=24/24 files=24 size=188.54KB
    stored statistics:
      table: rows=unavailable size=unavailable
      partitions: 0/24 rows=unavailable
@@ -596,17 +596,17 @@ Max Per-Host Resource Reservation: Memory=5.94MB Threads=4
 Per-Host Resource Estimates: Memory=44MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=16.00KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=10B cardinality=25
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(c_nationkey)] hosts=1 instances=1
-Per-Host Resources: mem-estimate=10.00MB mem-reservation=1.94MB thread-reservation=1
+Per-Host Resources: mem-estimate=10.02MB mem-reservation=1.94MB thread-reservation=1
 03:AGGREGATE [FINALIZE]
 |  output: avg:merge(c_acctbal)
 |  group by: c_nationkey
@@ -615,7 +615,7 @@ Per-Host Resources: mem-estimate=10.00MB mem-reservation=1.94MB thread-reservati
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(c_nationkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=10B cardinality=25
 |  in pipelines: 00(GETNEXT)
 |
@@ -642,17 +642,17 @@ Max Per-Host Resource Reservation: Memory=11.88MB Threads=5
 Per-Host Resource Estimates: Memory=88MB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=16.00KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=10B cardinality=25
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(c_nationkey)] hosts=1 instances=2
-Per-Host Resources: mem-estimate=20.00MB mem-reservation=3.88MB thread-reservation=2
+Per-Host Resources: mem-estimate=20.03MB mem-reservation=3.88MB thread-reservation=2
 03:AGGREGATE [FINALIZE]
 |  output: avg:merge(c_acctbal)
 |  group by: c_nationkey
@@ -661,7 +661,7 @@ Per-Host Resources: mem-estimate=20.00MB mem-reservation=3.88MB thread-reservati
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(c_nationkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=16.00KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=10B cardinality=25
 |  in pipelines: 00(GETNEXT)
 |
@@ -692,20 +692,20 @@ group by 1, 2
 having count(*) = 1
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=99.00MB Threads=7
-Per-Host Resource Estimates: Memory=227MB
+Per-Host Resource Estimates: Memory=267MB
 
 F04:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.11MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 08:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.11MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=33B cardinality=4690314
 |  in pipelines: 07(GETNEXT)
 |
 F03:PLAN FRAGMENT [HASH(l_orderkey,o_orderstatus)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=34.00MB mem-reservation=34.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=44.11MB mem-reservation=34.00MB thread-reservation=1
 07:AGGREGATE [FINALIZE]
 |  output: count:merge(*)
 |  group by: l_orderkey, o_orderstatus
@@ -715,12 +715,12 @@ Per-Host Resources: mem-estimate=34.00MB mem-reservation=34.00MB thread-reservat
 |  in pipelines: 07(GETNEXT), 00(OPEN)
 |
 06:EXCHANGE [HASH(l_orderkey,o_orderstatus)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.11MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=33B cardinality=4690314
 |  in pipelines: 00(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=72.12MB mem-reservation=52.00MB thread-reservation=1 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=92.22MB mem-reservation=52.00MB thread-reservation=1 runtime-filters-memory=1.00MB
 03:AGGREGATE [STREAMING]
 |  output: count(*)
 |  group by: l_orderkey, o_orderstatus
@@ -737,7 +737,7 @@ Per-Host Resources: mem-estimate=72.12MB mem-reservation=52.00MB thread-reservat
 |  in pipelines: 00(GETNEXT), 01(OPEN)
 |
 |--05:EXCHANGE [HASH(o_orderkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.06MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=25B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -754,38 +754,38 @@ Per-Host Resources: mem-estimate=72.12MB mem-reservation=52.00MB thread-reservat
 |     in pipelines: 01(GETNEXT)
 |
 04:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.04MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=8B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=3
 Per-Host Resources: mem-estimate=81.00MB mem-reservation=5.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    runtime filters: RF000[bloom] -> l_orderkey
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=1
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=147.00MB Threads=9
-Per-Host Resource Estimates: Memory=363MB
+Per-Host Resource Estimates: Memory=414MB
 
 F04:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.22MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 08:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.22MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=33B cardinality=4690314
 |  in pipelines: 07(GETNEXT)
 |
 F03:PLAN FRAGMENT [HASH(l_orderkey,o_orderstatus)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=34.00MB mem-reservation=34.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=54.43MB mem-reservation=34.00MB thread-reservation=2
 07:AGGREGATE [FINALIZE]
 |  output: count:merge(*)
 |  group by: l_orderkey, o_orderstatus
@@ -795,12 +795,12 @@ Per-Host Resources: mem-estimate=34.00MB mem-reservation=34.00MB thread-reservat
 |  in pipelines: 07(GETNEXT), 00(OPEN)
 |
 06:EXCHANGE [HASH(l_orderkey,o_orderstatus)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.22MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=2 row-size=33B cardinality=4690314
 |  in pipelines: 00(GETNEXT)
 |
 F02:PLAN FRAGMENT [HASH(l_orderkey)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=87.00MB mem-reservation=87.00MB thread-reservation=2 runtime-filters-memory=1.00MB
+Per-Host Resources: mem-estimate=107.23MB mem-reservation=87.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 03:AGGREGATE [STREAMING]
 |  output: count(*)
 |  group by: l_orderkey, o_orderstatus
@@ -825,7 +825,7 @@ Per-Host Resources: mem-estimate=87.00MB mem-reservation=87.00MB thread-reservat
 |  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |  |
 |  05:EXCHANGE [HASH(o_orderkey)]
-|  |  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  |  mem-estimate=10.11MB mem-reservation=0B thread-reservation=0
 |  |  tuple-ids=1 row-size=25B cardinality=1500000
 |  |  in pipelines: 01(GETNEXT)
 |  |
@@ -842,19 +842,19 @@ Per-Host Resources: mem-estimate=87.00MB mem-reservation=87.00MB thread-reservat
 |     in pipelines: 01(GETNEXT)
 |
 04:EXCHANGE [HASH(l_orderkey)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.07MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=0 row-size=8B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
 F00:PLAN FRAGMENT [RANDOM] hosts=3 instances=6
 Per-Host Resources: mem-estimate=162.00MB mem-reservation=10.00MB thread-reservation=2 runtime-filters-memory=1.00MB
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    runtime filters: RF000[bloom] -> l_orderkey
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=4.00MB thread-reservation=0
    tuple-ids=0 row-size=8B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -864,20 +864,20 @@ select distinct *
 from tpch_parquet.lineitem
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=108.00MB Threads=4
-Per-Host Resource Estimates: Memory=3.31GB
+Per-Host Resource Estimates: Memory=3.33GB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=10.78MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(tpch_parquet.lineitem.l_orderkey,tpch_parquet.lineitem.l_partkey,tpch_parquet.lineitem.l_suppkey,tpch_parquet.lineitem.l_linenumber,tpch_parquet.lineitem.l_quantity,tpch_parquet.lineitem.l_extendedprice,tpch_parquet.lineitem.l_discount,tpch_parquet.lineitem.l_tax,tpch_parquet.lineitem.l_returnflag,tpch_parquet.lineitem.l_linestatus,tpch_parquet.lineitem.l_shipdate,tpch_parquet.lineitem.l_commitdate,tpch_parquet.lineitem.l_receiptdate,tpch_parquet.lineitem.l_shipinstruct,tpch_parquet.lineitem.l_shipmode,tpch_parquet.lineitem.l_comment)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=1.62GB mem-reservation=34.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=1.63GB mem-reservation=34.00MB thread-reservation=1
 03:AGGREGATE [FINALIZE]
 |  group by: tpch_parquet.lineitem.l_orderkey, tpch_parquet.lineitem.l_partkey, tpch_parquet.lineitem.l_suppkey, tpch_parquet.lineitem.l_linenumber, tpch_parquet.lineitem.l_quantity, tpch_parquet.lineitem.l_extendedprice, tpch_parquet.lineitem.l_discount, tpch_parquet.lineitem.l_tax, tpch_parquet.lineitem.l_returnflag, tpch_parquet.lineitem.l_linestatus, tpch_parquet.lineitem.l_shipdate, tpch_parquet.lineitem.l_commitdate, tpch_parquet.lineitem.l_receiptdate, tpch_parquet.lineitem.l_shipinstruct, tpch_parquet.lineitem.l_shipmode, tpch_parquet.lineitem.l_comment
 |  mem-estimate=1.62GB mem-reservation=34.00MB spill-buffer=2.00MB thread-reservation=0
@@ -885,7 +885,7 @@ Per-Host Resources: mem-estimate=1.62GB mem-reservation=34.00MB thread-reservati
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(tpch_parquet.lineitem.l_orderkey,tpch_parquet.lineitem.l_partkey,tpch_parquet.lineitem.l_suppkey,tpch_parquet.lineitem.l_linenumber,tpch_parquet.lineitem.l_quantity,tpch_parquet.lineitem.l_extendedprice,tpch_parquet.lineitem.l_discount,tpch_parquet.lineitem.l_tax,tpch_parquet.lineitem.l_returnflag,tpch_parquet.lineitem.l_linestatus,tpch_parquet.lineitem.l_shipdate,tpch_parquet.lineitem.l_commitdate,tpch_parquet.lineitem.l_receiptdate,tpch_parquet.lineitem.l_shipinstruct,tpch_parquet.lineitem.l_shipmode,tpch_parquet.lineitem.l_comment)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=10.78MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -898,30 +898,30 @@ Per-Host Resources: mem-estimate=1.69GB mem-reservation=74.00MB thread-reservati
 |  in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=1
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=216.00MB Threads=5
-Per-Host Resource Estimates: Memory=6.62GB
+Per-Host Resource Estimates: Memory=6.65GB
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=11.56MB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.56MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(tpch_parquet.lineitem.l_orderkey,tpch_parquet.lineitem.l_partkey,tpch_parquet.lineitem.l_suppkey,tpch_parquet.lineitem.l_linenumber,tpch_parquet.lineitem.l_quantity,tpch_parquet.lineitem.l_extendedprice,tpch_parquet.lineitem.l_discount,tpch_parquet.lineitem.l_tax,tpch_parquet.lineitem.l_returnflag,tpch_parquet.lineitem.l_linestatus,tpch_parquet.lineitem.l_shipdate,tpch_parquet.lineitem.l_commitdate,tpch_parquet.lineitem.l_receiptdate,tpch_parquet.lineitem.l_shipinstruct,tpch_parquet.lineitem.l_shipmode,tpch_parquet.lineitem.l_comment)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=3.23GB mem-reservation=68.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=3.25GB mem-reservation=68.00MB thread-reservation=2
 03:AGGREGATE [FINALIZE]
 |  group by: tpch_parquet.lineitem.l_orderkey, tpch_parquet.lineitem.l_partkey, tpch_parquet.lineitem.l_suppkey, tpch_parquet.lineitem.l_linenumber, tpch_parquet.lineitem.l_quantity, tpch_parquet.lineitem.l_extendedprice, tpch_parquet.lineitem.l_discount, tpch_parquet.lineitem.l_tax, tpch_parquet.lineitem.l_returnflag, tpch_parquet.lineitem.l_linestatus, tpch_parquet.lineitem.l_shipdate, tpch_parquet.lineitem.l_commitdate, tpch_parquet.lineitem.l_receiptdate, tpch_parquet.lineitem.l_shipinstruct, tpch_parquet.lineitem.l_shipmode, tpch_parquet.lineitem.l_comment
 |  mem-estimate=1.62GB mem-reservation=34.00MB spill-buffer=2.00MB thread-reservation=0
@@ -929,7 +929,7 @@ Per-Host Resources: mem-estimate=3.23GB mem-reservation=68.00MB thread-reservati
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(tpch_parquet.lineitem.l_orderkey,tpch_parquet.lineitem.l_partkey,tpch_parquet.lineitem.l_suppkey,tpch_parquet.lineitem.l_linenumber,tpch_parquet.lineitem.l_quantity,tpch_parquet.lineitem.l_extendedprice,tpch_parquet.lineitem.l_discount,tpch_parquet.lineitem.l_tax,tpch_parquet.lineitem.l_returnflag,tpch_parquet.lineitem.l_linestatus,tpch_parquet.lineitem.l_shipdate,tpch_parquet.lineitem.l_commitdate,tpch_parquet.lineitem.l_receiptdate,tpch_parquet.lineitem.l_shipinstruct,tpch_parquet.lineitem.l_shipmode,tpch_parquet.lineitem.l_comment)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=11.56MB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=263B cardinality=6001215
 |  in pipelines: 00(GETNEXT)
 |
@@ -942,11 +942,11 @@ Per-Host Resources: mem-estimate=3.39GB mem-reservation=148.00MB thread-reservat
 |  in pipelines: 00(GETNEXT)
 |
 00:SCAN HDFS [tpch_parquet.lineitem, RANDOM]
-   partitions=1/1 files=3 size=193.71MB
+   partitions=1/1 files=3 size=193.72MB
    stored statistics:
-     table: rows=6001215 size=193.71MB
+     table: rows=6001215 size=193.72MB
      columns: all
-   extrapolated-rows=disabled max-scan-range-rows=2141802
+   extrapolated-rows=disabled max-scan-range-rows=2141530
    mem-estimate=80.00MB mem-reservation=40.00MB thread-reservation=0
    tuple-ids=0 row-size=263B cardinality=6001215
    in pipelines: 00(GETNEXT)
@@ -962,17 +962,17 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypestiny
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=83.99KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=83.99KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=24B cardinality=unavailable
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(string_col)] hosts=3 instances=3
-Per-Host Resources: mem-estimate=128.00MB mem-reservation=34.00MB thread-reservation=1
+Per-Host Resources: mem-estimate=128.08MB mem-reservation=34.00MB thread-reservation=1
 03:AGGREGATE [FINALIZE]
 |  output: count:merge(*)
 |  group by: string_col
@@ -981,7 +981,7 @@ Per-Host Resources: mem-estimate=128.00MB mem-reservation=34.00MB thread-reserva
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(string_col)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=83.99KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=24B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |
@@ -1011,17 +1011,17 @@ WARNING: The following tables are missing relevant table and/or column statistic
 functional_parquet.alltypestiny
 
 F02:PLAN FRAGMENT [UNPARTITIONED] hosts=1 instances=1
-|  Per-Host Resources: mem-estimate=0B mem-reservation=0B thread-reservation=1
+|  Per-Host Resources: mem-estimate=167.99KB mem-reservation=0B thread-reservation=1
 PLAN-ROOT SINK
 |  mem-estimate=0B mem-reservation=0B thread-reservation=0
 |
 04:EXCHANGE [UNPARTITIONED]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=167.99KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=24B cardinality=unavailable
 |  in pipelines: 03(GETNEXT)
 |
 F01:PLAN FRAGMENT [HASH(string_col)] hosts=3 instances=6
-Per-Host Resources: mem-estimate=256.00MB mem-reservation=68.00MB thread-reservation=2
+Per-Host Resources: mem-estimate=256.33MB mem-reservation=68.00MB thread-reservation=2
 03:AGGREGATE [FINALIZE]
 |  output: count:merge(*)
 |  group by: string_col
@@ -1030,7 +1030,7 @@ Per-Host Resources: mem-estimate=256.00MB mem-reservation=68.00MB thread-reserva
 |  in pipelines: 03(GETNEXT), 00(OPEN)
 |
 02:EXCHANGE [HASH(string_col)]
-|  mem-estimate=0B mem-reservation=0B thread-reservation=0
+|  mem-estimate=167.99KB mem-reservation=0B thread-reservation=0
 |  tuple-ids=1 row-size=24B cardinality=unavailable
 |  in pipelines: 00(GETNEXT)
 |

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-planner/queries/PlannerTest/tpcds-all.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-planner/queries/PlannerTest/tpcds-all.test b/testdata/workloads/functional-planner/queries/PlannerTest/tpcds-all.test
index 6cdb497..133613f 100644
--- a/testdata/workloads/functional-planner/queries/PlannerTest/tpcds-all.test
+++ b/testdata/workloads/functional-planner/queries/PlannerTest/tpcds-all.test
@@ -102,7 +102,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> store_sales.ss_sold_date_sk, RF002 -> store_sales.ss_item_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=69.62MB Threads=11
-Per-Host Resource Estimates: Memory=166MB
+Per-Host Resource Estimates: Memory=168MB
 PLAN-ROOT SINK
 |
 12:MERGING-EXCHANGE [UNPARTITIONED]
@@ -233,7 +233,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_item_sk, RF002 -> ss_promo_sk, RF004 -> ss_cdemo_sk, RF006 -> ss_sold_date_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=54.31MB Threads=12
-Per-Host Resource Estimates: Memory=454MB
+Per-Host Resource Estimates: Memory=461MB
 PLAN-ROOT SINK
 |
 17:MERGING-EXCHANGE [UNPARTITIONED]
@@ -297,7 +297,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_item_sk, RF002 -> ss_promo_sk, RF004 -> ss_cdemo_sk, RF006 -> ss_sold_date_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=108.62MB Threads=13
-Per-Host Resource Estimates: Memory=397MB
+Per-Host Resource Estimates: Memory=398MB
 PLAN-ROOT SINK
 |
 17:MERGING-EXCHANGE [UNPARTITIONED]
@@ -500,7 +500,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> store_sales.ss_store_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=47.07MB Threads=13
-Per-Host Resource Estimates: Memory=327MB
+Per-Host Resource Estimates: Memory=328MB
 PLAN-ROOT SINK
 |
 20:MERGING-EXCHANGE [UNPARTITIONED]
@@ -763,7 +763,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> ca_address_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=54.13MB Threads=16
-Per-Host Resource Estimates: Memory=358MB
+Per-Host Resource Estimates: Memory=360MB
 PLAN-ROOT SINK
 |
 22:MERGING-EXCHANGE [UNPARTITIONED]
@@ -841,7 +841,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_store_sk, RF004 -> ss_customer_sk, RF006 -> ss_sold_date_sk, RF008 -> ss_item_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=108.27MB Threads=19
-Per-Host Resource Estimates: Memory=299MB
+Per-Host Resource Estimates: Memory=303MB
 PLAN-ROOT SINK
 |
 22:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1017,7 +1017,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_item_sk, RF002 -> ss_store_sk, RF004 -> ss_cdemo_sk, RF006 -> ss_sold_date_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=54.26MB Threads=12
-Per-Host Resource Estimates: Memory=454MB
+Per-Host Resource Estimates: Memory=462MB
 PLAN-ROOT SINK
 |
 17:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1081,7 +1081,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_item_sk, RF002 -> ss_store_sk, RF004 -> ss_cdemo_sk, RF006 -> ss_sold_date_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=108.52MB Threads=13
-Per-Host Resource Estimates: Memory=397MB
+Per-Host Resource Estimates: Memory=398MB
 PLAN-ROOT SINK
 |
 17:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1254,7 +1254,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> c_customer_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=56.01MB Threads=13
-Per-Host Resource Estimates: Memory=339MB
+Per-Host Resource Estimates: Memory=348MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1321,7 +1321,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpcds.store_sales.ss_customer_sk, RF002 -> store_sales.ss_store_sk, RF004 -> store_sales.ss_sold_date_sk, RF006 -> store_sales.ss_hdemo_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=95.02MB Threads=15
-Per-Host Resource Estimates: Memory=276MB
+Per-Host Resource Estimates: Memory=291MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1838,7 +1838,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> tpcds.store_sales.ss_customer_sk, RF004 -> store_sales.ss_addr_sk, RF006 -> store_sales.ss_store_sk, RF008 -> store_sales.ss_sold_date_sk, RF010 -> store_sales.ss_hdemo_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=130.70MB Threads=17
-Per-Host Resource Estimates: Memory=442MB
+Per-Host Resource Estimates: Memory=462MB
 PLAN-ROOT SINK
 |
 24:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1924,7 +1924,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> tpcds.store_sales.ss_customer_sk, RF004 -> store_sales.ss_addr_sk, RF006 -> store_sales.ss_store_sk, RF008 -> store_sales.ss_sold_date_sk, RF010 -> store_sales.ss_hdemo_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=259.52MB Threads=19
-Per-Host Resource Estimates: Memory=435MB
+Per-Host Resource Estimates: Memory=458MB
 PLAN-ROOT SINK
 |
 24:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2136,7 +2136,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> store_sales.ss_sold_date_sk, RF002 -> store_sales.ss_item_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=67.62MB Threads=9
-Per-Host Resource Estimates: Memory=164MB
+Per-Host Resource Estimates: Memory=165MB
 PLAN-ROOT SINK
 |
 11:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2689,7 +2689,7 @@ PLAN-ROOT SINK
    runtime filters: RF004 -> tpcds.store_sales.ss_store_sk, RF008 -> ss_sold_date_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=106.89MB Threads=20
-Per-Host Resource Estimates: Memory=589MB
+Per-Host Resource Estimates: Memory=606MB
 PLAN-ROOT SINK
 |
 30:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2796,7 +2796,7 @@ PLAN-ROOT SINK
    runtime filters: RF004 -> tpcds.store_sales.ss_store_sk, RF008 -> ss_sold_date_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=210.03MB Threads=23
-Per-Host Resource Estimates: Memory=470MB
+Per-Host Resource Estimates: Memory=491MB
 PLAN-ROOT SINK
 |
 30:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3275,7 +3275,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpcds.store_sales.ss_store_sk, RF002 -> tpcds.store_sales.ss_item_sk, RF004 -> tpcds.store_sales.ss_store_sk, RF006 -> ss_sold_date_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=76.51MB Threads=17
-Per-Host Resource Estimates: Memory=495MB
+Per-Host Resource Estimates: Memory=502MB
 PLAN-ROOT SINK
 |
 27:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3372,7 +3372,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpcds.store_sales.ss_store_sk, RF002 -> tpcds.store_sales.ss_item_sk, RF004 -> tpcds.store_sales.ss_store_sk, RF006 -> ss_sold_date_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=153.02MB Threads=21
-Per-Host Resource Estimates: Memory=381MB
+Per-Host Resource Estimates: Memory=392MB
 PLAN-ROOT SINK
 |
 27:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3601,7 +3601,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> tpcds.store_sales.ss_customer_sk, RF004 -> store_sales.ss_addr_sk, RF006 -> store_sales.ss_store_sk, RF008 -> store_sales.ss_sold_date_sk, RF010 -> store_sales.ss_hdemo_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=136.32MB Threads=16
-Per-Host Resource Estimates: Memory=511MB
+Per-Host Resource Estimates: Memory=530MB
 PLAN-ROOT SINK
 |
 23:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3685,7 +3685,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> tpcds.store_sales.ss_customer_sk, RF004 -> store_sales.ss_addr_sk, RF006 -> store_sales.ss_store_sk, RF008 -> store_sales.ss_sold_date_sk, RF010 -> store_sales.ss_hdemo_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=272.64MB Threads=17
-Per-Host Resource Estimates: Memory=574MB
+Per-Host Resource Estimates: Memory=596MB
 PLAN-ROOT SINK
 |
 23:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3879,7 +3879,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> c_customer_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=61.82MB Threads=13
-Per-Host Resource Estimates: Memory=336MB
+Per-Host Resource Estimates: Memory=347MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3945,7 +3945,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpcds.store_sales.ss_customer_sk, RF002 -> store_sales.ss_store_sk, RF004 -> store_sales.ss_sold_date_sk, RF006 -> store_sales.ss_hdemo_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=106.64MB Threads=15
-Per-Host Resource Estimates: Memory=271MB
+Per-Host Resource Estimates: Memory=290MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4118,7 +4118,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> c_customer_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=53.32MB Threads=13
-Per-Host Resource Estimates: Memory=327MB
+Per-Host Resource Estimates: Memory=335MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4184,7 +4184,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpcds.store_sales.ss_customer_sk, RF002 -> store_sales.ss_sold_date_sk, RF004 -> store_sales.ss_store_sk, RF006 -> store_sales.ss_hdemo_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=99.14MB Threads=15
-Per-Host Resource Estimates: Memory=263MB
+Per-Host Resource Estimates: Memory=275MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4707,7 +4707,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> i_item_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=58.81MB Threads=9
-Per-Host Resource Estimates: Memory=253MB
+Per-Host Resource Estimates: Memory=255MB
 PLAN-ROOT SINK
 |
 14:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4761,7 +4761,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_sold_date_sk, RF002 -> ss_item_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=115.75MB Threads=11
-Per-Host Resource Estimates: Memory=200MB
+Per-Host Resource Estimates: Memory=203MB
 PLAN-ROOT SINK
 |
 14:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4921,7 +4921,7 @@ PLAN-ROOT SINK
    runtime filters: RF004 -> s.ss_item_sk, RF006 -> s.ss_sold_date_sk, RF010 -> s.ss_customer_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=89.38MB Threads=19
-Per-Host Resource Estimates: Memory=450MB
+Per-Host Resource Estimates: Memory=453MB
 PLAN-ROOT SINK
 |
 30:MERGING-EXCHANGE [UNPARTITIONED]
@@ -5350,7 +5350,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_store_sk, RF002 -> ss_item_sk, RF004 -> ss_sold_date_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=393.21MB Threads=29
-Per-Host Resource Estimates: Memory=1.33GB
+Per-Host Resource Estimates: Memory=1.35GB
 PLAN-ROOT SINK
 |
 54:MERGING-EXCHANGE [UNPARTITIONED]
@@ -5536,7 +5536,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ss_store_sk, RF002 -> ss_item_sk, RF004 -> ss_sold_date_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=752.42MB Threads=33
-Per-Host Resource Estimates: Memory=1.33GB
+Per-Host Resource Estimates: Memory=1.35GB
 PLAN-ROOT SINK
 |
 54:MERGING-EXCHANGE [UNPARTITIONED]
@@ -5918,7 +5918,7 @@ PLAN-ROOT SINK
    runtime filters: RF010 -> ss_sold_date_sk, RF008 -> ss_item_sk, RF006 -> ss_promo_sk, RF002 -> ss_customer_sk, RF004 -> ss_store_sk
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=121.39MB Threads=30
-Per-Host Resource Estimates: Memory=753MB
+Per-Host Resource Estimates: Memory=755MB
 PLAN-ROOT SINK
 |
 27:SORT
@@ -6066,7 +6066,7 @@ PLAN-ROOT SINK
    runtime filters: RF010 -> ss_sold_date_sk, RF008 -> ss_item_sk, RF006 -> ss_promo_sk, RF002 -> ss_customer_sk, RF004 -> ss_store_sk
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=236.78MB Threads=32
-Per-Host Resource Estimates: Memory=617MB
+Per-Host Resource Estimates: Memory=622MB
 PLAN-ROOT SINK
 |
 27:SORT

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-planner/queries/PlannerTest/tpch-all.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-planner/queries/PlannerTest/tpch-all.test b/testdata/workloads/functional-planner/queries/PlannerTest/tpch-all.test
index 510b47b..080e84a 100644
--- a/testdata/workloads/functional-planner/queries/PlannerTest/tpch-all.test
+++ b/testdata/workloads/functional-planner/queries/PlannerTest/tpch-all.test
@@ -212,7 +212,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpch.partsupp.ps_partkey, RF008 -> ps_suppkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=65.28MB Threads=21
-Per-Host Resource Estimates: Memory=656MB
+Per-Host Resource Estimates: Memory=662MB
 PLAN-ROOT SINK
 |
 30:MERGING-EXCHANGE [UNPARTITIONED]
@@ -319,7 +319,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpch.partsupp.ps_partkey, RF008 -> ps_suppkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=126.81MB Threads=23
-Per-Host Resource Estimates: Memory=703MB
+Per-Host Resource Estimates: Memory=713MB
 PLAN-ROOT SINK
 |
 30:MERGING-EXCHANGE [UNPARTITIONED]
@@ -517,7 +517,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> l_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=41.38MB Threads=8
-Per-Host Resource Estimates: Memory=537MB
+Per-Host Resource Estimates: Memory=546MB
 PLAN-ROOT SINK
 |
 11:MERGING-EXCHANGE [UNPARTITIONED]
@@ -564,7 +564,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> l_orderkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=82.75MB Threads=9
-Per-Host Resource Estimates: Memory=483MB
+Per-Host Resource Estimates: Memory=484MB
 PLAN-ROOT SINK
 |
 11:MERGING-EXCHANGE [UNPARTITIONED]
@@ -667,7 +667,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> l_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=42.44MB Threads=7
-Per-Host Resource Estimates: Memory=482MB
+Per-Host Resource Estimates: Memory=497MB
 PLAN-ROOT SINK
 |
 09:MERGING-EXCHANGE [UNPARTITIONED]
@@ -704,7 +704,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> l_orderkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=77.38MB Threads=9
-Per-Host Resource Estimates: Memory=430MB
+Per-Host Resource Estimates: Memory=450MB
 PLAN-ROOT SINK
 |
 09:MERGING-EXCHANGE [UNPARTITIONED]
@@ -828,7 +828,7 @@ PLAN-ROOT SINK
    runtime filters: RF005 -> l_suppkey, RF010 -> l_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=70.14MB Threads=14
-Per-Host Resource Estimates: Memory=660MB
+Per-Host Resource Estimates: Memory=668MB
 PLAN-ROOT SINK
 |
 20:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1149,7 +1149,7 @@ PLAN-ROOT SINK
    runtime filters: RF006 -> l_suppkey, RF008 -> l_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=103.95MB Threads=15
-Per-Host Resource Estimates: Memory=689MB
+Per-Host Resource Estimates: Memory=723MB
 PLAN-ROOT SINK
 |
 21:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1225,7 +1225,7 @@ PLAN-ROOT SINK
    runtime filters: RF006 -> l_suppkey, RF008 -> l_orderkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=194.78MB Threads=17
-Per-Host Resource Estimates: Memory=683MB
+Per-Host Resource Estimates: Memory=716MB
 PLAN-ROOT SINK
 |
 21:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1432,7 +1432,7 @@ PLAN-ROOT SINK
    runtime filters: RF004 -> c_nationkey, RF006 -> c_custkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=73.34MB Threads=21
-Per-Host Resource Estimates: Memory=751MB
+Per-Host Resource Estimates: Memory=759MB
 PLAN-ROOT SINK
 |
 29:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1532,7 +1532,7 @@ PLAN-ROOT SINK
    runtime filters: RF008 -> l_suppkey, RF010 -> l_orderkey, RF012 -> l_partkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=142.92MB Threads=25
-Per-Host Resource Estimates: Memory=715MB
+Per-Host Resource Estimates: Memory=726MB
 PLAN-ROOT SINK
 |
 29:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1747,7 +1747,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> l_partkey, RF003 -> l_suppkey, RF006 -> l_suppkey, RF008 -> l_orderkey, RF010 -> l_partkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=140.70MB Threads=15
-Per-Host Resource Estimates: Memory=864MB
+Per-Host Resource Estimates: Memory=896MB
 PLAN-ROOT SINK
 |
 21:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1821,7 +1821,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> l_partkey, RF003 -> l_suppkey, RF006 -> l_suppkey, RF008 -> l_orderkey, RF010 -> l_partkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=247.39MB Threads=17
-Per-Host Resource Estimates: Memory=862MB
+Per-Host Resource Estimates: Memory=884MB
 PLAN-ROOT SINK
 |
 21:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1990,7 +1990,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> c_nationkey, RF002 -> c_custkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=124.45MB Threads=11
-Per-Host Resource Estimates: Memory=669MB
+Per-Host Resource Estimates: Memory=701MB
 PLAN-ROOT SINK
 |
 15:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2048,7 +2048,7 @@ PLAN-ROOT SINK
    runtime filters: RF004 -> l_orderkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=231.89MB Threads=13
-Per-Host Resource Estimates: Memory=697MB
+Per-Host Resource Estimates: Memory=741MB
 PLAN-ROOT SINK
 |
 15:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2211,7 +2211,7 @@ PLAN-ROOT SINK
    runtime filters: RF002 -> ps_suppkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=43.70MB Threads=15
-Per-Host Resource Estimates: Memory=540MB
+Per-Host Resource Estimates: Memory=541MB
 PLAN-ROOT SINK
 |
 23:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2447,7 +2447,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> o_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=67.94MB Threads=7
-Per-Host Resource Estimates: Memory=508MB
+Per-Host Resource Estimates: Memory=528MB
 PLAN-ROOT SINK
 |
 09:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2483,7 +2483,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> l_orderkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=101.88MB Threads=9
-Per-Host Resource Estimates: Memory=454MB
+Per-Host Resource Estimates: Memory=475MB
 PLAN-ROOT SINK
 |
 09:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2573,7 +2573,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> o_custkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=41.38MB Threads=7
-Per-Host Resource Estimates: Memory=281MB
+Per-Host Resource Estimates: Memory=289MB
 PLAN-ROOT SINK
 |
 10:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2613,7 +2613,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> o_custkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=77.12MB Threads=9
-Per-Host Resource Estimates: Memory=320MB
+Per-Host Resource Estimates: Memory=334MB
 PLAN-ROOT SINK
 |
 10:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2692,7 +2692,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> l_partkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=22.75MB Threads=6
-Per-Host Resource Estimates: Memory=355MB
+Per-Host Resource Estimates: Memory=364MB
 PLAN-ROOT SINK
 |
 07:AGGREGATE [FINALIZE]
@@ -2720,7 +2720,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> l_partkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=41.75MB Threads=7
-Per-Host Resource Estimates: Memory=280MB
+Per-Host Resource Estimates: Memory=299MB
 PLAN-ROOT SINK
 |
 07:AGGREGATE [FINALIZE]
@@ -3018,7 +3018,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ps_partkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=54.56MB Threads=9
-Per-Host Resource Estimates: Memory=329MB
+Per-Host Resource Estimates: Memory=334MB
 PLAN-ROOT SINK
 |
 14:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3069,7 +3069,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> ps_partkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=101.38MB Threads=11
-Per-Host Resource Estimates: Memory=386MB
+Per-Host Resource Estimates: Memory=393MB
 PLAN-ROOT SINK
 |
 14:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3361,7 +3361,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpch.lineitem.l_orderkey, RF004 -> l_orderkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=191.12MB Threads=11
-Per-Host Resource Estimates: Memory=996MB
+Per-Host Resource Estimates: Memory=1.02GB
 PLAN-ROOT SINK
 |
 17:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3425,7 +3425,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpch.lineitem.l_orderkey, RF004 -> l_orderkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=336.88MB Threads=13
-Per-Host Resource Estimates: Memory=991MB
+Per-Host Resource Estimates: Memory=1.01GB
 PLAN-ROOT SINK
 |
 17:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3709,7 +3709,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpch.lineitem.l_suppkey, RF002 -> tpch.lineitem.l_partkey, RF003 -> tpch.lineitem.l_suppkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=124.63MB Threads=13
-Per-Host Resource Estimates: Memory=667MB
+Per-Host Resource Estimates: Memory=677MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3777,7 +3777,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> tpch.lineitem.l_suppkey, RF002 -> tpch.lineitem.l_partkey, RF003 -> tpch.lineitem.l_suppkey
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=247.39MB Threads=15
-Per-Host Resource Estimates: Memory=675MB
+Per-Host Resource Estimates: Memory=691MB
 PLAN-ROOT SINK
 |
 18:MERGING-EXCHANGE [UNPARTITIONED]
@@ -3961,7 +3961,7 @@ PLAN-ROOT SINK
    predicates: l3.l_receiptdate > l3.l_commitdate
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=56.51MB Threads=15
-Per-Host Resource Estimates: Memory=1.05GB
+Per-Host Resource Estimates: Memory=1.08GB
 PLAN-ROOT SINK
 |
 21:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4040,7 +4040,7 @@ PLAN-ROOT SINK
    predicates: l3.l_receiptdate > l3.l_commitdate
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=109.27MB Threads=17
-Per-Host Resource Estimates: Memory=841MB
+Per-Host Resource Estimates: Memory=863MB
 PLAN-ROOT SINK
 |
 21:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4207,7 +4207,7 @@ PLAN-ROOT SINK
    partitions=1/1 files=1 size=162.56MB
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=41.88MB Threads=10
-Per-Host Resource Estimates: Memory=358MB
+Per-Host Resource Estimates: Memory=365MB
 PLAN-ROOT SINK
 |
 15:MERGING-EXCHANGE [UNPARTITIONED]
@@ -4258,7 +4258,7 @@ PLAN-ROOT SINK
    partitions=1/1 files=1 size=162.56MB
 ---- PARALLELPLANS
 Max Per-Host Resource Reservation: Memory=83.75MB Threads=12
-Per-Host Resource Estimates: Memory=402MB
+Per-Host Resource Estimates: Memory=414MB
 PLAN-ROOT SINK
 |
 15:MERGING-EXCHANGE [UNPARTITIONED]

http://git-wip-us.apache.org/repos/asf/impala/blob/8cbec20e/testdata/workloads/functional-planner/queries/PlannerTest/tpch-nested.test
----------------------------------------------------------------------
diff --git a/testdata/workloads/functional-planner/queries/PlannerTest/tpch-nested.test b/testdata/workloads/functional-planner/queries/PlannerTest/tpch-nested.test
index e06d87a..7717acf 100644
--- a/testdata/workloads/functional-planner/queries/PlannerTest/tpch-nested.test
+++ b/testdata/workloads/functional-planner/queries/PlannerTest/tpch-nested.test
@@ -34,11 +34,11 @@ PLAN-ROOT SINK
 |  group by: l_returnflag, l_linestatus
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate <= '1998-09-02'
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=112.00MB Threads=4
-Per-Host Resource Estimates: Memory=886MB
+Per-Host Resource Estimates: Memory=916MB
 PLAN-ROOT SINK
 |
 05:MERGING-EXCHANGE [UNPARTITIONED]
@@ -58,7 +58,7 @@ PLAN-ROOT SINK
 |  group by: l_returnflag, l_linestatus
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate <= '1998-09-02'
 ====
 # TPCH-Q2
@@ -132,7 +132,7 @@ PLAN-ROOT SINK
 |  |  |  19:UNNEST [r.r_nations n]
 |  |  |
 |  |  16:SCAN HDFS [tpch_nested_parquet.region r]
-|  |     partitions=1/1 files=1 size=3.36KB
+|  |     partitions=1/1 files=1 size=3.44KB
 |  |     predicates: r_name = 'EUROPE', !empty(r.r_nations)
 |  |
 |  12:SUBPLAN
@@ -161,7 +161,7 @@ PLAN-ROOT SINK
 |  |  09:UNNEST [r.r_nations n]
 |  |
 |  06:SCAN HDFS [tpch_nested_parquet.region r]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: r_name = 'EUROPE', !empty(r.r_nations)
 |
 23:HASH JOIN [INNER JOIN]
@@ -186,7 +186,7 @@ PLAN-ROOT SINK
    runtime filters: RF004 -> s_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=114.73MB Threads=12
-Per-Host Resource Estimates: Memory=1.00GB
+Per-Host Resource Estimates: Memory=1.01GB
 PLAN-ROOT SINK
 |
 33:MERGING-EXCHANGE [UNPARTITIONED]
@@ -227,7 +227,7 @@ PLAN-ROOT SINK
 |  |  |  19:UNNEST [r.r_nations n]
 |  |  |
 |  |  16:SCAN HDFS [tpch_nested_parquet.region r]
-|  |     partitions=1/1 files=1 size=3.36KB
+|  |     partitions=1/1 files=1 size=3.44KB
 |  |     predicates: r_name = 'EUROPE', !empty(r.r_nations)
 |  |
 |  12:SUBPLAN
@@ -258,7 +258,7 @@ PLAN-ROOT SINK
 |  |  09:UNNEST [r.r_nations n]
 |  |
 |  06:SCAN HDFS [tpch_nested_parquet.region r]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: r_name = 'EUROPE', !empty(r.r_nations)
 |
 23:HASH JOIN [INNER JOIN, BROADCAST]
@@ -336,13 +336,13 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: c_mktsegment = 'BUILDING', !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate < '1995-03-15'
    predicates on l: l_shipdate > '1995-03-15'
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=100.00MB Threads=4
-Per-Host Resource Estimates: Memory=872MB
+Per-Host Resource Estimates: Memory=882MB
 PLAN-ROOT SINK
 |
 13:MERGING-EXCHANGE [UNPARTITIONED]
@@ -379,7 +379,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: c_mktsegment = 'BUILDING', !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate < '1995-03-15'
    predicates on l: l_shipdate > '1995-03-15'
@@ -436,13 +436,13 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: o_orderdate >= '1993-07-01', o_orderdate < '1993-10-01'
    predicates on o_lineitems: l_commitdate < l_receiptdate
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=96.00MB Threads=4
-Per-Host Resource Estimates: Memory=620MB
+Per-Host Resource Estimates: Memory=632MB
 PLAN-ROOT SINK
 |
 13:MERGING-EXCHANGE [UNPARTITIONED]
@@ -478,7 +478,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: o_orderdate >= '1993-07-01', o_orderdate < '1993-10-01'
    predicates on o_lineitems: l_commitdate < l_receiptdate
@@ -538,7 +538,7 @@ PLAN-ROOT SINK
 |  |  13:UNNEST [r.r_nations n]
 |  |
 |  10:SCAN HDFS [tpch_nested_parquet.region r]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: r_name = 'ASIA', !empty(r.r_nations)
 |
 01:SUBPLAN
@@ -558,13 +558,13 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate >= '1994-01-01', o_orderdate < '1995-01-01'
    runtime filters: RF000 -> c_nationkey, RF004 -> c.c_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=110.02MB Threads=8
-Per-Host Resource Estimates: Memory=1.26GB
+Per-Host Resource Estimates: Memory=1.29GB
 PLAN-ROOT SINK
 |
 23:MERGING-EXCHANGE [UNPARTITIONED]
@@ -607,7 +607,7 @@ PLAN-ROOT SINK
 |  |  13:UNNEST [r.r_nations n]
 |  |
 |  10:SCAN HDFS [tpch_nested_parquet.region r]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: r_name = 'ASIA', !empty(r.r_nations)
 |
 01:SUBPLAN
@@ -627,7 +627,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate >= '1994-01-01', o_orderdate < '1995-01-01'
    runtime filters: RF000 -> c_nationkey, RF004 -> c.c_nationkey
@@ -652,7 +652,7 @@ PLAN-ROOT SINK
 |  output: sum(l_extendedprice * l_discount)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_discount <= 0.07, l_discount >= 0.05, l_quantity < 24, l_shipdate < '1995-01-01', l_shipdate >= '1994-01-01'
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=16.00MB Threads=3
@@ -668,7 +668,7 @@ PLAN-ROOT SINK
 |  output: sum(l_extendedprice * l_discount)
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_discount <= 0.07, l_discount >= 0.05, l_quantity < 24, l_shipdate < '1995-01-01', l_shipdate >= '1994-01-01'
 ====
 # TPCH-Q7
@@ -727,14 +727,14 @@ PLAN-ROOT SINK
 |  runtime filters: RF000 <- n2.n_nationkey
 |
 |--11:SCAN HDFS [tpch_nested_parquet.region.r_nations n2]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 13:HASH JOIN [INNER JOIN]
 |  hash predicates: s_nationkey = n1.n_nationkey
 |  runtime filters: RF002 <- n1.n_nationkey
 |
 |--10:SCAN HDFS [tpch_nested_parquet.region.r_nations n1]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 12:HASH JOIN [INNER JOIN]
 |  hash predicates: l_suppkey = s_suppkey
@@ -760,14 +760,14 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems)
    predicates on l: l_shipdate >= '1995-01-01', l_shipdate <= '1996-12-31'
    runtime filters: RF000 -> c_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=112.97MB Threads=10
-Per-Host Resource Estimates: Memory=997MB
+Per-Host Resource Estimates: Memory=1.00GB
 PLAN-ROOT SINK
 |
 22:MERGING-EXCHANGE [UNPARTITIONED]
@@ -794,7 +794,7 @@ PLAN-ROOT SINK
 |--19:EXCHANGE [BROADCAST]
 |  |
 |  11:SCAN HDFS [tpch_nested_parquet.region.r_nations n2]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 13:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: s_nationkey = n1.n_nationkey
@@ -803,7 +803,7 @@ PLAN-ROOT SINK
 |--18:EXCHANGE [BROADCAST]
 |  |
 |  10:SCAN HDFS [tpch_nested_parquet.region.r_nations n1]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 12:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: l_suppkey = s_suppkey
@@ -831,7 +831,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems)
    predicates on l: l_shipdate >= '1995-01-01', l_shipdate <= '1996-12-31'
@@ -890,7 +890,7 @@ PLAN-ROOT SINK
 |  runtime filters: RF000 <- n2.n_nationkey
 |
 |--16:SCAN HDFS [tpch_nested_parquet.region.r_nations n2]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 19:HASH JOIN [INNER JOIN]
 |  hash predicates: c_nationkey = n1.n_nationkey
@@ -905,7 +905,7 @@ PLAN-ROOT SINK
 |  |  14:UNNEST [r.r_nations n1]
 |  |
 |  11:SCAN HDFS [tpch_nested_parquet.region r]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: r_name = 'AMERICA', !empty(r.r_nations)
 |
 18:HASH JOIN [INNER JOIN]
@@ -939,13 +939,13 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate >= '1995-01-01', o_orderdate <= '1996-12-31'
    runtime filters: RF002 -> c_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=110.91MB Threads=12
-Per-Host Resource Estimates: Memory=1.01GB
+Per-Host Resource Estimates: Memory=1.04GB
 PLAN-ROOT SINK
 |
 29:MERGING-EXCHANGE [UNPARTITIONED]
@@ -971,7 +971,7 @@ PLAN-ROOT SINK
 |--26:EXCHANGE [BROADCAST]
 |  |
 |  16:SCAN HDFS [tpch_nested_parquet.region.r_nations n2]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 19:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: c_nationkey = n1.n_nationkey
@@ -988,7 +988,7 @@ PLAN-ROOT SINK
 |  |  14:UNNEST [r.r_nations n1]
 |  |
 |  11:SCAN HDFS [tpch_nested_parquet.region r]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: r_name = 'AMERICA', !empty(r.r_nations)
 |
 18:HASH JOIN [INNER JOIN, BROADCAST]
@@ -1026,7 +1026,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate >= '1995-01-01', o_orderdate <= '1996-12-31'
    runtime filters: RF002 -> c_nationkey
@@ -1079,7 +1079,7 @@ PLAN-ROOT SINK
 |  runtime filters: RF000 <- n_nationkey
 |
 |--11:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 13:HASH JOIN [INNER JOIN]
 |  hash predicates: l_partkey = p_partkey
@@ -1113,11 +1113,11 @@ PLAN-ROOT SINK
 |  03:UNNEST [o.o_lineitems l]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders o]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(o.o_lineitems)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=143.33MB Threads=10
-Per-Host Resource Estimates: Memory=1.09GB
+Per-Host Resource Estimates: Memory=1.12GB
 PLAN-ROOT SINK
 |
 22:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1143,7 +1143,7 @@ PLAN-ROOT SINK
 |--19:EXCHANGE [BROADCAST]
 |  |
 |  11:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 13:HASH JOIN [INNER JOIN, BROADCAST]
 |  hash predicates: l_partkey = p_partkey
@@ -1181,7 +1181,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [o.o_lineitems l]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders o]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(o.o_lineitems)
 ====
 # TPCH-Q10
@@ -1234,7 +1234,7 @@ PLAN-ROOT SINK
 |  runtime filters: RF000 <- n_nationkey
 |
 |--09:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 01:SUBPLAN
 |
@@ -1253,14 +1253,14 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate >= '1993-10-01', o_orderdate < '1994-01-01'
    predicates on l: l_returnflag = 'R'
    runtime filters: RF000 -> c_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=94.95MB Threads=6
-Per-Host Resource Estimates: Memory=995MB
+Per-Host Resource Estimates: Memory=1006MB
 PLAN-ROOT SINK
 |
 16:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1287,7 +1287,7 @@ PLAN-ROOT SINK
 |--13:EXCHANGE [BROADCAST]
 |  |
 |  09:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |
 01:SUBPLAN
 |
@@ -1306,7 +1306,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderdate >= '1993-10-01', o_orderdate < '1994-01-01'
    predicates on l: l_returnflag = 'R'
@@ -1364,7 +1364,7 @@ PLAN-ROOT SINK
 |  |  runtime filters: RF002 <- n_nationkey
 |  |
 |  |--13:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|  |     partitions=1/1 files=1 size=3.36KB
+|  |     partitions=1/1 files=1 size=3.44KB
 |  |     predicates: n_name = 'GERMANY'
 |  |
 |  09:SUBPLAN
@@ -1389,7 +1389,7 @@ PLAN-ROOT SINK
 |  runtime filters: RF000 <- n_nationkey
 |
 |--05:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: n_name = 'GERMANY'
 |
 01:SUBPLAN
@@ -1406,7 +1406,7 @@ PLAN-ROOT SINK
    runtime filters: RF000 -> s_nationkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=111.91MB Threads=11
-Per-Host Resource Estimates: Memory=744MB
+Per-Host Resource Estimates: Memory=746MB
 PLAN-ROOT SINK
 |
 25:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1435,7 +1435,7 @@ PLAN-ROOT SINK
 |  |--21:EXCHANGE [BROADCAST]
 |  |  |
 |  |  13:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|  |     partitions=1/1 files=1 size=3.36KB
+|  |     partitions=1/1 files=1 size=3.44KB
 |  |     predicates: n_name = 'GERMANY'
 |  |
 |  09:SUBPLAN
@@ -1468,7 +1468,7 @@ PLAN-ROOT SINK
 |--18:EXCHANGE [BROADCAST]
 |  |
 |  05:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: n_name = 'GERMANY'
 |
 01:SUBPLAN
@@ -1534,12 +1534,12 @@ PLAN-ROOT SINK
 |  03:UNNEST [o.o_lineitems l]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders o]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(o.o_lineitems)
    predicates on l: l_shipmode IN ('MAIL', 'SHIP'), l_commitdate < l_receiptdate, l_shipdate < l_commitdate, l_receiptdate >= '1994-01-01', l_receiptdate < '1995-01-01'
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=104.00MB Threads=4
-Per-Host Resource Estimates: Memory=718MB
+Per-Host Resource Estimates: Memory=748MB
 PLAN-ROOT SINK
 |
 09:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1567,7 +1567,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [o.o_lineitems l]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders o]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(o.o_lineitems)
    predicates on l: l_shipmode IN ('MAIL', 'SHIP'), l_commitdate < l_receiptdate, l_shipdate < l_commitdate, l_receiptdate >= '1994-01-01', l_receiptdate < '1995-01-01'
 ====
@@ -1617,11 +1617,11 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates on c_orders: (NOT o_comment LIKE '%special%requests%')
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=96.94MB Threads=5
-Per-Host Resource Estimates: Memory=546MB
+Per-Host Resource Estimates: Memory=548MB
 PLAN-ROOT SINK
 |
 12:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1659,7 +1659,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates on c_orders: (NOT o_comment LIKE '%special%requests%')
 ====
 # TPCH-Q14
@@ -1693,7 +1693,7 @@ PLAN-ROOT SINK
 |     partitions=1/1 files=1 size=6.23MB
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate < '1995-10-01', l_shipdate >= '1995-09-01'
    runtime filters: RF000 -> l_partkey
 ---- DISTRIBUTEDPLAN
@@ -1719,7 +1719,7 @@ PLAN-ROOT SINK
 |     partitions=1/1 files=1 size=6.23MB
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate < '1995-10-01', l_shipdate >= '1995-09-01'
    runtime filters: RF000 -> l_partkey
 ====
@@ -1774,7 +1774,7 @@ PLAN-ROOT SINK
 |  |  group by: l_suppkey
 |  |
 |  03:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-|     partitions=1/1 files=4 size=288.98MB
+|     partitions=1/1 files=4 size=288.99MB
 |     predicates: l_shipdate < '1996-04-01', l_shipdate >= '1996-01-01'
 |
 06:HASH JOIN [INNER JOIN]
@@ -1789,12 +1789,12 @@ PLAN-ROOT SINK
 |  group by: l_suppkey
 |
 01:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate < '1996-04-01', l_shipdate >= '1996-01-01'
    runtime filters: RF000 -> l.l_suppkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=186.88MB Threads=10
-Per-Host Resource Estimates: Memory=1.45GB
+Per-Host Resource Estimates: Memory=1.47GB
 PLAN-ROOT SINK
 |
 17:MERGING-EXCHANGE [UNPARTITIONED]
@@ -1827,7 +1827,7 @@ PLAN-ROOT SINK
 |  |  group by: l_suppkey
 |  |
 |  03:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-|     partitions=1/1 files=4 size=288.98MB
+|     partitions=1/1 files=4 size=288.99MB
 |     predicates: l_shipdate < '1996-04-01', l_shipdate >= '1996-01-01'
 |
 06:HASH JOIN [INNER JOIN, PARTITIONED]
@@ -1850,7 +1850,7 @@ PLAN-ROOT SINK
 |  group by: l_suppkey
 |
 01:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate < '1996-04-01', l_shipdate >= '1996-01-01'
    runtime filters: RF000 -> l.l_suppkey
 ====
@@ -1915,7 +1915,7 @@ PLAN-ROOT SINK
    predicates: NOT s_comment LIKE '%Customer%Complaints%', !empty(s.s_partsupps)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=31.81MB Threads=7
-Per-Host Resource Estimates: Memory=286MB
+Per-Host Resource Estimates: Memory=288MB
 PLAN-ROOT SINK
 |
 15:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2000,7 +2000,7 @@ PLAN-ROOT SINK
 |  |  group by: l_partkey
 |  |
 |  02:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-|     partitions=1/1 files=4 size=288.98MB
+|     partitions=1/1 files=4 size=288.99MB
 |
 04:HASH JOIN [INNER JOIN]
 |  hash predicates: l_partkey = p_partkey
@@ -2012,11 +2012,11 @@ PLAN-ROOT SINK
 |     runtime filters: RF000 -> p_partkey
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    runtime filters: RF000 -> l.l_partkey, RF002 -> l_partkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=154.94MB Threads=8
-Per-Host Resource Estimates: Memory=865MB
+Per-Host Resource Estimates: Memory=875MB
 PLAN-ROOT SINK
 |
 12:AGGREGATE [FINALIZE]
@@ -2043,7 +2043,7 @@ PLAN-ROOT SINK
 |  |  group by: l_partkey
 |  |
 |  02:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-|     partitions=1/1 files=4 size=288.98MB
+|     partitions=1/1 files=4 size=288.99MB
 |
 10:EXCHANGE [HASH(p_partkey)]
 |
@@ -2059,7 +2059,7 @@ PLAN-ROOT SINK
 |     runtime filters: RF000 -> p_partkey
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    runtime filters: RF000 -> l.l_partkey, RF002 -> l_partkey
 ====
 # TPCH-Q18
@@ -2110,7 +2110,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=24.00MB Threads=3
@@ -2145,7 +2145,7 @@ PLAN-ROOT SINK
 |  03:UNNEST [c.c_orders o]
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
 ====
 # TPCH-Q19
@@ -2203,7 +2203,7 @@ PLAN-ROOT SINK
 |     predicates: p_size >= 1
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipmode IN ('AIR', 'AIR REG'), l_shipinstruct = 'DELIVER IN PERSON'
    runtime filters: RF000 -> l_partkey
 ---- DISTRIBUTEDPLAN
@@ -2231,7 +2231,7 @@ PLAN-ROOT SINK
 |     predicates: p_size >= 1
 |
 00:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipmode IN ('AIR', 'AIR REG'), l_shipinstruct = 'DELIVER IN PERSON'
    runtime filters: RF000 -> l_partkey
 ====
@@ -2297,7 +2297,7 @@ PLAN-ROOT SINK
 |  |  runtime filters: RF006 <- n_nationkey
 |  |
 |  |--05:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|  |     partitions=1/1 files=1 size=3.36KB
+|  |     partitions=1/1 files=1 size=3.44KB
 |  |     predicates: n_name = 'CANADA'
 |  |
 |  01:SUBPLAN
@@ -2318,12 +2318,12 @@ PLAN-ROOT SINK
 |  group by: l_partkey, l_suppkey
 |
 07:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate < '1995-01-01', l_shipdate >= '1994-01-01'
    runtime filters: RF000 -> l.l_partkey, RF001 -> l.l_suppkey
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=164.33MB Threads=11
-Per-Host Resource Estimates: Memory=1.04GB
+Per-Host Resource Estimates: Memory=1.07GB
 PLAN-ROOT SINK
 |
 21:MERGING-EXCHANGE [UNPARTITIONED]
@@ -2363,7 +2363,7 @@ PLAN-ROOT SINK
 |  |--16:EXCHANGE [BROADCAST]
 |  |  |
 |  |  05:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|  |     partitions=1/1 files=1 size=3.36KB
+|  |     partitions=1/1 files=1 size=3.44KB
 |  |     predicates: n_name = 'CANADA'
 |  |
 |  01:SUBPLAN
@@ -2390,7 +2390,7 @@ PLAN-ROOT SINK
 |  group by: l_partkey, l_suppkey
 |
 07:SCAN HDFS [tpch_nested_parquet.customer.c_orders.o_lineitems l]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: l_shipdate < '1995-01-01', l_shipdate >= '1994-01-01'
    runtime filters: RF000 -> l.l_partkey, RF001 -> l.l_suppkey
 ====
@@ -2465,7 +2465,7 @@ PLAN-ROOT SINK
 |  runtime filters: RF000 <- n_nationkey
 |
 |--10:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: n_name = 'SAUDI ARABIA'
 |
 11:HASH JOIN [INNER JOIN]
@@ -2492,7 +2492,7 @@ PLAN-ROOT SINK
 |  04:UNNEST [c.c_orders o]
 |
 01:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderstatus = 'F'
    predicates on l1: l1.l_receiptdate > l1.l_commitdate
@@ -2540,7 +2540,7 @@ PLAN-ROOT SINK
 |--22:EXCHANGE [BROADCAST]
 |  |
 |  10:SCAN HDFS [tpch_nested_parquet.region.r_nations n]
-|     partitions=1/1 files=1 size=3.36KB
+|     partitions=1/1 files=1 size=3.44KB
 |     predicates: n_name = 'SAUDI ARABIA'
 |
 11:HASH JOIN [INNER JOIN, BROADCAST]
@@ -2569,7 +2569,7 @@ PLAN-ROOT SINK
 |  04:UNNEST [c.c_orders o]
 |
 01:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: !empty(c.c_orders)
    predicates on o: !empty(o.o_lineitems), o_orderstatus = 'F'
    predicates on l1: l1.l_receiptdate > l1.l_commitdate
@@ -2636,11 +2636,11 @@ PLAN-ROOT SINK
 |  |  output: avg(c_acctbal)
 |  |
 |  01:SCAN HDFS [tpch_nested_parquet.customer c]
-|     partitions=1/1 files=4 size=288.98MB
+|     partitions=1/1 files=4 size=288.99MB
 |     predicates: c_acctbal > 0.00, substr(c_phone, 1, 2) IN ('13', '31', '23', '29', '30', '18', '17')
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: substr(c_phone, 1, 2) IN ('13', '31', '23', '29', '30', '18', '17')
 ---- DISTRIBUTEDPLAN
 Max Per-Host Resource Reservation: Memory=25.94MB Threads=8
@@ -2685,10 +2685,10 @@ PLAN-ROOT SINK
 |  |  output: avg(c_acctbal)
 |  |
 |  01:SCAN HDFS [tpch_nested_parquet.customer c]
-|     partitions=1/1 files=4 size=288.98MB
+|     partitions=1/1 files=4 size=288.99MB
 |     predicates: c_acctbal > 0.00, substr(c_phone, 1, 2) IN ('13', '31', '23', '29', '30', '18', '17')
 |
 00:SCAN HDFS [tpch_nested_parquet.customer c]
-   partitions=1/1 files=4 size=288.98MB
+   partitions=1/1 files=4 size=288.99MB
    predicates: substr(c_phone, 1, 2) IN ('13', '31', '23', '29', '30', '18', '17')
 ====