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: line insn notes cleanups (haifa-sched and modulo-sched)


Ian Lance Taylor <iant@google.com> wrote:

>> Those hunks use the function 'find_line_note', which content is:
>> find_line_note (rtx insn)
>>  {
>>    if (no_line_numbers)
>>      return 0;
>>
>>    for (; insn; insn = PREV_INSN (insn))
>>      if (NOTE_P (insn)
>>          && NOTE_LINE_NUMBER (insn) >= 0)
>>        break;
>>
>>    return insn;
>>  }
>>
>> Since it's returning the insn that is  a line number note
(NOTE_LINE_NUMBER
>> (insn) >= 0), we decided to eliminate it.
>> Therefore, I think I'll keep it eliminated.

>My question was not about the code related to find_line_note.  I agree
>that should go.  However, this code prints "SMS loop many exits" and
>"SMS loop many BBs" regardless of whether a line note is found or not.
>There is similar code in the other hunks I mentioned.  Why should
>these fprintf statements go?  That seems like an unrelated change.

>Ian


You're completely right. Thanks for the comment.
We're going to replace the other printings with code uses the insn locators
instead of LINE_NUMBER_NOTES.
(need to find out how to do it).

Tehila.


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