aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/integrate.c14
-rw-r--r--gcc/testsuite/ChangeLog4
-rw-r--r--gcc/testsuite/gcc.dg/20000707-1.c16
4 files changed, 35 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 41df73b..b9261b3 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,9 @@
2000-07-07 Jakub Jelinek <jakub@redhat.com>
+ * integrate.c (copy_insn_list): Remove REG_LABEL notes.
+
+2000-07-07 Jakub Jelinek <jakub@redhat.com>
+
* sibcall.c (uses_addressof): Add INMEM argument, check for
current_function_internal_arg_pointer outside of MEM rtxs in addition
to ADDRESSOFs.
diff --git a/gcc/integrate.c b/gcc/integrate.c
index eba94c1..93ed6d4 100644
--- a/gcc/integrate.c
+++ b/gcc/integrate.c
@@ -1581,13 +1581,21 @@ copy_insn_list (insns, map, static_chain_value)
&& map->insn_map[INSN_UID (insn)]
&& REG_NOTES (insn))
{
- rtx tem = copy_rtx_and_substitute (REG_NOTES (insn), map, 0);
+ rtx next, note = copy_rtx_and_substitute (REG_NOTES (insn), map, 0);
/* We must also do subst_constants, in case one of our parameters
has const type and constant value. */
- subst_constants (&tem, NULL_RTX, map, 0);
+ subst_constants (&note, NULL_RTX, map, 0);
apply_change_group ();
- REG_NOTES (map->insn_map[INSN_UID (insn)]) = tem;
+ REG_NOTES (map->insn_map[INSN_UID (insn)]) = note;
+
+ /* Finally, delete any REG_LABEL notes from the chain. */
+ for (; note; note = next)
+ {
+ next = XEXP (note, 1);
+ if (REG_NOTE_KIND (note) == REG_LABEL)
+ remove_note (map->insn_map[INSN_UID (insn)], note);
+ }
}
if (local_return_label)
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index e50a96c..096cea1 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,5 +1,9 @@
2000-07-07 Jakub Jelinek <jakub@redhat.com>
+ * gcc.dg/20000707-1.c: New test.
+
+2000-07-07 Jakub Jelinek <jakub@redhat.com>
+
* gcc.c-torture/execute/20000706-1.c: New test.
* gcc.c-torture/execute/20000706-2.c: New test.
* gcc.c-torture/execute/20000706-3.c: New test.
diff --git a/gcc/testsuite/gcc.dg/20000707-1.c b/gcc/testsuite/gcc.dg/20000707-1.c
new file mode 100644
index 0000000..5328dfa
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/20000707-1.c
@@ -0,0 +1,16 @@
+/* { dg-do compile } */
+/* { dg-options "-O2 -Wall" } */
+
+extern void foo(void *here);
+extern inline void bar(void)
+{
+ __label__ here;
+ foo(&&here);
+here:
+ ;
+}
+
+void baz(void)
+{
+ bar();
+}