summaryrefslogtreecommitdiff
path: root/gcc/emit-rtl.c
diff options
context:
space:
mode:
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2010-08-25 10:03:19 +0000
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>2010-08-25 10:03:19 +0000
commit559c9389f9e707f42e9b883eff93c11e50105369 (patch)
treeb8cfc730f4a1e716803f11de698d3e20898c13e2 /gcc/emit-rtl.c
parentb2d33090f5c98fd727c577903a82869b8658d8b9 (diff)
downloadgcc-559c9389f9e707f42e9b883eff93c11e50105369.tar.gz
2010-08-25 Richard Guenther <rguenther@suse.de>
PR middle-end/45379 * emit-rtl.c (set_mem_attributes_minus_bitpos): Handle TARGET_MEM_REF in alignment computation. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@163540 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r--gcc/emit-rtl.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index 9f96abf76d2..2993c93874f 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -1615,6 +1615,11 @@ set_mem_attributes_minus_bitpos (rtx ref, tree t, int objectp,
align = MAX (align, TYPE_ALIGN (type));
}
+ else if (TREE_CODE (t) == TARGET_MEM_REF)
+ /* ??? This isn't fully correct, we can't set the alignment from the
+ type in all cases. */
+ align = MAX (align, TYPE_ALIGN (type));
+
else if (TREE_CODE (t) == MISALIGNED_INDIRECT_REF)
{
if (integer_zerop (TREE_OPERAND (t, 1)))