From 5969b52d80555cf74c70931b625d340ab7c5971b Mon Sep 17 00:00:00 2001 From: Kaz Kojima Date: Sat, 19 Mar 2011 23:22:18 +0000 Subject: [PATCH] sh.c (find_barrier): Don't emit a constant pool between a call and its corresponding... * config/sh/sh.c (find_barrier): Don't emit a constant pool between a call and its corresponding CALL_ARG_LOCATION note. From-SVN: r171185 --- gcc/ChangeLog | 6 ++++++ gcc/config/sh/sh.c | 10 ++++++++++ 2 files changed, 16 insertions(+) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index bf32ebb9e50..87fb0337ecd 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2011-03-19 Kaz Kojima + + PR debug/48178 + * config/sh/sh.c (find_barrier): Don't emit a constant pool + between a call and its corresponding CALL_ARG_LOCATION note. + 2011-03-19 Anatoly Sokolov * cfgcleanup.c (mark_effect): Use bitmap_set_range/bitmap_clear_range diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c index 18bd9642f7b..fc739dd4f42 100644 --- a/gcc/config/sh/sh.c +++ b/gcc/config/sh/sh.c @@ -4876,6 +4876,16 @@ find_barrier (int num_mova, rtx mova, rtx from) || LABEL_P (from)) from = PREV_INSN (from); + /* Make sure we do not split between a call and its corresponding + CALL_ARG_LOCATION note. */ + if (CALL_P (from)) + { + rtx next = NEXT_INSN (from); + if (next && NOTE_P (next) + && NOTE_KIND (next) == NOTE_INSN_CALL_ARG_LOCATION) + from = next; + } + from = emit_jump_insn_after (gen_jump (label), from); JUMP_LABEL (from) = label; LABEL_NUSES (label) = 1; -- 2.30.2