Skip to content

[fix](Nereids) fold constant for logical operator#20017

Merged
morrySnow merged 1 commit intoapache:masterfrom
morrySnow:gix_constant_or_and
May 25, 2023
Merged

[fix](Nereids) fold constant for logical operator#20017
morrySnow merged 1 commit intoapache:masterfrom
morrySnow:gix_constant_or_and

Conversation

@morrySnow
Copy link
Contributor

@morrySnow morrySnow commented May 24, 2023

Proposed changes

Issue Number: close #xxx

Problem summary

the rule of constant folding on Logical Operator is:

true and true -> true
true and false -> false
false and false -> false
true and x -> x
false and x -> false
null and true -> null
null and false -> false
null and null -> null
null and x -> null and x

true or true -> true
true or false -> true
false or false -> false
true or x -> true
false or x -> false or x
null or true -> true
null or false -> null
null or null -> null
null or x -> null or x

Checklist(Required)

  • Does it affect the original behavior
  • Has unit tests been added
  • Has document been added or modified
  • Does it need to update dependencies
  • Is this PR support rollback (If NO, please explain WHY)

Further comments

If this is a relatively large or complex change, kick off the discussion at dev@doris.apache.org by explaining why you chose the solution you did and what alternatives you considered, etc...

@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label May 24, 2023
@github-actions
Copy link
Contributor

PR approved by at least one committer and no changes requested.

@github-actions
Copy link
Contributor

PR approved by anyone and no changes requested.

@yiguolei
Copy link
Contributor

run buildall

@hello-stephen
Copy link
Contributor

TeamCity pipeline, clickbench performance test result:
the sum of best hot time: 34.79 seconds
stream load tsv: 444 seconds loaded 74807831229 Bytes, about 160 MB/s
stream load json: 21 seconds loaded 2358488459 Bytes, about 107 MB/s
stream load orc: 58 seconds loaded 1101869774 Bytes, about 18 MB/s
stream load parquet: 30 seconds loaded 861443392 Bytes, about 27 MB/s
insert into select: 25.8 seconds inserted 10000000 Rows, about 387K ops/s
https://doris-community-test-1308700295.cos.ap-hongkong.myqcloud.com/tmp/20230525011755_clickbench_pr_150019.html

@morrySnow morrySnow merged commit c49060a into apache:master May 25, 2023
@morrySnow morrySnow deleted the gix_constant_or_and branch June 29, 2023 09:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by one committer. area/nereids reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

Comments