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: [PATCH IRA] update_equiv_regs fails to set EQUIV reg-note for pseudo with more than one definition


On 02/12/15 05:40, Alex Velenko wrote:
On 09/02/15 23:32, Jeff Law wrote:
On 02/03/15 20:03, Bin.Cheng wrote:
I looked into the test and can confirm the previous compilation is
correct.
The cover letter of this patch said IRA mis-handled REQ_EQUIV before,
but in this case it is REG_EQUAL that is lost.  The full dump (without
this patch) after IRA is like:
Right, but a REG_EQUIV is generated based on the incoming REG_EQUAL
notes in the insn stream.  Basically update_equiv_regs will scan insn
stream and some REG_EQUAL notes will be promoted to REG_EQUIV notes.

Hi Jeff,
Do I understand you correctly, that REG_EQUAL notes should not be
generated in IRA pass, because some of them may get promoted to
REG_EQUIV? Or is there any other reason register r110 should not get
REG_EQUAL note? Previously, register r110 was getting REG_EQUAL, not
REG_EQUIV note.
The reason r110 can not get a REG_EQUIV note is because there are multiple insns that set r110 to different values.

The equivalency created by a REG_EQUIV note has to be valid at every point within the function. Thus for any pseudo that holds > 1 distinct value within a function there can be no valid REG_EQUIV notes on the assignments to that pseudo.



jeff


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