This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/42652] vectorizer created unaligned vector insns
- From: "law at redhat dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 14 Jan 2010 17:29:48 -0000
- Subject: [Bug tree-optimization/42652] vectorizer created unaligned vector insns
- References: <bug-42652-391@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #11 from law at redhat dot com 2010-01-14 17:29 -------
Subject: Re: vectorizer created unaligned vector
insns
On 01/13/10 02:35, irar at il dot ibm dot com wrote:
> ------- Comment #10 from irar at il dot ibm dot com 2010-01-13 09:35 -------
> Yes, I understand that we can't assume that an access is aligned if we can't
> prove it's aligned. I don't understand how we can prove that a COMPONENT_REF is
> aligned, i.e., if there is a way to check if a struct is packed, or we'd better
> decide that we always use versioning for COMPONENT_REFs?
>
Given a raw COMPONENT_REF I don't think you can prove proper alignment.
You have to look at the entire effective address computation.
Unfortunately, I think this has rather significant implications on how
often we can vectorize without needing to perform the runtime check for
alignment.
Jeff
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42652