This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

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?


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]