The following patch changes the x86 intrinsic compat headers to use #error instead of #warning. We do this for two reasons. Firstly, we want the user to really be sure they want/need to use the x86 intrinsic compat support before doing so, because a warning is too easy to ignore. Secondly, we don't want configure time tests that check for whether x86 intrinsic support exists and then use them if they do, to automatically enable usage of them. The x86 intrinsic compat support should only be used when there is no other option to the user (ie, no generic or ppc specific code exists).
Is this ok for trunk? Peter * config/rs6000/x86intrin.h: Change #warning to #error. Update message. * config/rs6000/emmintrin.h: Likewise. * config/rs6000/mmintrin.h: Likewise. * config/rs6000/xmmintrin.h: Likewise. Index: gcc/config/rs6000/x86intrin.h =================================================================== --- gcc/config/rs6000/x86intrin.h (revision 256351) +++ gcc/config/rs6000/x86intrin.h (working copy) @@ -29,7 +29,7 @@ Note that much code that uses Intel intrinsics can be rewritten in standard C or GNU C extensions, which are more portable and better optimized across multiple targets. */ -#warning "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this warning." +#error "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this error." #endif #ifndef _X86INTRIN_H_INCLUDED Index: gcc/config/rs6000/emmintrin.h =================================================================== --- gcc/config/rs6000/emmintrin.h (revision 256351) +++ gcc/config/rs6000/emmintrin.h (working copy) @@ -53,7 +53,7 @@ the PowerISA FPSCR / VSCR registers. We recommend applications replace direct access to the MXSCR with the more portable <fenv.h> Posix APIs. */ -#warning "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this warning." +#error "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this error." #endif #ifndef EMMINTRIN_H_ Index: gcc/config/rs6000/mmintrin.h =================================================================== --- gcc/config/rs6000/mmintrin.h (revision 256351) +++ gcc/config/rs6000/mmintrin.h (working copy) @@ -49,7 +49,7 @@ C language 64-bit scalar operation or optimized to use the newer 128-bit SSE/Altivec operations. We recomend this for new applications. */ -#warning "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this warning." +#error "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this error." #endif #ifndef _MMINTRIN_H_INCLUDED Index: gcc/config/rs6000/xmmintrin.h =================================================================== --- gcc/config/rs6000/xmmintrin.h (revision 256351) +++ gcc/config/rs6000/xmmintrin.h (working copy) @@ -51,7 +51,7 @@ the PowerISA FPSCR / VSCR registers. We recommend applications replace direct access to the MXSCR with the more portable <fenv.h> Posix APIs. */ -#warning "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this warning." +#error "Please read comment above. Use -DNO_WARN_X86_INTRINSICS to disable this error." #endif #ifndef _XMMINTRIN_H_INCLUDED