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

Zoltan Haindrich commented on CALCITE-2451:
-------------------------------------------

interesting...I think I've kinda tried it a different way; by adding more 
"logic modes" beyond unknownAsFalse ;
I feel that the most usefull part of unknownAsFalse is that it makes more 
agressive optimizations possible ; but it has a bad side: that it have to be 
manually checked / evaluated / etc - which is very error prune ; that's why I 
wanted to add logic modes...but  I've somewhere run out of time during the 
refactors to move to the new logic modes instead of "unknownAsFalse" -- I 
wanted to generalize all the existing functions to build upon questions against 
the current logic mode instead of checking the mode itself...(I've stopped 
around the part when "and" have broken up predicates into lists...)

I think that this should have to be done in smaller steps - because right now 
my branch is most probably really outdated...I think that closing down the 
RexSimplify class to be used from other classes would make it easier to make 
changes inside it...calling simplifyAnds() externally is not what would happen 
if simplify_() - for example; the strong check would not run...I think when 
features are added to rexsimplify everyone is thinking about that the 
entrypoint will be simplify()



> RexSimplify: fuse unknownAsFalse and IS TRUE handling
> -----------------------------------------------------
>
>                 Key: CALCITE-2451
>                 URL: https://issues.apache.org/jira/browse/CALCITE-2451
>             Project: Calcite
>          Issue Type: Sub-task
>          Components: core
>    Affects Versions: 1.17.0
>            Reporter: Vladimir Sitnikov
>            Assignee: Julian Hyde
>            Priority: Major
>
> It looks like {{unknownAsFalse}} duplicates {{IS_TRUE}} handling.
> In other words, {{withUnknownAsFalse(true). simplfy(expr)}} is more or less 
> comparable to {{simplify(isTrue(expr))}}
> Implementing {{IS_TRUE/IS_FALSE/...}} simplification possibilities might make 
> {{unknownAsFalse}} obsolete.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to