commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] [gnuradio] 04/11: volk: clang sets GNUC_MINOR only to


From: git
Subject: [Commit-gnuradio] [gnuradio] 04/11: volk: clang sets GNUC_MINOR only to 2, so we need to check if we're building with clang. This patch enables xgetbv for clang >= 3.0.
Date: Thu, 9 Jan 2014 21:52:39 +0000 (UTC)

This is an automated email from the git hooks/post-receive script.

trondeau pushed a commit to branch maint
in repository gnuradio.

commit 3d84c6fd4907b1f6a6770956a3e0c5a663e65175
Author: Steve Markgraf <address@hidden>
Date:   Sat Dec 28 12:01:56 2013 -0500

    volk: clang sets GNUC_MINOR only to 2, so we need to check if we're 
building with clang. This patch enables xgetbv for clang >= 3.0.
---
 volk/tmpl/volk_cpu.tmpl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/volk/tmpl/volk_cpu.tmpl.c b/volk/tmpl/volk_cpu.tmpl.c
index a7a5093..f6df4d1 100644
--- a/volk/tmpl/volk_cpu.tmpl.c
+++ b/volk/tmpl/volk_cpu.tmpl.c
@@ -44,7 +44,7 @@ struct VOLK_CPU volk_cpu;
      * This function will bomb on non-AVX-capable machines, so
      * check for AVX capability before executing.
      */
-    #if (__GNUC__ > 4 || __GNUC__ == 4 && __GNUC_MINOR__ >= 4) && 
defined(HAVE_XGETBV)
+    #if ((__GNUC__ > 4 || __GNUC__ == 4 && __GNUC_MINOR__ >= 2) || 
(__clang_major__ >= 3)) && defined(HAVE_XGETBV)
     static inline unsigned long long _xgetbv(unsigned int index){
         unsigned int eax, edx;
         __asm__ __volatile__("xgetbv" : "=a"(eax), "=d"(edx) : "c"(index));



reply via email to

[Prev in Thread] Current Thread [Next in Thread]