summaryrefslogtreecommitdiff
path: root/gcc/var-tracking.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/var-tracking.c')
-rw-r--r--gcc/var-tracking.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/var-tracking.c b/gcc/var-tracking.c
index 815facae182..c4bef66d5e2 100644
--- a/gcc/var-tracking.c
+++ b/gcc/var-tracking.c
@@ -2443,7 +2443,9 @@ emit_note_insn_var_location (void **varp, void *data)
complete = false;
if (where == EMIT_NOTE_AFTER_INSN)
- note = emit_note_after (NOTE_INSN_VAR_LOCATION, insn);
+ /* emit_note_after can insert a note after a flow-control insn in a basic
+ block. That causes verify_flow_info failures. */
+ note = emit_note_before (NOTE_INSN_VAR_LOCATION, NEXT_INSN (insn));
else
note = emit_note_before (NOTE_INSN_VAR_LOCATION, insn);