]> gcc.gnu.org Git - gcc.git/commit
Swap loop splitting and final value replacement
authorRichard Biener <rguenther@suse.de>
Thu, 3 Aug 2023 08:59:52 +0000 (10:59 +0200)
committerRichard Biener <rguenther@suse.de>
Thu, 3 Aug 2023 11:20:00 +0000 (13:20 +0200)
commit3d48c11ad082def8ee237e5778d8a5d569bff96d
tree9b254147c9b6be872a17208f62d62bf38b24935c
parentfab08d12b40ad637c5a4ce8e026fb43cd3f0fad1
Swap loop splitting and final value replacement

The following swaps the loop splitting pass and the final value
replacement pass to avoid keeping the IV of the earlier loop
live when not necessary.  The existing gcc.target/i386/pr87007-5.c
testcase shows that we otherwise fail to elide an empty loop
later.  I don't see any good reason why loop splitting would need
final value replacement, all exit values honor the constraints
we place on loop header PHIs automatically.

* passes.def: Exchange loop splitting and final value
replacement passes.

* gcc.target/i386/pr87007-5.c: Make sure we split the loop
and eliminate both in the end.
gcc/passes.def
gcc/testsuite/gcc.target/i386/pr87007-5.c
This page took 0.074344 seconds and 5 git commands to generate.