From 44c7cc374d31ee25d6d052b6a89d35caa9830275 Mon Sep 17 00:00:00 2001 From: minghong Date: Thu, 28 Nov 2024 16:55:41 +0800 Subject: [PATCH] push down encode slot --- .../doris/nereids/jobs/executor/Rewriter.java | 4 +- .../nereids/properties/LogicalProperties.java | 12 +- .../apache/doris/nereids/rules/RuleType.java | 1 + .../rules/rewrite/PullUpJoinFromUnionAll.java | 15 +- .../rules/rewrite/PushDownEncodeSlot.java | 180 ++++++++++++++++++ .../rewrite/PushDownFilterThroughProject.java | 4 +- .../functions/scalar/EncodeAsBigInt.java | 4 +- .../functions/scalar/EncodeAsInt.java | 4 +- .../functions/scalar/EncodeAsLargeInt.java | 4 +- .../functions/scalar/EncodeAsSmallInt.java | 4 +- ...EncodeStrToInteger.java => EncodeStr.java} | 11 +- .../doris/nereids/trees/plans/Plan.java | 5 + .../trees/plans/logical/LogicalOlapScan.java | 2 +- .../trees/plans/logical/LogicalProject.java | 18 ++ .../org/apache/doris/qe/SessionVariable.java | 2 +- 15 files changed, 245 insertions(+), 25 deletions(-) create mode 100644 fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownEncodeSlot.java rename fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/{EncodeStrToInteger.java => EncodeStr.java} (70%) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/jobs/executor/Rewriter.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/jobs/executor/Rewriter.java index f4ca9a972a6814c..ac925c48ecbf726 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/jobs/executor/Rewriter.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/jobs/executor/Rewriter.java @@ -113,6 +113,7 @@ import org.apache.doris.nereids.rules.rewrite.PushDownAggThroughJoinOnPkFk; import org.apache.doris.nereids.rules.rewrite.PushDownAggThroughJoinOneSide; import org.apache.doris.nereids.rules.rewrite.PushDownDistinctThroughJoin; +import org.apache.doris.nereids.rules.rewrite.PushDownEncodeSlot; import org.apache.doris.nereids.rules.rewrite.PushDownFilterThroughProject; import org.apache.doris.nereids.rules.rewrite.PushDownLimit; import org.apache.doris.nereids.rules.rewrite.PushDownLimitDistinctThroughJoin; @@ -248,7 +249,8 @@ public class Rewriter extends AbstractBatchJobExecutor { topDown( new NormalizeAggregate(), new CountLiteralRewrite(), - new NormalizeSort() + new NormalizeSort(), + new PushDownEncodeSlot() ), topic("Window analysis", topDown( diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/properties/LogicalProperties.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/properties/LogicalProperties.java index 2cb472ce975f314..b889ec6abc7c6c4 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/properties/LogicalProperties.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/properties/LogicalProperties.java @@ -44,11 +44,6 @@ public class LogicalProperties { protected final Supplier dataTraitSupplier; private Integer hashCode = null; - public LogicalProperties(Supplier> outputSupplier, - Supplier dataTraitSupplier) { - this(outputSupplier, dataTraitSupplier, ImmutableList::of); - } - /** * constructor of LogicalProperties. * @@ -56,8 +51,7 @@ public LogicalProperties(Supplier> outputSupplier, * throw exception for which children have UnboundRelation */ public LogicalProperties(Supplier> outputSupplier, - Supplier dataTraitSupplier, - Supplier> nonUserVisibleOutputSupplier) { + Supplier dataTraitSupplier) { this.outputSupplier = Suppliers.memoize( Objects.requireNonNull(outputSupplier, "outputSupplier can not be null") ); @@ -100,6 +94,10 @@ public LogicalProperties(Supplier> outputSupplier, ); } + public LogicalProperties withOutputSupplier(Supplier> outputSupplier) { + return new LogicalProperties(outputSupplier, dataTraitSupplier); + } + public List getOutput() { return outputSupplier.get(); } diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/RuleType.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/RuleType.java index beb8bd436557434..2ee07d17f56a7e4 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/RuleType.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/RuleType.java @@ -108,6 +108,7 @@ public enum RuleType { // rewrite rules COMPRESSED_MATERIALIZE_AGG(RuleTypeClass.REWRITE), COMPRESSED_MATERIALIZE_SORT(RuleTypeClass.REWRITE), + PUSH_DOWN_ENCODE_SLOT(RuleTypeClass.REWRITE), NORMALIZE_AGGREGATE(RuleTypeClass.REWRITE), NORMALIZE_SORT(RuleTypeClass.REWRITE), NORMALIZE_REPEAT(RuleTypeClass.REWRITE), diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PullUpJoinFromUnionAll.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PullUpJoinFromUnionAll.java index b3df9b92c56a84c..8c21b12a6d8fa18 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PullUpJoinFromUnionAll.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PullUpJoinFromUnionAll.java @@ -586,10 +586,17 @@ boolean comparePlan(Plan plan1, Plan plan2) { isEqual = false; } for (int i = 0; isEqual && i < plan2.getOutput().size(); i++) { - NamedExpression expr = ((LogicalProject) plan1).getProjects().get(i); - NamedExpression replacedExpr = (NamedExpression) - expr.rewriteUp(e -> plan1ToPlan2.getOrDefault(e, e)); - if (!replacedExpr.equals(((LogicalProject) plan2).getProjects().get(i))) { + Expression expr1 = ((LogicalProject) plan1).getProjects().get(i); + Expression expr2 = ((LogicalProject) plan2).getProjects().get(i); + if (expr1 instanceof Alias) { + if (!(expr2 instanceof Alias)) { + return false; + } + expr1 = expr1.child(0); + expr2 = expr2.child(0); + } + Expression replacedExpr = expr1.rewriteUp(e -> plan1ToPlan2.getOrDefault(e, e)); + if (!replacedExpr.equals(expr2)) { isEqual = false; } } diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownEncodeSlot.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownEncodeSlot.java new file mode 100644 index 000000000000000..69565166953db68 --- /dev/null +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownEncodeSlot.java @@ -0,0 +1,180 @@ +// Licensed to the Apache Software Foundation (ASF) under one +// or more contributor license agreements. See the NOTICE file +// distributed with this work for additional information +// regarding copyright ownership. The ASF licenses this file +// to you under the Apache License, Version 2.0 (the +// "License"); you may not use this file except in compliance +// with the License. You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, +// software distributed under the License is distributed on an +// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +// KIND, either express or implied. See the License for the +// specific language governing permissions and limitations +// under the License. + +package org.apache.doris.nereids.rules.rewrite; + +import org.apache.doris.nereids.rules.Rule; +import org.apache.doris.nereids.rules.RuleType; +import org.apache.doris.nereids.trees.expressions.Alias; +import org.apache.doris.nereids.trees.expressions.Expression; +import org.apache.doris.nereids.trees.expressions.NamedExpression; +import org.apache.doris.nereids.trees.expressions.Slot; +import org.apache.doris.nereids.trees.expressions.SlotReference; +import org.apache.doris.nereids.trees.expressions.functions.scalar.EncodeStr; +import org.apache.doris.nereids.trees.plans.Plan; +import org.apache.doris.nereids.trees.plans.logical.LogicalCatalogRelation; +import org.apache.doris.nereids.trees.plans.logical.LogicalProject; +import org.apache.doris.nereids.trees.plans.visitor.PlanVisitor; + +import com.google.common.collect.ImmutableList; +import com.google.common.collect.Sets; + +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.stream.Collectors; + +/** + * push down encode_as_int(slot) down + * example: + * group by x + * -->project(encode_as_int(A) as x) + * -->Any(A) + * -->project(A) + * --> scan + * => + * group by x + * -->project(x) + * -->Any(x) + * --> project(encode_as_int(A) as x) + * -->scan + * Note: + * do not push down encode if encode.child() is not slot, + * example + * group by encode_as_int(A + B) + * --> any(A, B) + */ +public class PushDownEncodeSlot extends OneRewriteRuleFactory { + + @Override + public Rule build() { + return logicalProject() + .when(this::containsEncode) + .when(project -> !(project.child() instanceof LogicalCatalogRelation)) + .then(project -> pushDownEncodeSlot(project)) + .toRule(RuleType.PUSH_DOWN_ENCODE_SLOT); + } + + private boolean containsEncode(LogicalProject project) { + return project.getProjects().stream() + .anyMatch(e -> e instanceof Alias && containsEncode(e.child(0))); + } + + private boolean containsEncode(Expression expr) { + return expr instanceof EncodeStr && expr.child(0) instanceof SlotReference; + } + + private List collectEncodeAlias(LogicalProject project) { + List encodeAlias = new ArrayList<>(); + project.getProjects().forEach(e -> { + if (e instanceof Alias && e.child(0) instanceof EncodeStr) { + encodeAlias.add((Alias) e); + } + }); + return encodeAlias; + } + + private LogicalProject pushDownEncodeSlot(LogicalProject project) { + List encodeAlias = collectEncodeAlias(project); + LogicalProject result = (LogicalProject) + project.accept(EncodeSlotPushDownVisitor.visitor, encodeAlias); + return result; + } + + /** + * push down encode slot + */ + public static class EncodeSlotPushDownVisitor extends PlanVisitor> { + public static EncodeSlotPushDownVisitor visitor = new EncodeSlotPushDownVisitor(); + + @Override + public Plan visit(Plan plan, List encodeAlias) { + // replaceMap: + // encode_as_int(slot1) -> slot2 + // slot1 -> slot2 + Map replaceMap = new HashMap<>(); + List> byPassSlots = plan.children().stream() + .map(this::getByPassSlot) + .collect(Collectors.toList()); + Map> toBePushed = new HashMap<>(); + for (Alias alias : encodeAlias) { + EncodeStr encode = (EncodeStr) alias.child(); + Expression strExpr = encode.child(); + if (strExpr instanceof SlotReference) { + for (int i = 0; i < byPassSlots.size(); i++) { + if (byPassSlots.get(i).contains(strExpr)) { + toBePushed.putIfAbsent(plan.child(i), new ArrayList<>()); + toBePushed.get(plan.child(i)).add(alias); + replaceMap.put(alias, alias.toSlot()); + replaceMap.put(alias.child().child(0), alias.toSlot()); + break; + } + } + } + } + // rewrite plan according to encode expression + // for example: project(encode_as_int(slot1) as slot2) + // 1. rewrite project's expressions: project(slot2), + // 2. push encode_as_int(slot1) as slot2 down to project.child() + // rewrite expressions + plan = plan.replaceExpressions(replaceMap); + // rewrite children + ImmutableList.Builder newChildren = ImmutableList.builderWithExpectedSize(plan.arity()); + boolean hasNewChildren = false; + for (Plan child : plan.children()) { + Plan newChild; + if (toBePushed.containsKey(child)) { + if (child instanceof LogicalProject && child.child(0) instanceof LogicalCatalogRelation) { + LogicalProject project = (LogicalProject) child; + List projections = new ArrayList<>(); + projections.addAll(toBePushed.get(project)); + projections.addAll(project.getProjects()); + newChild = project.withProjects(projections); + } else if (child instanceof LogicalCatalogRelation) { + List newProjections = new ArrayList<>(); + newProjections.addAll(child.getOutput()); + newProjections.addAll(toBePushed.get(child)); + newChild = new LogicalProject<>(newProjections, child); + hasNewChildren = true; + } else { + newChild = child.accept(this, toBePushed.get(child)); + } + if (!hasNewChildren && newChild != child) { + hasNewChildren = true; + } + } else { + newChild = child; + } + newChildren.add(newChild); + } + + if (hasNewChildren) { + plan = plan.withChildren(newChildren.build()); + } + return plan; + } + + private Set getByPassSlot(Plan plan) { + Set outputSlots = Sets.newHashSet(plan.getOutput()); + outputSlots.removeAll(plan.getInputSlots()); + return outputSlots; + } + } + +} diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownFilterThroughProject.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownFilterThroughProject.java index 38b687ba8387a05..ab5eb11e8d76d7f 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownFilterThroughProject.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/rules/rewrite/PushDownFilterThroughProject.java @@ -23,7 +23,7 @@ import org.apache.doris.nereids.trees.expressions.Expression; import org.apache.doris.nereids.trees.expressions.Slot; import org.apache.doris.nereids.trees.expressions.functions.scalar.DecodeAsVarchar; -import org.apache.doris.nereids.trees.expressions.functions.scalar.EncodeStrToInteger; +import org.apache.doris.nereids.trees.expressions.functions.scalar.EncodeStr; import org.apache.doris.nereids.trees.plans.Plan; import org.apache.doris.nereids.trees.plans.logical.LogicalFilter; import org.apache.doris.nereids.trees.plans.logical.LogicalLimit; @@ -149,7 +149,7 @@ private static Set eliminateDecodeAndEncode(Set expressi } private static Expression eliminateDecodeAndEncode(Expression expression) { - if (expression instanceof DecodeAsVarchar && expression.child(0) instanceof EncodeStrToInteger) { + if (expression instanceof DecodeAsVarchar && expression.child(0) instanceof EncodeStr) { return expression.child(0).child(0); } boolean hasNewChild = false; diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsBigInt.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsBigInt.java index 7d798ecf3e8cab9..50a7efcc0f4d74f 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsBigInt.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsBigInt.java @@ -33,8 +33,8 @@ /** * ScalarFunction 'EncodeAsBigInt'. */ -public class EncodeAsBigInt extends ScalarFunction - implements ExplicitlyCastableSignature, PropagateNullable, EncodeStrToInteger { +public class EncodeAsBigInt extends EncodeStr + implements ExplicitlyCastableSignature, PropagateNullable { public static final List SIGNATURES = ImmutableList.of( FunctionSignature.ret(BigIntType.INSTANCE).args(VarcharType.SYSTEM_DEFAULT) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsInt.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsInt.java index 5c6382d6ea144da..208bae89c3fabf2 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsInt.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsInt.java @@ -33,8 +33,8 @@ /** * ScalarFunction 'EncodeAsInt'. */ -public class EncodeAsInt extends ScalarFunction - implements ExplicitlyCastableSignature, PropagateNullable, EncodeStrToInteger { +public class EncodeAsInt extends EncodeStr + implements ExplicitlyCastableSignature, PropagateNullable { public static final List SIGNATURES = ImmutableList.of( FunctionSignature.ret(IntegerType.INSTANCE).args(VarcharType.SYSTEM_DEFAULT) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsLargeInt.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsLargeInt.java index bb30a9a8e8aef53..bd0c5b23520ec99 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsLargeInt.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsLargeInt.java @@ -33,8 +33,8 @@ /** * ScalarFunction 'EncodeAsLargeInt'. */ -public class EncodeAsLargeInt extends ScalarFunction - implements ExplicitlyCastableSignature, PropagateNullable, EncodeStrToInteger { +public class EncodeAsLargeInt extends EncodeStr + implements ExplicitlyCastableSignature, PropagateNullable { public static final List SIGNATURES = ImmutableList.of( FunctionSignature.ret(LargeIntType.INSTANCE).args(VarcharType.SYSTEM_DEFAULT) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsSmallInt.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsSmallInt.java index 355a740197c33ec..b57be9a0f433780 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsSmallInt.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeAsSmallInt.java @@ -33,8 +33,8 @@ /** * ScalarFunction 'CompressAsSmallInt'. */ -public class EncodeAsSmallInt extends ScalarFunction - implements ExplicitlyCastableSignature, PropagateNullable, EncodeStrToInteger { +public class EncodeAsSmallInt extends EncodeStr + implements ExplicitlyCastableSignature, PropagateNullable { public static final List SIGNATURES = ImmutableList.of( FunctionSignature.ret(SmallIntType.INSTANCE).args(VarcharType.SYSTEM_DEFAULT) diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeStrToInteger.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeStr.java similarity index 70% rename from fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeStrToInteger.java rename to fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeStr.java index 87a9c43687d6a3f..520db4c3e65d669 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeStrToInteger.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/EncodeStr.java @@ -17,8 +17,17 @@ package org.apache.doris.nereids.trees.expressions.functions.scalar; +import org.apache.doris.nereids.trees.expressions.Expression; +import org.apache.doris.nereids.trees.expressions.shape.UnaryExpression; + /** * Encode_as_XXXInt */ -public interface EncodeStrToInteger { +public abstract class EncodeStr extends ScalarFunction implements UnaryExpression { + /** + * constructor with 1 argument. + */ + public EncodeStr(String name, Expression arg0) { + super("encode_as_int", arg0); + } } diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/Plan.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/Plan.java index 60af0d18666f2bc..3c564a01e6fe8ba 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/Plan.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/Plan.java @@ -36,6 +36,7 @@ import com.google.common.collect.Sets; import java.util.List; +import java.util.Map; import java.util.Optional; import java.util.Set; @@ -232,4 +233,8 @@ default String getGroupIdAsString() { default String getGroupIdWithPrefix() { return "@" + getGroupIdAsString(); } + + default Plan replaceExpressions(Map replaceMap) { + return this; + } } diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalOlapScan.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalOlapScan.java index 90ceb24231340c7..b7b9f155b910603 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalOlapScan.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalOlapScan.java @@ -217,7 +217,7 @@ public OlapTable getTable() { @Override public String toString() { return Utils.toSqlString("LogicalOlapScan", - "qualified", qualifiedName(), + "name", table.getName(), "indexName", getSelectedMaterializedIndexName().orElse(""), "selectedIndexId", selectedIndexId, "preAgg", preAggStatus diff --git a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalProject.java b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalProject.java index 171a355d8452d82..e668726a4971799 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalProject.java +++ b/fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/logical/LogicalProject.java @@ -278,4 +278,22 @@ public void computeFd(DataTrait.Builder builder) { } } } + + @Override + public Plan replaceExpressions(Map replaceMap) { + List newProjections = new ArrayList<>(); + boolean changed = false; + for (NamedExpression expr : getProjects()) { + if (replaceMap.containsKey(expr) && replaceMap.get(expr) instanceof NamedExpression) { + newProjections.add((NamedExpression) replaceMap.get(expr)); + changed = true; + } else { + newProjections.add(expr); + } + } + if (changed) { + return this.withProjects(newProjections); + } + return this; + } } diff --git a/fe/fe-core/src/main/java/org/apache/doris/qe/SessionVariable.java b/fe/fe-core/src/main/java/org/apache/doris/qe/SessionVariable.java index 3c180be9d42802f..762b16656bbd92b 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/qe/SessionVariable.java +++ b/fe/fe-core/src/main/java/org/apache/doris/qe/SessionVariable.java @@ -2196,7 +2196,7 @@ public void setIgnoreShapePlanNodes(String ignoreShapePlanNodes) { needForward = true, fuzzy = false, varType = VariableAnnotation.EXPERIMENTAL ) - public boolean enableCompressMaterialize = false; + public boolean enableCompressMaterialize = true; @VariableMgr.VarAttr( name = ENABLE_AGG_SPILL,