Commit fcdc0d6e by J"orn Rennecke Committed by Joern Rennecke

sched.c (update_flow_info, REG_WAS_0): Ignore if setting insn was deleted.

	* sched.c (update_flow_info, REG_WAS_0): Ignore if setting insn
	was deleted.
	* haifa-sched.c (update_flow_info, REG_WAS_0): Likewise.

From-SVN: r17963
parent b7673cdb
Fri Feb 13 20:36:05 1998 J"orn Rennecke <amylaar@cygnus.co.uk>
* sched.c (update_flow_info, REG_WAS_0): Ignore if setting insn
was deleted.
* haifa-sched.c (update_flow_info, REG_WAS_0): Likewise.
Fri Feb 13 12:18:40 1998 Jeffrey A Law (law@cygnus.com) Fri Feb 13 12:18:40 1998 Jeffrey A Law (law@cygnus.com)
* genextract.c (main): Fix typo. * genextract.c (main): Fix typo.
......
...@@ -7978,6 +7978,14 @@ update_flow_info (notes, first, last, orig_insn) ...@@ -7978,6 +7978,14 @@ update_flow_info (notes, first, last, orig_insn)
break; break;
case REG_WAS_0: case REG_WAS_0:
/* If the insn that set the register to 0 was deleted, this
note cannot be relied on any longer. The destination might
even have been moved to memory.
This was observed for SH4 with execute/920501-6.c compilation,
-O2 -fomit-frame-pointer -finline-functions . */
if (GET_CODE (XEXP (note, 0)) == NOTE
|| INSN_DELETED_P (XEXP (note, 0)))
break;
/* This note applies to the dest of the original insn. Find the /* This note applies to the dest of the original insn. Find the
first new insn that now has the same dest, and move the note first new insn that now has the same dest, and move the note
there. */ there. */
......
...@@ -3854,6 +3854,14 @@ update_flow_info (notes, first, last, orig_insn) ...@@ -3854,6 +3854,14 @@ update_flow_info (notes, first, last, orig_insn)
break; break;
case REG_WAS_0: case REG_WAS_0:
/* If the insn that set the register to 0 was deleted, this
note cannot be relied on any longer. The destination might
even have been moved to memory.
This was observed for SH4 with execute/920501-6.c compilation,
-O2 -fomit-frame-pointer -finline-functions . */
if (GET_CODE (XEXP (note, 0)) == NOTE
|| INSN_DELETED_P (XEXP (note, 0)))
break;
/* This note applies to the dest of the original insn. Find the /* This note applies to the dest of the original insn. Find the
first new insn that now has the same dest, and move the note first new insn that now has the same dest, and move the note
there. */ there. */
......
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