This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: cfg merge part 19 - gcse tweek
- From: Jan Hubicka <jh at suse dot cz>
- To: Joern Rennecke <joern dot rennecke at superh dot com>
- Cc: Jan Hubicka <jh at suse dot cz>, gcc-patches at gcc dot gnu dot org, law at redhat dot com
- Date: Thu, 6 Jun 2002 14:45:45 +0200
- Subject: Re: cfg merge part 19 - gcse tweek
- References: <3CFF589A.9D13FDA0@superh.com>
> > Hi,
> > this is small patch from cfg-branch. It's purpose is to make gcse to drop
> > REG_EQUAL note when it GCSEes out the real computation so the local passes
> > won't lose track of what is going on.
>
> > It helps to avoid negative results of my next GCSE patch to switch it
> > into code hoisting functions (that patch needs liveness that is still
> > discussed), but anyway this has small positive effect.
>
> > Bootstrapped/regtested i386.
> > Honza
>
> > Mon May 27 13:53:16 CEST 2002 Jan Hubicka <jh@suse.cz>
> > * gcse.c (gcse_emit_move_after): New.
> > (pre_delete, hoist_store): Use it.
>
> You delete the check to verify that the change is valid. I don't see any
> code that you have added to check validity before. Worse, instead of
> changing an instruction that is already valid, you generate an ad-hoc
> instruction pattern, altogether ignoring the machine description.
There is code veirfying that the operand can be moved in want_to_gcse_p,
but I see it is not checking whetehr simple reg-reg set works. I guess
it is safe to use emit_move_instructions, as generally it can not have
side effects, since some passes, like reload insert moves at random
places anyway.
I will send a patch tonight.
Honza