1/*===---- module.modulemap - intrinsics module map -------------------------===
2 *
3 * Permission is hereby granted, free of charge, to any person obtaining a copy
4 * of this software and associated documentation files (the "Software"), to deal
5 * in the Software without restriction, including without limitation the rights
6 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 * copies of the Software, and to permit persons to whom the Software is
8 * furnished to do so, subject to the following conditions:
9 *
10 * The above copyright notice and this permission notice shall be included in
11 * all copies or substantial portions of the Software.
12 *
13 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 * THE SOFTWARE.
20 *
21 *===-----------------------------------------------------------------------===
22 */
23
24module _Builtin_intrinsics [system] [extern_c] {
25  explicit module altivec {
26    requires altivec
27    header "altivec.h"
28  }
29
30  explicit module arm {
31    requires arm
32
33    explicit module acle {
34      header "arm_acle.h"
35      export *
36    }
37
38    explicit module neon {
39      requires neon
40      header "arm_neon.h"
41      header "arm_fp16.h"
42      export *
43    }
44  }
45
46  explicit module intel {
47    requires x86
48    export *
49
50    header "immintrin.h"
51    textual header "f16cintrin.h"
52    textual header "avxintrin.h"
53    textual header "avx2intrin.h"
54    textual header "avx512fintrin.h"
55    textual header "avx512erintrin.h"
56    textual header "fmaintrin.h"
57
58    header "x86intrin.h"
59    textual header "bmiintrin.h"
60    textual header "bmi2intrin.h"
61    textual header "lzcntintrin.h"
62    textual header "xopintrin.h"
63    textual header "fma4intrin.h"
64    textual header "mwaitxintrin.h"
65    textual header "clzerointrin.h"
66
67    explicit module mm_malloc {
68      requires !freestanding
69      header "mm_malloc.h"
70      export * // note: for <stdlib.h> dependency
71    }
72
73    explicit module cpuid {
74      requires gnuinlineasm
75      header "cpuid.h"
76    }
77
78    explicit module mmx {
79      header "mmintrin.h"
80    }
81
82    explicit module sse {
83      export mm_malloc
84      export mmx
85      export sse2 // note: for hackish <emmintrin.h> dependency
86      header "xmmintrin.h"
87    }
88
89    explicit module sse2 {
90      export sse
91      header "emmintrin.h"
92    }
93
94    explicit module sse3 {
95      export sse2
96      header "pmmintrin.h"
97    }
98
99    explicit module ssse3 {
100      export sse3
101      header "tmmintrin.h"
102    }
103
104    explicit module sse4_1 {
105      export ssse3
106      header "smmintrin.h"
107    }
108
109    explicit module sse4_2 {
110      export sse4_1
111      header "nmmintrin.h"
112    }
113
114    explicit module sse4a {
115      export sse3
116      header "ammintrin.h"
117    }
118
119    explicit module popcnt {
120      header "popcntintrin.h"
121    }
122
123    explicit module mm3dnow {
124      header "mm3dnow.h"
125    }
126
127    explicit module aes_pclmul {
128      header "wmmintrin.h"
129      export aes
130      export pclmul
131    }
132
133    explicit module aes {
134      header "__wmmintrin_aes.h"
135    }
136
137    explicit module pclmul {
138      header "__wmmintrin_pclmul.h"
139    }
140  }
141
142  explicit module systemz {
143    requires systemz
144    export *
145
146    header "s390intrin.h"
147
148    explicit module htm {
149      requires htm
150      header "htmintrin.h"
151      header "htmxlintrin.h"
152    }
153
154    explicit module zvector {
155      requires zvector, vx
156      header "vecintrin.h"
157    }
158  }
159}
160
161module _Builtin_stddef_max_align_t [system] [extern_c] {
162  header "__stddef_max_align_t.h"
163}
164
165module opencl_c {
166  requires opencl
167  header "opencl-c.h"
168}
169