Patchwork Fix location info on stack checking sequence

mail settings
Submitter Eric Botcazou
Date Nov. 12, 2010, 6:17 p.m.
Message ID <>
Download mbox | patch
Permalink /patch/71004/
State New
Headers show


Eric Botcazou - Nov. 12, 2010, 6:17 p.m.
When stack checking is still done the old way (-fstack-check=generic), the 
sequence of insns is emitted right after the prologue but generated from 
expand_function_end, so it inherits the locator of the epilogue...

Tested on i586-suse-linux, applied on the mainline as obvious.

2010-11-12  Eric Botcazou  <>

	* function.c (expand_function_end): Set the locator of the prologue on
	the stack checking insns.


Index: function.c
--- function.c	(revision 166650)
+++ function.c	(working copy)
@@ -4867,6 +4867,7 @@  expand_function_end (void)
 	      probe_stack_range (STACK_OLD_CHECK_PROTECT, max_frame_size);
 	    seq = get_insns ();
 	    end_sequence ();
+	    set_insn_locators (seq, prologue_locator);
 	    emit_insn_before (seq, stack_check_probe_note);