diff options
author | Hans-Peter Nilsson <hp@axis.com> | 2019-05-22 00:30:42 +0000 |
---|---|---|
committer | Hans-Peter Nilsson <hp@gcc.gnu.org> | 2019-05-22 00:30:42 +0000 |
commit | 325437b2a329715da7be4de792af052c19a0ac7b (patch) | |
tree | 0276a04a3ce7e0505e572d81fbade46dba877f6e /gcc/function.c | |
parent | 0fd67989f9c53aa85ea803941882c997e9c4d012 (diff) | |
download | gcc-325437b2a329715da7be4de792af052c19a0ac7b.zip gcc-325437b2a329715da7be4de792af052c19a0ac7b.tar.gz gcc-325437b2a329715da7be4de792af052c19a0ac7b.tar.bz2 |
In <https://gcc.gnu.org/ml/gcc-patches/2019-05/msg01417.html>...
In <https://gcc.gnu.org/ml/gcc-patches/2019-05/msg01417.html>:
...a change introduced in r94104 where BITS_PER_WORD was chosenperhaps because we expect register-sized writes into this area.
See <https://gcc.gnu.org/ml/gcc-patches/2005-01/msg01564.html>
for the r94104 change.
* function.c (assign_parm_setup_block): Raise alignment of
stacked parameter only for STRICT_ALIGNMENT targets.
From-SVN: r271497
Diffstat (limited to 'gcc/function.c')
-rw-r--r-- | gcc/function.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/function.c b/gcc/function.c index c6e862b..e30ee25 100644 --- a/gcc/function.c +++ b/gcc/function.c @@ -2912,7 +2912,11 @@ assign_parm_setup_block (struct assign_parm_data_all *all, size_stored = CEIL_ROUND (size, UNITS_PER_WORD); if (stack_parm == 0) { - SET_DECL_ALIGN (parm, MAX (DECL_ALIGN (parm), BITS_PER_WORD)); + HOST_WIDE_INT parm_align + = (STRICT_ALIGNMENT + ? MAX (DECL_ALIGN (parm), BITS_PER_WORD) : DECL_ALIGN (parm)); + + SET_DECL_ALIGN (parm, parm_align); if (DECL_ALIGN (parm) > MAX_SUPPORTED_STACK_ALIGNMENT) { rtx allocsize = gen_int_mode (size_stored, Pmode); |