This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [new-ra] "#if DENIS"
- From: Denis Chertykov <denisc at overta dot ru>
- To: Michael Matz <matz at suse dot de>
- Cc: Denis Chertykov <denisc at overta dot ru>, gcc-patches at gcc dot gnu dot org
- Date: 21 Jul 2003 21:34:52 +0400
- Subject: Re: [new-ra] "#if DENIS"
- References: <Pine.LNX.4.44.0307211744090.2024-100000@wotan.suse.de>
Michael Matz <matz@suse.de> writes:
> Hi,
>
> On 16 Jul 2003, Denis Chertykov wrote:
>
> > I remember that reload (reload on insns modified by allocator) was founded
> > by me. After that I have realized assign_stack_slots and etc.
> > I can't remembered why these reloads happened.
>
> I had to disable actually doing reloads for insns in later passes, as the
> allocator doesn't expect the insns to be changed under it's foot.
Oops. I forgot about this, but I mean only last pass of allocator and
call to emit_colors and assign_stack_local inside it. I mean true
reload not a pre-reload.
>
> > > To one of those allowed by the constraints.
> >
> > You don't mark insns with spill-pseudos as ra_modified_insns.
>
> Hmm, I do, in some situations conditionalized on "if (!flag_ra_test)"
> which is false by default, so ra_modified_insns should be set for all
> modifed instruction.
I was wrong here. :(
> Tracking what insns where changed when is a bit of a mess currently
> (there is last_changed_insns for those insns changed in the current
> pass and ra_modified_insns for insns changed at all, and there is
> some overlap between the two. This should be cleaned up somewhen).
You right. last_changed_insns and ra_modified_insns may be identical.
I have added ra_modified_insns as alternative/complement of df_insn_modify.
You have added last_changed_insns after ra_modified_insns.
So, today we have a three identical things (if last_changed_insns
equal to ra_modified_insns).
>
> > Such insns isn't rescanned and will have a wrong web->regclass field.
>
> They all should be rescanned, see above. But for later passes no reloads
> are added, just the regclass field is set.
It's a thing about which I have worried.
You have disabled changing of insns in non-first pass of pre-reload.
So, if pre-reload want to change insn then it's a wrong insn and
(probably) it can't be rescanned right. The wrong classes will be choosed
for pseudos (ra_refs) and wrong web->regclass will be calculated too.
Denis.