aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/ada/acats-2/tests/d
diff options
context:
space:
mode:
authorAndrew Pinski <quic_apinski@quicinc.com>2025-07-25 13:54:32 -0700
committerAndrew Pinski <quic_apinski@quicinc.com>2025-07-28 10:24:51 -0700
commita51bf9e10182cf7ac858db0ea6c5cb11b4f12377 (patch)
treee171c442f9fbbbe723044b357f82afd6ea25cdac /gcc/testsuite/ada/acats-2/tests/d
parent5760ddbce26ff9c5c8851b6b2089ad65981d5078 (diff)
downloadgcc-master.zip
gcc-master.tar.gz
gcc-master.tar.bz2
ifcvt: Fix ifcvt for multiple phi nodes after factoring operator [PR121236]HEADtrunkmaster
When I added the factor operations to ifcvt, I messed how handling of removing the phi nodes. The fix is we need to remove the phi node that was factored out as we factored out the operator because otherwise scev can go when it comes to detecting if the new args are from a reduction. Also the need to change the interface for is_cond_scalar_reduction as the phi node that was being passed after the factoring no longer exists so need to pass the parts that were being used. PR tree-optimization/121236 gcc/ChangeLog: * tree-if-conv.cc (is_cond_scalar_reduction): Instead of phi argument, pass bb and res of the phi. (factor_out_operators): Add iterator for the phi. Remove the phi if this is the first time. Return if we had removed the phi. (predicate_scalar_phi): Add the phi iterator argument. Update call to is_cond_scalar_reduction. Update call to factor_out_operators and set the return value to true when factor_out_operators returns true. (predicate_all_scalar_phis): Don't remove the phi if predicate_scalar_phi already removed it. gcc/testsuite/ChangeLog: * gcc.dg/torture/pr121236-1.c: New test. Signed-off-by: Andrew Pinski <quic_apinski@quicinc.com>
Diffstat (limited to 'gcc/testsuite/ada/acats-2/tests/d')
0 files changed, 0 insertions, 0 deletions