>accepting -march=iwmmxt on x86 is a bug in GCC<br><br>"-march" just tells gcc for what processor it has to generate the code. It does not matter what processor the computer actually has. I mean, it's ok to compile code for ARM on x86 computer, or the other way around.<br>
<br><br><div class="gmail_quote">On Thu, Oct 6, 2011 at 2:15 PM, Søren Sandmann <span dir="ltr"><<a href="mailto:sandmann@cs.au.dk" target="_blank">sandmann@cs.au.dk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div>Matt Turner <<a href="mailto:mattst88@gmail.com" target="_blank">mattst88@gmail.com</a>> writes:<br>
<br>
> I'm not able to reproduce it, but I have two reports that iwMMXt is<br>
> incorrectly detected on x86 and amd64. This happens because it uses the<br>
> standard _mm_* intrinsic functions. It should fail on x86 and amd64<br>
> because configure will use -march=iwmmxt to compile the test, which<br>
> isn't a valid option on these platforms.<br>
><br>
> So, just #error out in the test if the __arm__ preprocessor directive<br>
> isn't defined.<br>
<br>
</div>Looks good to me, though presumably accepting -march=iwmmxt on x86 is a<br>
bug in GCC. Also, looking at this again, isn't there a typo in the<br>
compiler check:<br>
<div><br>
#if defined(__GNUC__) && (__GNUC__ < 4 || (__GNUC__ == 3 && __GNUC_MINOR__ < 6))<br>
#error "Need GCC >= 4.6 for IWMMXT intrinsics"<br>
#endif<br>
<br>
</div>where __GNUC__ == 3 should be __GNUC__ == 4?<br>
<br>
<br>
Soren<br>
<div><br>
> Fixes <a href="https://bugs.gentoo.org/show_bug.cgi?id=385179" target="_blank">https://bugs.gentoo.org/show_bug.cgi?id=385179</a><br>
><br>
> Signed-off-by: Matt Turner <<a href="mailto:mattst88@gmail.com" target="_blank">mattst88@gmail.com</a>><br>
> ---<br>
> <a href="http://configure.ac" target="_blank">configure.ac</a> | 3 +++<br>
> 1 files changed, 3 insertions(+), 0 deletions(-)<br>
><br>
> diff --git a/<a href="http://configure.ac" target="_blank">configure.ac</a> b/<a href="http://configure.ac" target="_blank">configure.ac</a><br>
> index 481d0bb..471a127 100644<br>
> --- a/<a href="http://configure.ac" target="_blank">configure.ac</a><br>
> +++ b/<a href="http://configure.ac" target="_blank">configure.ac</a><br>
> @@ -552,6 +552,9 @@ AC_MSG_CHECKING(whether to use ARM IWMMXT intrinsics)<br>
> xserver_save_CFLAGS=$CFLAGS<br>
> CFLAGS="$IWMMXT_CFLAGS $CFLAGS"<br>
> AC_COMPILE_IFELSE([<br>
> +#ifndef __arm__<br>
> +#error "IWMMXT is only available on ARM"<br>
> +#endif<br>
> #if defined(__GNUC__) && (__GNUC__ < 4 || (__GNUC__ == 3 && __GNUC_MINOR__ < 6))<br>
> #error "Need GCC >= 4.6 for IWMMXT intrinsics"<br>
> #endif<br>
</div>_______________________________________________<br>
Pixman mailing list<br>
<a href="mailto:Pixman@lists.freedesktop.org" target="_blank">Pixman@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/pixman" target="_blank">http://lists.freedesktop.org/mailman/listinfo/pixman</a><br>
</blockquote></div><br>