rl78.c (rl78_alloc_physical_registers): Check for SET before extracting SET_SRC.
* config/rl78/rl78.c (rl78_alloc_physical_registers): Check for SET before extracting SET_SRC. (rl78_remove_unused_sets): Check for REG before extractnig REGNO. From-SVN: r190278
This commit is contained in:
parent
23459cbecd
commit
1c6b102126
2 changed files with 9 additions and 2 deletions
|
@ -1,3 +1,9 @@
|
|||
2012-08-09 DJ Delorie <dj@redhat.com>
|
||||
|
||||
* config/rl78/rl78.c (rl78_alloc_physical_registers): Check for
|
||||
SET before extracting SET_SRC.
|
||||
(rl78_remove_unused_sets): Check for REG before extractnig REGNO.
|
||||
|
||||
2012-08-09 Oleg Endo <olegendo@gcc.gnu.org>
|
||||
|
||||
PR target/54089
|
||||
|
|
|
@ -2217,7 +2217,8 @@ rl78_alloc_physical_registers (void)
|
|||
&& GET_CODE (PATTERN (insn)) != CALL)
|
||||
continue;
|
||||
|
||||
if (GET_CODE (SET_SRC (PATTERN (insn))) == ASM_OPERANDS)
|
||||
if (GET_CODE (PATTERN (insn)) == SET
|
||||
&& GET_CODE (SET_SRC (PATTERN (insn))) == ASM_OPERANDS)
|
||||
continue;
|
||||
|
||||
valloc_method = get_attr_valloc (insn);
|
||||
|
@ -2644,7 +2645,7 @@ rl78_remove_unused_sets (void)
|
|||
|
||||
dest = SET_DEST (insn);
|
||||
|
||||
if (REGNO (dest) > 23)
|
||||
if (GET_CODE (dest) != REG || REGNO (dest) > 23)
|
||||
continue;
|
||||
|
||||
if (find_regno_note (insn, REG_UNUSED, REGNO (dest)))
|
||||
|
|
Loading…
Add table
Reference in a new issue