[Bug middle-end/48016] New: Inconsistency in non-local goto save area
hjl.tools at gmail dot com
gcc-bugzilla@gcc.gnu.org
Mon Mar 7 14:06:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48016
Summary: Inconsistency in non-local goto save area
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: middle-end
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: hjl.tools@gmail.com
We have
void
emit_stack_save (enum save_level save_level, rtx *psave)
{
rtx sa = *psave;
/* The default is that we use a move insn and save in a Pmode object. */
rtx (*fcn) (rtx, rtx) = gen_move_insn;
enum machine_mode mode = STACK_SAVEAREA_MODE (save_level);
....
void
update_nonlocal_goto_save_area (void)
{
tree t_save;
rtx r_save;
/* The nonlocal_goto_save_area object is an array of N pointers. The
first one is used for the frame pointer save; the rest are sized by
STACK_SAVEAREA_MODE. Create a reference to array index 1, the first
of the stack save area slots. */
t_save = build4 (ARRAY_REF, ptr_type_node, cfun->nonlocal_goto_save_area,
integer_one_node, NULL_TREE, NULL_TREE);
r_save = expand_expr (t_save, NULL_RTX, VOIDmode, EXPAND_WRITE);
emit_stack_save (SAVE_NONLOCAL, &r_save);
}
The mode of PSAVE passed to emit_stack_save is the mode of
ptr_type_node, which may not be STACK_SAVEAREA_MODE which
is expected by emit_stack_save.
More information about the Gcc-bugs
mailing list