This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/47272] GCC can't bootstrap on powerpc64-linx using --with-cpu=power7
- From: "meissner at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 20 Jan 2011 20:58:03 +0000
- Subject: [Bug target/47272] GCC can't bootstrap on powerpc64-linx using --with-cpu=power7
- Auto-submitted: auto-generated
- References: <bug-47272-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47272
--- Comment #2 from Michael Meissner <meissner at gcc dot gnu.org> 2011-01-20 20:57:54 UTC ---
Created attachment 23052
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=23052
Preliminary patch to allow --with-cpu=power7 to work
The root problem is under VSX, the vec_ld/vec_st builtins use VSX memory
instructions which have different semantics than Altivec when the memory is not
aligned. The Altivec speedup in libcpp/lex.c specifically knows about the
Altivec behaviour and accesses the wrong memory location if the compiler is
built with VSX instructions.
This patch changes vec_ld/vec_st to go back to using Altivec instructions. It
also adds vector double/vector long long support to the Altivec builtin whole
vector memory operations. However, in doing so, it may affect users who have
been using GCC 4.5 for VSX that expects to use VSX instructions. I anticipate
this is not the final patch for the problem.