This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Implicit altivec vs. linux kernel build
- From: Benjamin Herrenschmidt <benh at kernel dot crashing dot org>
- To: Andrew Pinski <pinskia at physics dot uc dot edu>
- Cc: gcc at gcc dot gnu dot org, Paul Mackerras <paulus at samba dot org>, Alan Modra <amodra at bigpond dot net dot au>
- Date: Mon, 28 Feb 2005 09:49:33 +1100
- Subject: Re: Implicit altivec vs. linux kernel build
- References: <1109544228.15026.225.camel@gaston> <d447655c007dfef84af4e1404ad5d163@physics.uc.edu>
On Sun, 2005-02-27 at 17:47 -0500, Andrew Pinski wrote:
> s the proper way or set of options for me to:
> >
> > 1) optionally have POWER4 optimisations (that must be independant on
> > the rest below)
> > 2) be able to use altivec instructions in assembly
> > 3) be able to use altivec in a few selected bits of C code
> > 4) never have altivec code implicitely generated by the compiler
>
> Use -mcpu=970 -mno-altivec this will cause not altivec instructions to
> be created. -mcpu=970 implies you are compiling for 970 and want the
> best code produced.
Ok, but, will the above allow me to explicitely use altivec instructions
in the RAID6 code and the assembly ?
Also, if I have CONIFG_POWER4 not enabled (which mean I need code that
will work on POWER3 for example), what should I use so can I still use
altivec instructions in the RAID6 code and assembly ?
The problem is that when CONFIG_POWER4 is not set, the kernel should
still boot any machine. When CONFIG_POWER4 is set, it's just an
optimisation to generate code for POWER4 and later only, but it should
have no impact on the kind of code I am _able_ to generate in selected
places.
Ben.