This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
Re: Patch: Update jacks.xfail for the tree-ssa merge
- From: Jeff Sturm <jsturm at one-point dot com>
- To: Ranjit Mathew <rmathew at gmail dot com>
- Cc: tromey at redhat dot com, <java-patches at gcc dot gnu dot org>
- Date: Sun, 16 May 2004 19:33:53 -0400 (EDT)
- Subject: Re: Patch: Update jacks.xfail for the tree-ssa merge
On Sun, 16 May 2004, Ranjit Mathew wrote:
> All of the failures:
>
> 16.1.7-simple-definite-unassignment-pass-1
> 16.2.10-definite-unassign-pass-3
> 16.2.11-definite-unassign-pass-3
> 16.2.9-definite-unassign-pass-3
> non-jls-jsr41.2-nesting-1
>
> arise because we now no longer optimise away an if-else statement
> if the condition is constant. This change was done as a part of the
> original gimplification of Java (see patch_if_else_statement):
>
> http://gcc.gnu.org/ml/java-patches/2003-q2/msg00409.html
Wow... good catch! (Sheepishly, I don't remember whether I ran jacks
against the original gimplifier patch or not. Probably not.)
This part of the message gives a clue why I must have deleted that
optimization from the parser:
>Most of the conversion is handled in java_simplify_expr, however there are
>other changes due to certain trees that are not acceptable to gimplify
>even though they are accepted by the RTL expanders. For example,
>LOOP_EXPR nodes with trailing empty statements cause an incorrect CFG to
>be constructed, breaking copy/constant propogation.
Besides, I figured it was bogus that the parser tries to optimize
these cases at all, instead of leaving the job up to DCE. I clearly
wasn't thinking about definite assignment at the time :-(
> So we can't simply throw away the dead portion of an if-else
> statement with a constant condition.
Perhaps we could ignore the dead branch somwhere within
check_for_initialization?
The 5 new failures should get fixed somehow. I'm not comfortable with
trading new passes for regressions, whatever the numbers are.
Jeff