On 09/12/14 21:14, lin zuojian wrote:
> Hi Kugan,
>     I have read these pdfs. My question is LRA will change the insns, so
>     why brother do the coloring so early. Changing the insns can
>     generates new pseudo registers, so they needs to re-assign. Is that
>     correct?

Hi,

IRA's job here is register allocation and LRA's job is matching the
constraints. For example, LRA might have to reload a value into a
different register class to match a constraint. To do that, LRA will
need a free register from certain register class. In order to get that
free register, LRA might have to change the IRA's allocation decision.

LRA needs the registrar allocation (that is the coloring info) and
spilled pseudo information to see if the constraints can be matched. It
iteratively have to change the insns till all the constraints are
matched. To get all the details you have to look at the code.

Thanks,
Kugan


Reply via email to