From: bugzilla-daemon-CC+yJ3UmIYqDUpFQwHEjaQ@public.gmane.org Subject: [Bug 93454] Can't build with LLVM/clang 3.7.0 - SSSE3 instruction set not enabled Date: Sun, 20 Dec 2015 10:37:50 +0000 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1659807435==" Return-path: In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: nouveau-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org Sender: "Nouveau" To: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org List-Id: nouveau.vger.kernel.org --===============1659807435== Content-Type: multipart/alternative; boundary="1450607870.fDfBb1.23402"; charset="UTF-8" --1450607870.fDfBb1.23402 Date: Sun, 20 Dec 2015 10:37:50 +0000 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" https://bugs.freedesktop.org/show_bug.cgi?id=93454 --- Comment #6 from Jose Fonseca --- The issue is simple: - GCC used to require -msse3 in order to include tmmintrin.h - MSVC/ICC does not - GCC 4.9 finally eliminated that awkward requirement -- it's now possible to use SSE3 instrinsics without giving GCC carte blanch to emit SSSE3 whenever it wants - it appears Clang claims to be GCC 4.9 but does not in fact support this. We can workaround by adding diff --git a/src/gallium/include/pipe/p_config.h b/src/gallium/include/pipe/p_config.h index 0b570c7..7d5d7d4 100644 --- a/src/gallium/include/pipe/p_config.h +++ b/src/gallium/include/pipe/p_config.h @@ -96,7 +96,7 @@ #else #define PIPE_ARCH_SSE #endif -#if defined(PIPE_CC_GCC) && (__GNUC__ * 100 + __GNUC_MINOR__) < 409 && !defined(__SSSE3__) +#if defined(PIPE_CC_GCC) && ((__GNUC__ * 100 + __GNUC_MINOR__) < 409 || defined(__clang__)) && !defined(__SSSE3__) /* #warning SSE3 support requires -msse3 compiler options before GCC 4.9 */ #else #define PIPE_ARCH_SSSE3 But this is above all a bug in Clang 3.7. If that strive/claim to be GCC 4.9 then they should handle this too. -- You are receiving this mail because: You are the QA Contact for the bug. You are the assignee for the bug. --1450607870.fDfBb1.23402 Date: Sun, 20 Dec 2015 10:37:50 +0000 MIME-Version: 1.0 Content-Type: text/html; charset="UTF-8"

Comment # 6 on bug 93454 from
The issue is simple:

- GCC used to require -msse3 in order to include tmmintrin.h 
- MSVC/ICC does not
- GCC 4.9 finally eliminated that awkward requirement -- it's now possible to
use SSE3 instrinsics without giving GCC carte blanch to emit SSSE3 whenever it
wants

- it appears Clang claims to be GCC 4.9 but does not in fact support this.


We can workaround by adding   

diff --git a/src/gallium/include/pipe/p_config.h
b/src/gallium/include/pipe/p_config.h
index 0b570c7..7d5d7d4 100644
--- a/src/gallium/include/pipe/p_config.h
+++ b/src/gallium/include/pipe/p_config.h
@@ -96,7 +96,7 @@
 #else
 #define PIPE_ARCH_SSE
 #endif
-#if defined(PIPE_CC_GCC) && (__GNUC__ * 100 + __GNUC_MINOR__) < 409 &&
!defined(__SSSE3__)
+#if defined(PIPE_CC_GCC) && ((__GNUC__ * 100 + __GNUC_MINOR__) < 409 ||
defined(__clang__)) && !defined(__SSSE3__)
 /* #warning SSE3 support requires -msse3 compiler options before GCC 4.9 */
 #else
 #define PIPE_ARCH_SSSE3


But this is above all a bug in Clang 3.7.  If that strive/claim to be GCC 4.9
then they should handle this too.


You are receiving this mail because:
  • You are the QA Contact for the bug.
  • You are the assignee for the bug.
--1450607870.fDfBb1.23402-- --===============1659807435== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KTm91dmVhdSBt YWlsaW5nIGxpc3QKTm91dmVhdUBsaXN0cy5mcmVlZGVza3RvcC5vcmcKaHR0cDovL2xpc3RzLmZy ZWVkZXNrdG9wLm9yZy9tYWlsbWFuL2xpc3RpbmZvL25vdXZlYXUK --===============1659807435==--