[PATCH] Set cpu type explicitly, take 2
benh at kernel.crashing.org
Sat May 21 08:27:32 EST 2005
On Fri, 2005-05-20 at 10:30 -0400, Dan Malek wrote:
> On May 20, 2005, at 3:45 AM, Benjamin Herrenschmidt wrote:
> > The problem is the same as ppc64 isn't it ?, -maltivec doesn't work
> > with
> > -mcpu=power4 on gcc 3.4 does it ? That would mean no RAID6...
> I don't understand "doesn't work." Does power4 imply altivec?
> Do we need to add -maltivec based on the configuration option?
No, -mcpu=970 is equivalent in a way to -mcpu=power4 and -maltivec,
howevever, there is a bug in gcc 3.4 which makes -maltivec cause an
error if you have -mcpu=power4. The RAID6 code needs -maltivec. So on
gcc 3.4, we need to use -mcpu=970 instead of -mcpu=power4. However, we
must _NOT_ do that on gcc-4.0 as that causes it to implicitely generate
altivec code all over the place. (Fortunately, the bug is also fixed
there, so with gcc-4.0, we just need -mcpu=power4 and -maltivec only on
the RAID6 code)
Messy ? Yeah !
More information about the Linuxppc-dev