diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2017-06-29 19:21:25 +0000 |
---|---|---|
committer | Eric Botcazou <ebotcazou@gcc.gnu.org> | 2017-06-29 19:21:25 +0000 |
commit | 3ba358bf20a292e277df4de02b2f57c203e627cc (patch) | |
tree | 55e1d6b786135609443047541d2d9148636913b0 /gcc/expr.c | |
parent | 74582a3e2e01068437410fb75f2f9282ee4923e3 (diff) | |
download | gcc-3ba358bf20a292e277df4de02b2f57c203e627cc.zip gcc-3ba358bf20a292e277df4de02b2f57c203e627cc.tar.gz gcc-3ba358bf20a292e277df4de02b2f57c203e627cc.tar.bz2 |
expr.c (expand_expr): When testing for unaligned objects...
* expr.c (expand_expr) <normal_inner_ref>: When testing for unaligned
objects, take into account only the alignment of 'op0' and 'mode1' if
'op0' is a MEM.
From-SVN: r249811
Diffstat (limited to 'gcc/expr.c')
-rw-r--r-- | gcc/expr.c | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -10639,11 +10639,11 @@ expand_expr_real_1 (tree exp, rtx target, machine_mode tmode, /* If the field isn't aligned enough to fetch as a memref, fetch it as a bit field. */ || (mode1 != BLKmode - && (((TYPE_ALIGN (TREE_TYPE (tem)) < GET_MODE_ALIGNMENT (mode) - || (bitpos % GET_MODE_ALIGNMENT (mode) != 0) - || (MEM_P (op0) - && (MEM_ALIGN (op0) < GET_MODE_ALIGNMENT (mode1) - || (bitpos % GET_MODE_ALIGNMENT (mode1) != 0)))) + && (((MEM_P (op0) + ? MEM_ALIGN (op0) < GET_MODE_ALIGNMENT (mode1) + || (bitpos % GET_MODE_ALIGNMENT (mode1) != 0) + : TYPE_ALIGN (TREE_TYPE (tem)) < GET_MODE_ALIGNMENT (mode) + || (bitpos % GET_MODE_ALIGNMENT (mode) != 0)) && modifier != EXPAND_MEMORY && ((modifier == EXPAND_CONST_ADDRESS || modifier == EXPAND_INITIALIZER) |