summaryrefslogtreecommitdiff
path: root/gcc/emit-rtl.c
diff options
context:
space:
mode:
authorhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2007-04-01 19:48:01 +0000
committerhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2007-04-01 19:48:01 +0000
commit4486418e176c6c8fc4c3f2ecb12f130406c46e89 (patch)
treed0643ac498a8717ec42054fe964056ce95cc37e2 /gcc/emit-rtl.c
parent41456429d0333227c6abe2fd87ef2eba382c5170 (diff)
downloadgcc-4486418e176c6c8fc4c3f2ecb12f130406c46e89.tar.gz
* emit-rtl.c (emit_insn_before_setloc): Do not ICE when asked to emit
before very first instruction. * ggc-page.c (ggc_print_statistics): Fix formatting string to avoid waring on 64bit hosts. * bitmap.h: Fix typo in bitmap_head_def. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@123408 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r--gcc/emit-rtl.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index ebe0a52e7d9..16fa6c5ed7c 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -4220,7 +4220,10 @@ emit_insn_before_setloc (rtx pattern, rtx before, int loc)
if (pattern == NULL_RTX || !loc)
return last;
- first = NEXT_INSN (first);
+ if (!first)
+ first = get_insns ();
+ else
+ first = NEXT_INSN (first);
while (1)
{
if (active_insn_p (first) && !INSN_LOCATOR (first))