Commit c39a4ad7 by Jan Hubicka Committed by H.J. Lu

ira-emit.c (change_regs): Return false when replacing reg by itself.

2008-10-15  Jan Hubicka  <jh@suse.cz>

	* ira-emit.c (change_regs): Return false when replacing reg by
	itself.

From-SVN: r141163
parent aac375dd
2008-10-15 Jan Hubicka <jh@suse.cz>
* ira-emit.c (change_regs): Return false when replacing reg by
itself.
2008-10-14 Vladimir Makarov <vmakarov@redhat.com> 2008-10-14 Vladimir Makarov <vmakarov@redhat.com>
PR target/37633 PR target/37633
......
...@@ -137,6 +137,7 @@ change_regs (rtx *loc) ...@@ -137,6 +137,7 @@ change_regs (rtx *loc)
int i, regno, result = false; int i, regno, result = false;
const char *fmt; const char *fmt;
enum rtx_code code; enum rtx_code code;
rtx reg;
if (*loc == NULL_RTX) if (*loc == NULL_RTX)
return false; return false;
...@@ -151,7 +152,10 @@ change_regs (rtx *loc) ...@@ -151,7 +152,10 @@ change_regs (rtx *loc)
return false; return false;
if (ira_curr_regno_allocno_map[regno] == NULL) if (ira_curr_regno_allocno_map[regno] == NULL)
return false; return false;
*loc = ALLOCNO_REG (ira_curr_regno_allocno_map[regno]); reg = ALLOCNO_REG (ira_curr_regno_allocno_map[regno]);
if (reg == *loc)
return false;
*loc = reg;
return true; return true;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment