This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug optimization/13629] [tree-ssa][Regression] dominator optimizations can pessimize code
- From: "law at redhat dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 16 Jan 2004 02:37:24 -0000
- Subject: [Bug optimization/13629] [tree-ssa][Regression] dominator optimizations can pessimize code
- References: <20040109121229.13629.steven@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From law at redhat dot com 2004-01-16 02:37 -------
Subject: Re: [tree-ssa][Regression] dominator
optimizations can pessimize code
In message <20040115235224.12798.qmail@sources.redhat.com>, "steven at gcc dot
gnu dot org" writes:
>
>------- Additional Comments From steven at gcc dot gnu dot org 2004-01-15 23
>:52 -------
>Running a DCE pass before DOM1 cures the problem:
>
>Resulting assembly with tree-ssa + patch.DCE_before_DOM1:
>partial_dead:
> movl 4(%esp), %edx
> movl 8(%esp), %eax
> testl %eax, %edx
> je .L1
> imull %eax, %edx
> movl data, %eax
> movl %edx, (%eax)
>.L1:
> ret
I mentioned this as a short term plan to Diego yesterday, so consider it
on my todo list (though it looks like you're already doing some of the
evaluation of how that impacts the compiler which will definitely make
my life easier :-)
Long term we may want to handle this with partial dead code elimination
since real code often has partial dead code which we would like to be
able to move to eliminate it on paths where it's not needed.
jeff
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13629