diff options
| author | Andrew Pinski <andrew.pinski@oss.qualcomm.com> | 2025-11-12 21:06:02 -0800 |
|---|---|---|
| committer | Andrew Pinski <andrew.pinski@oss.qualcomm.com> | 2025-11-13 12:00:18 -0800 |
| commit | 0c69007b1fb98d0fe03d61d81a51e4fc6ac98ce9 (patch) | |
| tree | 69fa6e14864e9d103e13e2c08215a74351aac877 /libjava/classpath/gnu/java/beans/decoder/ArrayHandler.java | |
| parent | be54e3106ae967e8c23dca57b75525931fd28287 (diff) | |
sccp: Fix order of gimplification, removal of the phi and constant prop in sccp (3rd time) [PR122637]
This is 3rd (and hopefully last) time to fix the order here.
The previous times were r16-5093-g77e10b47f25d05 and r16-4905-g7b9d32aa2ffcb5.
The order before these patches were:
* removal of phi
* propagate constants
* gimplification of expr
* create assignment
* rewrite to undefined
* add stmts to bb
The current order before this patch (and after the other 2):
* gimplification of expr
* removal of phi
* create assignment
* propagate constants
* rewrite to undefined
* add stmts to bb
The correct and new order with this patch we have:
* gimplifcation of expr
* propagate constants
* removal of phi
* create the assignment
* rewrite to undefined
* add stmts to bb
This is because the propagate of the constant will cause a fold_stmt which requires
the statement in the IR still. The gimplifcation of expr also calls fold_stmt.
Now with the new order the phi is not removed until right before the creation of the
new assigment so the IR in the basic block is well defined while calling fold_stmt.
Pushed as obvious after bootstrap/test on x86_64-linux-gnu.
PR tree-optimization/122637
gcc/ChangeLog:
* tree-scalar-evolution.cc (final_value_replacement_loop): Fix order
of gimplification and constant prop.
gcc/testsuite/ChangeLog:
* gcc.dg/torture/pr122637-1.c: New test.
Signed-off-by: Andrew Pinski <andrew.pinski@oss.qualcomm.com>
Diffstat (limited to 'libjava/classpath/gnu/java/beans/decoder/ArrayHandler.java')
0 files changed, 0 insertions, 0 deletions
