This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug optimization/14797] [tree-ssa] propagate constants back to PHI
- From: "kazu at cs dot umass dot edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 31 Mar 2004 15:32:25 -0000
- Subject: [Bug optimization/14797] [tree-ssa] propagate constants back to PHI
- References: <20040331104555.14797.kazu@cs.umass.edu>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From kazu at cs dot umass dot edu 2004-03-31 15:32 -------
I don't know where to draw a line. Even for the last example, i386
port converts the code to
b = a != 0;
b--;
b &= 500;
b += 201;
but this would be a nightmare on ports without setcc (like h8).
Maybe we could keep anything more complex than "c = a COND b" in the
if-then-else form (assuming we don't want to introduce
machine-dependent if-conversion pass at tree level). If we don't want
to rely on rtl optimizers to do if-conversion, we could put a flag to
"if" to indicate that that's an if-conversion candidate (just like
tail-call flag) and then do the if-conversion at the expand time.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14797