mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-12 20:21:45 +08:00
calls.c (compute_argument_addresses): Force stack slots into alias set 0.
* calls.c (compute_argument_addresses): Force stack slots into alias set 0. * expr.c (emit_push_insn): Force pushes into alias set 0. From-SVN: r34662
This commit is contained in:
parent
054451eaca
commit
7ab923ccff
@ -1,3 +1,9 @@
|
||||
2000-06-23 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
* calls.c (compute_argument_addresses): Force stack slots into
|
||||
alias set 0.
|
||||
* expr.c (emit_push_insn): Force pushes into alias set 0.
|
||||
|
||||
2000-06-23 Richard Henderson <rth@cygnus.com>
|
||||
|
||||
* config/ia64/ia64.md (pred_rel_mutex): Only take one register.
|
||||
|
@ -1595,6 +1595,13 @@ compute_argument_addresses (args, argblock, num_actuals)
|
||||
args[i].stack_slot = gen_rtx_MEM (args[i].mode, addr);
|
||||
set_mem_attributes (args[i].stack_slot,
|
||||
TREE_TYPE (args[i].tree_value), 1);
|
||||
|
||||
/* Function incoming arguments may overlap with sibling call
|
||||
outgoing arguments and we cannot allow reordering of reads
|
||||
from function arguments with stores to outgoing arguments
|
||||
of sibling calls. */
|
||||
MEM_ALIAS_SET (args[i].stack) = 0;
|
||||
MEM_ALIAS_SET (args[i].stack_slot) = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
37
gcc/expr.c
37
gcc/expr.c
@ -3052,6 +3052,8 @@ emit_push_insn (x, mode, type, size, align, partial, reg, extra,
|
||||
else
|
||||
#endif /* PUSH_ROUNDING */
|
||||
{
|
||||
rtx target;
|
||||
|
||||
/* Otherwise make space on the stack and copy the data
|
||||
to the address of that space. */
|
||||
|
||||
@ -3086,8 +3088,6 @@ emit_push_insn (x, mode, type, size, align, partial, reg, extra,
|
||||
skip));
|
||||
if (current_function_check_memory_usage && ! in_check_memory_usage)
|
||||
{
|
||||
rtx target;
|
||||
|
||||
in_check_memory_usage = 1;
|
||||
target = copy_to_reg (temp);
|
||||
if (GET_CODE (x) == MEM && type && AGGREGATE_TYPE_P (type))
|
||||
@ -3104,27 +3104,29 @@ emit_push_insn (x, mode, type, size, align, partial, reg, extra,
|
||||
in_check_memory_usage = 0;
|
||||
}
|
||||
|
||||
target = gen_rtx_MEM (BLKmode, temp);
|
||||
|
||||
if (type != 0)
|
||||
{
|
||||
set_mem_attributes (target, type, 1);
|
||||
/* Function incoming arguments may overlap with sibling call
|
||||
outgoing arguments and we cannot allow reordering of reads
|
||||
from function arguments with stores to outgoing arguments
|
||||
of sibling calls. */
|
||||
MEM_ALIAS_SET (target) = 0;
|
||||
}
|
||||
|
||||
/* TEMP is the address of the block. Copy the data there. */
|
||||
if (GET_CODE (size) == CONST_INT
|
||||
&& MOVE_BY_PIECES_P ((unsigned) INTVAL (size), align))
|
||||
{
|
||||
rtx target = gen_rtx_MEM (BLKmode, temp);
|
||||
|
||||
if (type != 0)
|
||||
set_mem_attributes (target, type, 1);
|
||||
|
||||
move_by_pieces (gen_rtx_MEM (BLKmode, temp), xinner,
|
||||
INTVAL (size), align);
|
||||
move_by_pieces (target, xinner, INTVAL (size), align);
|
||||
goto ret;
|
||||
}
|
||||
else
|
||||
{
|
||||
rtx opalign = GEN_INT (align / BITS_PER_UNIT);
|
||||
enum machine_mode mode;
|
||||
rtx target = gen_rtx_MEM (BLKmode, temp);
|
||||
|
||||
if (type != 0)
|
||||
set_mem_attributes (target, type, 1);
|
||||
|
||||
for (mode = GET_CLASS_NARROWEST_MODE (MODE_INT);
|
||||
mode != VOIDmode;
|
||||
@ -3293,7 +3295,14 @@ emit_push_insn (x, mode, type, size, align, partial, reg, extra,
|
||||
|
||||
dest = gen_rtx_MEM (mode, addr);
|
||||
if (type != 0)
|
||||
set_mem_attributes (dest, type, 1);
|
||||
{
|
||||
set_mem_attributes (dest, type, 1);
|
||||
/* Function incoming arguments may overlap with sibling call
|
||||
outgoing arguments and we cannot allow reordering of reads
|
||||
from function arguments with stores to outgoing arguments
|
||||
of sibling calls. */
|
||||
MEM_ALIAS_SET (dest) = 0;
|
||||
}
|
||||
|
||||
emit_move_insn (dest, x);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user