This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Implicit altivec vs. linux kernel build


>>>>> Benjamin Herrenschmidt writes:

Ben> The only problem I see is that the day we have a CPU, let's call it
Ben> POWER8 for the sake of this demonstration, that has altivec and is
Ben> different enough to justify a specific "optimize" option, we'll have to
Ben> use -mcpu=POWER8 -mno-altivec for the whole kernel, which makes it
Ben> difficult to enable altivec only for the raid6 file since the kenrel
Ben> makefiles, afaik, can only add an option to a specific file. Unless
Ben> -mcpu=POWER8 -mno-altivec -maltivec is legal ...

	It depends why you are using -mcpu=power8.  If one wants to
generate common PowerPC code tuned for POWER8, one could use
-mtune=power8.  If one specifically wants to generate POWER4, POWER5, etc.
base architecture instructions, GCC probably should add a PowerPC/AS
generic cpu type to match the existing "powerpc" and "powerpc64" types so
that one could enable the instructions common to the architecture and tune
for the latest processor without enabling processor-specific features.

David


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]