This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/55614] [4.6/4.7 Regression] vector extensions cause movdqa to be generated for memcpy on unaligned buffer
- From: "ebotcazou at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 07 Dec 2012 15:40:08 +0000
- Subject: [Bug tree-optimization/55614] [4.6/4.7 Regression] vector extensions cause movdqa to be generated for memcpy on unaligned buffer
- Auto-submitted: auto-generated
- References: <bug-55614-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55614
--- Comment #7 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-12-07 15:40:08 UTC ---
> That is what the memcpy folding folds it to. We could perhaps stop for 4.6/4.7
> doing such replacements in memcpy folding if it would try to decrease alignment
> of some aggregate, but then we risk regressing generated code quality.
It's the build_aligned_type paths in fold_builtin_memory_op, right? No wonder
you get problems by breaking such a fundamental invariant as the type
alignment.
I guess you can kludge in SRA and disable the COMPONENT_REF thing if the
platform isn't STRICT_ALIGNMENT.