blob: 0f10dd4c08168834f4a5bd6404801077e3efe0e4 [file] [log] [blame]
Yunzhong Gaoc293a262016-04-04 18:46:09 +00001/*===---- 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
Ben Langmuirc67a7742015-01-13 21:54:32 +000024module _Builtin_intrinsics [system] [extern_c] {
Douglas Gregor232e3432012-01-31 21:57:50 +000025 explicit module altivec {
26 requires altivec
27 header "altivec.h"
28 }
29
Douglas Gregor5cad45b2013-05-20 14:07:18 +000030 explicit module arm {
31 requires arm
32
Yi Kongcd081392014-07-23 09:00:21 +000033 explicit module acle {
34 header "arm_acle.h"
35 export *
36 }
37
Douglas Gregor5cad45b2013-05-20 14:07:18 +000038 explicit module neon {
39 requires neon
40 header "arm_neon.h"
Abderrazek Zaafranice8746d2018-01-19 23:11:18 +000041 header "arm_fp16.h"
Douglas Gregor5cad45b2013-05-20 14:07:18 +000042 export *
43 }
44 }
45
Douglas Gregor0070c0b2012-01-30 06:38:25 +000046 explicit module intel {
47 requires x86
Douglas Gregor3ec66632012-02-02 18:42:48 +000048 export *
Douglas Gregor0070c0b2012-01-30 06:38:25 +000049
50 header "immintrin.h"
Richard Smith20d47012016-04-16 00:46:26 +000051 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
Douglas Gregor0070c0b2012-01-30 06:38:25 +000058 header "x86intrin.h"
Richard Smith20d47012016-04-16 00:46:26 +000059 textual header "bmiintrin.h"
60 textual header "bmi2intrin.h"
61 textual header "lzcntintrin.h"
62 textual header "xopintrin.h"
63 textual header "fma4intrin.h"
Richard Smithf5c3a632016-05-20 01:06:47 +000064 textual header "mwaitxintrin.h"
Craig Topper45742262017-02-09 06:10:14 +000065 textual header "clzerointrin.h"
Craig Topper5f1d10e2018-04-24 17:40:49 +000066 textual header "wbnoinvdintrin.h"
67 textual header "cldemoteintrin.h"
68 textual header "waitpkgintrin.h"
Gabor Buellaa51e0c22018-05-01 10:05:42 +000069 textual header "movdirintrin.h"
Gabor Buellab0f310d2018-05-08 06:49:41 +000070 textual header "pconfigintrin.h"
Gabor Buella5e52fa92018-05-08 07:12:34 +000071 textual header "sgxintrin.h"
Gabor Buella3a757122018-05-10 07:28:54 +000072 textual header "ptwriteintrin.h"
Douglas Gregor0070c0b2012-01-30 06:38:25 +000073
Douglas Gregor3ec66632012-02-02 18:42:48 +000074 explicit module mm_malloc {
Elad Cohenfb6358d2016-09-04 06:00:42 +000075 requires !freestanding
Douglas Gregor3ec66632012-02-02 18:42:48 +000076 header "mm_malloc.h"
77 export * // note: for <stdlib.h> dependency
78 }
79
Douglas Gregor0070c0b2012-01-30 06:38:25 +000080 explicit module cpuid {
Bruno Cardoso Lopes6736e192016-08-30 21:25:42 +000081 requires gnuinlineasm
Douglas Gregor0070c0b2012-01-30 06:38:25 +000082 header "cpuid.h"
83 }
84
85 explicit module mmx {
Douglas Gregor0070c0b2012-01-30 06:38:25 +000086 header "mmintrin.h"
87 }
88
89 explicit module sse {
John Thompsondebce242016-03-22 20:57:51 +000090 export mm_malloc
Douglas Gregor0070c0b2012-01-30 06:38:25 +000091 export mmx
Richard Smith23d8d032015-05-14 00:45:20 +000092 export sse2 // note: for hackish <emmintrin.h> dependency
Douglas Gregor0070c0b2012-01-30 06:38:25 +000093 header "xmmintrin.h"
94 }
95
96 explicit module sse2 {
Douglas Gregor0070c0b2012-01-30 06:38:25 +000097 export sse
98 header "emmintrin.h"
99 }
100
101 explicit module sse3 {
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000102 export sse2
103 header "pmmintrin.h"
104 }
105
106 explicit module ssse3 {
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000107 export sse3
108 header "tmmintrin.h"
109 }
110
111 explicit module sse4_1 {
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000112 export ssse3
113 header "smmintrin.h"
114 }
115
116 explicit module sse4_2 {
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000117 export sse4_1
118 header "nmmintrin.h"
119 }
120
Douglas Gregor4c698592012-11-05 20:11:10 +0000121 explicit module sse4a {
Douglas Gregor4c698592012-11-05 20:11:10 +0000122 export sse3
Douglas Gregor10b4f2a2012-11-05 20:41:30 +0000123 header "ammintrin.h"
Douglas Gregor4c698592012-11-05 20:11:10 +0000124 }
125
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000126 explicit module popcnt {
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000127 header "popcntintrin.h"
128 }
129
130 explicit module mm3dnow {
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000131 header "mm3dnow.h"
132 }
Douglas Gregor4c698592012-11-05 20:11:10 +0000133
Douglas Gregordc779ab2012-11-05 23:30:26 +0000134 explicit module aes_pclmul {
Douglas Gregordc779ab2012-11-05 23:30:26 +0000135 header "wmmintrin.h"
John Thompsonb7892ff2015-05-27 18:26:41 +0000136 export aes
137 export pclmul
Douglas Gregordc779ab2012-11-05 23:30:26 +0000138 }
139
140 explicit module aes {
Douglas Gregordc779ab2012-11-05 23:30:26 +0000141 header "__wmmintrin_aes.h"
142 }
143
144 explicit module pclmul {
Douglas Gregordc779ab2012-11-05 23:30:26 +0000145 header "__wmmintrin_pclmul.h"
146 }
Douglas Gregor0070c0b2012-01-30 06:38:25 +0000147 }
Ulrich Weigandcc673442015-04-01 14:15:35 +0000148
149 explicit module systemz {
150 requires systemz
151 export *
152
153 header "s390intrin.h"
154
155 explicit module htm {
156 requires htm
157 header "htmintrin.h"
158 header "htmxlintrin.h"
159 }
Ulrich Weigandca256432015-07-30 14:10:43 +0000160
161 explicit module zvector {
162 requires zvector, vx
163 header "vecintrin.h"
164 }
Ulrich Weigandcc673442015-04-01 14:15:35 +0000165 }
Douglas Gregor3f09de62012-01-29 20:52:14 +0000166}
Richard Smithef99e4d2014-10-03 00:31:35 +0000167
168module _Builtin_stddef_max_align_t [system] [extern_c] {
169 header "__stddef_max_align_t.h"
170}
Yaxun Liu143f0832016-06-20 19:26:00 +0000171
172module opencl_c {
173 requires opencl
174 header "opencl-c.h"
175}