aboutsummaryrefslogtreecommitdiff
path: root/contrib/gcc-changelog/git_commit.py
diff options
context:
space:
mode:
authorAndrew Pinski <andrew.pinski@oss.qualcomm.com>2025-10-05 22:39:35 -0700
committerAndrew Pinski <andrew.pinski@oss.qualcomm.com>2025-10-27 15:59:13 -0700
commit2f7edefc54e6967168c3cce3a4347cc0bc6a8155 (patch)
tree39fdef6b1af82bc6dc0f952581f51756edd2c920 /contrib/gcc-changelog/git_commit.py
parent374ec67294fc4f66e87e88fa67d13ee829008559 (diff)
downloadgcc-2f7edefc54e6967168c3cce3a4347cc0bc6a8155.zip
gcc-2f7edefc54e6967168c3cce3a4347cc0bc6a8155.tar.gz
gcc-2f7edefc54e6967168c3cce3a4347cc0bc6a8155.tar.bz2
[PATCH] match: simplify `VCE<bool>({0,1}) ==/!= 0` to `{0,1} ==/!= 0` [PR105749]
SRA likes to create VCE<bool>(a) when it comes to bool. This confuses a few different passes including jump threading and uninitialization warning. This removes the VCE in one case where it will help and when it is known not to have any undefined behavior since the ranges of a is known to be 0/1. This implements similar was done for PR 80635 but without VRP's help; ccp provides enough on the range/non-zeroness to implement this in match. This will fix many of the std::optional reported warnings at -O1 too. pr80635-[34].C are the same as pr80635-[12].C but compiled at -O1 rather than just -O2. PR tree-optimization/105749 PR tree-optimization/80635 gcc/ChangeLog: * match.pd (`VCE<bool>(zero_one_valued_p) ==\!= 0`): New pattern. gcc/testsuite/ChangeLog: * g++.dg/warn/pr80635-3.C: New test. * g++.dg/warn/pr80635-4.C: New test. Signed-off-by: Andrew Pinski <andrew.pinski@oss.qualcomm.com>
Diffstat (limited to 'contrib/gcc-changelog/git_commit.py')
0 files changed, 0 insertions, 0 deletions