This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Properly handle VIEW_CONVERT_EXPR in LHS (fixes 4.5 ACATS tests)
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- To: rth at redhat dot com
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Mon, 29 Nov 04 21:10:02 EST
- Subject: Re: Properly handle VIEW_CONVERT_EXPR in LHS (fixes 4.5 ACATS tests)
const_val must satisfy is_gimple_min_invariant, because it is
substituted into PHI nodes. In some cases, you may be able to
construct a correct replacement, but in others it'll be tricky.
I suggest
w = fold (build1 (VIEW_CONVERT_EXPR, ...))
if (is_gimple_min_invariant (w))
...
Well, fold doesn't do anything for VIEW_CONVERT_EXPR now unless the input
is also a VIEW_CONVERT_EXPR, which it isn't. So that condition will
never be true.
I thought these substitutions were for other statements, not PHI nodes?
If indeed it must be a constant, then what do we record in that case,
UNKNOWN?