r266501 - [modules] Don't expose *intrin.h headers that cannot be included standalone as

Richard Smith via cfe-commits cfe-commits at lists.llvm.org
Fri Apr 15 17:46:27 PDT 2016


Author: rsmith
Date: Fri Apr 15 19:46:26 2016
New Revision: 266501

URL: http://llvm.org/viewvc/llvm-project?rev=266501&view=rev
Log:
[modules] Don't expose *intrin.h headers that cannot be included standalone as
separate modules. These cause build breakage with -fmodules-local-submodule-visibility.

Modified:
    cfe/trunk/lib/Headers/module.modulemap
    cfe/trunk/test/Headers/cxx11.cpp

Modified: cfe/trunk/lib/Headers/module.modulemap
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Headers/module.modulemap?rev=266501&r1=266500&r2=266501&view=diff
==============================================================================
--- cfe/trunk/lib/Headers/module.modulemap (original)
+++ cfe/trunk/lib/Headers/module.modulemap Fri Apr 15 19:46:26 2016
@@ -47,7 +47,19 @@ module _Builtin_intrinsics [system] [ext
     export *
 
     header "immintrin.h"
+    textual header "f16cintrin.h"
+    textual header "avxintrin.h"
+    textual header "avx2intrin.h"
+    textual header "avx512fintrin.h"
+    textual header "avx512erintrin.h"
+    textual header "fmaintrin.h"
+
     header "x86intrin.h"
+    textual header "bmiintrin.h"
+    textual header "bmi2intrin.h"
+    textual header "lzcntintrin.h"
+    textual header "xopintrin.h"
+    textual header "fma4intrin.h"
 
     explicit module mm_malloc {
       header "mm_malloc.h"
@@ -62,10 +74,6 @@ module _Builtin_intrinsics [system] [ext
       header "mmintrin.h"
     }
 
-    explicit module f16c {
-      header "f16cintrin.h"
-    }
-
     explicit module sse {
       export mm_malloc
       export mmx
@@ -103,46 +111,6 @@ module _Builtin_intrinsics [system] [ext
       header "ammintrin.h"
     }
 
-    explicit module avx {
-      export sse4_2
-      header "avxintrin.h"
-    }
-
-    explicit module avx2 {
-      export avx
-      header "avx2intrin.h"
-    }
-
-    explicit module avx512f {
-      export avx2
-      header "avx512fintrin.h"
-    }
-
-    explicit module avx512er {
-      header "avx512erintrin.h"
-    }
-
-    explicit module bmi {
-      header "bmiintrin.h"
-    }
-
-    explicit module bmi2 {
-      header "bmi2intrin.h"
-    }
-
-    explicit module fma {
-      header "fmaintrin.h"
-    }
-
-    explicit module fma4 {
-      export sse3
-      header "fma4intrin.h"
-    }
-
-    explicit module lzcnt {
-      header "lzcntintrin.h"
-    }
-
     explicit module popcnt {
       header "popcntintrin.h"
     }
@@ -151,11 +119,6 @@ module _Builtin_intrinsics [system] [ext
       header "mm3dnow.h"
     }
 
-    explicit module xop {
-      export fma4
-      header "xopintrin.h"
-    }
-
     explicit module aes_pclmul {
       header "wmmintrin.h"
       export aes

Modified: cfe/trunk/test/Headers/cxx11.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Headers/cxx11.cpp?rev=266501&r1=266500&r2=266501&view=diff
==============================================================================
--- cfe/trunk/test/Headers/cxx11.cpp (original)
+++ cfe/trunk/test/Headers/cxx11.cpp Fri Apr 15 19:46:26 2016
@@ -1,6 +1,7 @@
 // RUN: rm -rf %t
 // RUN: %clang_cc1 -ffreestanding -fsyntax-only -std=c++11 %s
 // RUN: %clang_cc1 -ffreestanding -fsyntax-only -std=c++11 -fmodules -fmodules-cache-path=%t %s
+// RUN: %clang_cc1 -ffreestanding -fsyntax-only -std=c++11 -fmodules -fmodules-cache-path=%t -fmodules-local-submodule-visibility %s
 
 // This test fails on systems with older OS X 10.9 SDK headers, see PR18322.
 




More information about the cfe-commits mailing list