Commit 108c3c88 by Martin Liska Committed by Martin Liska

Move non-local goto expansion after parm_birth_insn (PR sanitize/81186).

2017-07-26  Martin Liska  <mliska@suse.cz>

	PR sanitize/81186
	* function.c (expand_function_start): Make expansion of
	nonlocal_goto_save_area after parm_birth_insn.
2017-07-26  Martin Liska  <mliska@suse.cz>

	PR sanitize/81186
	* gcc.dg/asan/pr81186.c: New test.

From-SVN: r250561
parent 9cda17b5
2017-07-26 Martin Liska <mliska@suse.cz>
PR sanitize/81186
* function.c (expand_function_start): Make expansion of
nonlocal_goto_save_area after parm_birth_insn.
2017-07-26 Sebastian Huber <sebastian.huber@embedded-brains.de>
* config/sparc/sparc.c (sparc_option_override): Remove MASK_FPU
......
......@@ -5254,6 +5254,16 @@ expand_function_start (tree subr)
}
}
/* The following was moved from init_function_start.
The move is supposed to make sdb output more accurate. */
/* Indicate the beginning of the function body,
as opposed to parm setup. */
emit_note (NOTE_INSN_FUNCTION_BEG);
gcc_assert (NOTE_P (get_last_insn ()));
parm_birth_insn = get_last_insn ();
/* If the function receives a non-local goto, then store the
bits we need to restore the frame pointer. */
if (cfun->nonlocal_goto_save_area)
......@@ -5275,16 +5285,6 @@ expand_function_start (tree subr)
update_nonlocal_goto_save_area ();
}
/* The following was moved from init_function_start.
The move is supposed to make sdb output more accurate. */
/* Indicate the beginning of the function body,
as opposed to parm setup. */
emit_note (NOTE_INSN_FUNCTION_BEG);
gcc_assert (NOTE_P (get_last_insn ()));
parm_birth_insn = get_last_insn ();
if (crtl->profile)
{
#ifdef PROFILE_HOOK
......
2017-07-26 Martin Liska <mliska@suse.cz>
PR sanitize/81186
* gcc.dg/asan/pr81186.c: New test.
2017-07-25 Carl Love <cel@us.ibm.com>
* gcc.target/powerpc/builtins-4-p9-runnable.c: Add test file for
......
/* PR sanitizer/81186 */
/* { dg-do run } */
int
main ()
{
__label__ l;
void f ()
{
int a[123];
goto l;
}
f ();
l:
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment