This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug middle-end/47397] Alignment of array element is not optimal in AVX mode due to use of TARGET_MEM_REFs
- From: "rguenth at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 21 Jan 2011 14:21:48 +0000
- Subject: [Bug middle-end/47397] Alignment of array element is not optimal in AVX mode due to use of TARGET_MEM_REFs
- Auto-submitted: auto-generated
- References: <bug-47397-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47397
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2011.01.21 14:21:20
Summary|Alignment of array element |Alignment of array element
|is incorrect in AVX mode |is not optimal in AVX mode
| |due to use of
| |TARGET_MEM_REFs
Ever Confirmed|0 |1
--- Comment #4 from Richard Guenther <rguenth at gcc dot gnu.org> 2011-01-21 14:21:20 UTC ---
This is because index is unknown in both
vect_var_.13_20 = MEM[symbol: a, index: ivtmp.24_12, offset: 16B];
and
MEM[symbol: b, index: ivtmp.24_12, offset: 0B] = vect_var_.14_22;
we don't have a way to record that ivtmp.24_12 is {0, +, 32} for
RTL expansion. Which means that IVOPTs is responsible for the
loss of information. Before IVOPTs we have
# ALIGN = 32, MISALIGN = 16
# vect_pa.9_18 = PHI <vect_pa.9_19(4), vect_pa.12_17(2)>
# ALIGN = 32, MISALIGN = 0
# vect_pb.16_24 = PHI <vect_pb.16_25(4), vect_pb.19_23(2)>
vect_var_.13_20 = MEM[(double[1024] *)vect_pa.9_18];
MEM[(double[1024] *)vect_pb.16_24] = vect_var_.14_22;
so we know that the pointers we dereference are properly aligned.