You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (JIRA)" <ji...@apache.org> on 2016/11/23 03:44:58 UTC

[jira] [Commented] (CALCITE-1505) Enable constant reduction rules

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

Julian Hyde commented on CALCITE-1505:
--------------------------------------

I'm not sure, but I suspect that it's because constant reduction is expensive or because it requires the user to specify a {{RelOptPlanner.Executor}}. Try changing the {{false}} to {{true}} and see whether anything breaks in the test suite (or if the test suite gets noticeably slower).

I see that {{CalcitePrepareImpl.CONSTANT_REDUCTION_RULES}} is private, and that's a shame. It would probably be useful if constant reduction was packaged up as a program (in {{Programs}}, say) so that people rolling their own planner could do constant reduction as an early and a late phase in planning.

Powerful ingredients like constant reduction are best used sparingly.

> Enable constant reduction rules
> -------------------------------
>
>                 Key: CALCITE-1505
>                 URL: https://issues.apache.org/jira/browse/CALCITE-1505
>             Project: Calcite
>          Issue Type: Improvement
>          Components: core
>            Reporter: Andreas Damm
>            Assignee: Julian Hyde
>            Priority: Minor
>
> In CalcitePrepareImpl.createPlanner/3 the constant reduction rules are always disabled ("if (false) ...") with a comment stating "Change the below to enable constant-reduction". Are these rules working? Why are they excluded?



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