aboutsummaryrefslogtreecommitdiff
path: root/gcc/optabs.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/optabs.c')
-rw-r--r--gcc/optabs.c24
1 files changed, 13 insertions, 11 deletions
diff --git a/gcc/optabs.c b/gcc/optabs.c
index 85bb24e..5f2a76a 100644
--- a/gcc/optabs.c
+++ b/gcc/optabs.c
@@ -2758,19 +2758,21 @@ emit_libcall_block (insns, target, result, equiv)
rtx prev, next, first, last, insn;
/* look for any CALL_INSNs in this sequence, and attach a REG_EH_REGION
- reg note to indicate that this call cannot throw. (Unless there is
- already a REG_EH_REGION note.) */
+ reg note to indicate that this call cannot throw or execute a nonlocal
+ goto. (Unless there is already a REG_EH_REGION note, in which case
+ we update it.) */
for (insn = insns; insn; insn = NEXT_INSN (insn))
- {
- if (GET_CODE (insn) == CALL_INSN)
- {
- rtx note = find_reg_note (insn, REG_EH_REGION, NULL_RTX);
- if (note == NULL_RTX)
- REG_NOTES (insn) = gen_rtx_EXPR_LIST (REG_EH_REGION, GEN_INT (-1),
- REG_NOTES (insn));
- }
- }
+ if (GET_CODE (insn) == CALL_INSN)
+ {
+ rtx note = find_reg_note (insn, REG_EH_REGION, NULL_RTX);
+
+ if (note != 0)
+ XEXP (note, 0) = GEN_INT (-1);
+ else
+ REG_NOTES (insn) = gen_rtx_EXPR_LIST (REG_EH_REGION, GEN_INT (-1),
+ REG_NOTES (insn));
+ }
/* First emit all insns that set pseudos. Remove them from the list as
we go. Avoid insns that set pseudos which were referenced in previous