This is the mail archive of the 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: [patch] Fix PR rtl-optimization/87727

On 12/20/18 2:30 PM, Peter Bergner wrote:
> On 12/20/18 2:26 PM, Segher Boessenkool wrote:
>> On Thu, Dec 20, 2018 at 09:07:41PM +0100, Eric Botcazou wrote:
>>>> It's not a terrible workaround, no.  It looks like it will make some asm
>>>> once again fail though?  If argument registers are forwarded to in the asm.
>>> The combiner change looks like a big hammer for such a corner case though.
>> That isn't the primary goal, no; the primary goal is to get better RA (by
>> not having the combiner do RA's work, and doing a mediocre job of it).  It
>> does solve these problems though.
> My recent RA patches improved conflict information by noticing when we
> don't need a conflict for a copy insn between a hard reg and a pseudo
> when the source operand is live past the copy.  However, conflict info
> for copies between two pseudos wasn't affected because IRA/LRA computes
> liveness differently for pseudos than for hard regs.  I have seen copies
> between two pseudos still get to RA and we're not able to do anything
> about them at the moment because we still think they conflict.
> For stage1, I'd like to fix that conflict wart if I can.  I have also
> wondered about adding a copy coalesce phase just before we enter RA,
> which would ensure the copies are removed, instead of hoping RA assigns
> the same reg to the source and destination of the copy making it a nop
> that can be removed.
The difficulty with coalescing is that if you get too aggressive then
you end up removing degrees of freedom from the allocator and you can
easily make the final results worse.


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