This is the mail archive of the gcc-patches@gcc.gnu.org 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: [3/4] SMS: Record moves in the partial schedule


Ayal Zaks <ayal.zaks@gmail.com> writes:
> On Wed, Sep 28, 2011 at 4:53 PM, Richard Sandiford
> <richard.sandiford@linaro.org> wrote:
>> Ayal Zaks <ayal.zaks@gmail.com> writes:
>>>>> Only request is to document that the register moves are
>>>>> placed/assigned-id'sÂin a specific order.
>>>>
>>>>I suppose this is the downside of splitting the patches up, sorry,
>>>>but the ids are only ordered for the throw-away loop:
>>>>
>>>>ÂFOR_EACH_VEC_ELT_REVERSE (ps_reg_move_info, ps->reg_moves, i, move)
>>>>Â Âadd_insn_before (move->insn, ps_first_note (ps, move->def), NULL);
>>>>
>>>>and for the prologue/epilogue code. ÂBoth are replaced in patch 4
>>>>with code that doesn't rely on the ordering of ids.
>>> Ok then, very well. I was mostly referring to the following in
>>> prologue/epiloque code, which merely relies on assigningÂall regmoves
>>> of a node consecutive id's:
>>
>> FWIW, the 4/4 that I just posted did finally get rid of the first_reg_move
>> & nreg_moves fields.
>>
>> Here's a slightly updated patch in line with your 4/4 comments.
>> The move->def is now always the id of the predecessor, rather than
>> the id of the original ddg node producer. ÂI've adapted the throw-away
>> loop accordingly, but there are no other changes.
>>
>
> This is ok.

Thanks.

> Just to make sure I follow, the changes were (for this patch):
>
> 1. setting up a different move->def for each move
>
>> +         move->def = i_reg_move > 0 ? first_move + i_reg_move - 1 : i;
>
> instead of the same original def for all
>
>> +      move->def = i;
>
> 2. inserting each move right before its own def, bottom-up:
>
>> +  FOR_EACH_VEC_ELT (ps_reg_move_info, ps->reg_moves, i, move)
>> +    add_insn_before (move->insn, ps_first_note (ps, move->def), NULL);
>
> instead of inserting each move right before the original def, top-down:
>
>>>> FOR_EACH_VEC_ELT_REVERSE (ps_reg_move_info, ps->reg_moves, i, move)
>>>>   add_insn_before (move->insn, ps_first_note (ps, move->def), NULL);

Yeah, those were the ones.

Richard


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