]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
* function.c (emit_use_return_register_into_block): On cc0 targets,
authorebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 25 Mar 2013 11:24:12 +0000 (11:24 +0000)
committerebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 25 Mar 2013 11:24:12 +0000 (11:24 +0000)
do not emit the sequence between cc0 setter and user.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@197036 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/function.c

index c782c040774408002923b5d4b53df1ccc7bca84f..072efd7d65a41ec8780e70e58b68e75aa7f39ad6 100644 (file)
@@ -1,7 +1,12 @@
+2013-03-25  Eric Botcazou  <ebotcazou@adacore.com>
+
+       * function.c (emit_use_return_register_into_block): On cc0 targets,
+       do not emit the sequence between cc0 setter and user.
+
 2013-03-25  Kai Tietz  <ktietz@redhat.com>
 
-        * config/i386/predicates.md (local_symbolic_operand): Interpret
-        dll-imported symbols as none-local.
+       * config/i386/predicates.md (local_symbolic_operand): Interpret
+       dll-imported symbols as none-local.
 
 2013-03-25  Richard Biener  <rguenther@suse.de>
 
index 5419b88593dfbaf27eabf4f13ff298c7c180ef1c..cd9cb855d40e72992932dca83c7a9905e37aab55 100644 (file)
@@ -5598,12 +5598,17 @@ prepare_shrink_wrap (basic_block entry_block)
 static void
 emit_use_return_register_into_block (basic_block bb)
 {
-  rtx seq;
+  rtx seq, insn;
   start_sequence ();
   use_return_register ();
   seq = get_insns ();
   end_sequence ();
-  emit_insn_before (seq, BB_END (bb));
+  insn = BB_END (bb);
+#ifdef HAVE_cc0
+  if (reg_mentioned_p (cc0_rtx, PATTERN (insn)))
+    insn = prev_cc0_setter (insn);
+#endif
+  emit_insn_before (seq, insn);
 }