Ben Langmuir | c67a774 | 2015-01-13 21:54:32 +0000 | [diff] [blame] | 1 | module _Builtin_intrinsics [system] [extern_c] { |
Douglas Gregor | 232e343 | 2012-01-31 21:57:50 +0000 | [diff] [blame] | 2 | explicit module altivec { |
3 | requires altivec | ||||
4 | header "altivec.h" | ||||
5 | } | ||||
6 | |||||
Douglas Gregor | 5cad45b | 2013-05-20 14:07:18 +0000 | [diff] [blame] | 7 | explicit module arm { |
8 | requires arm | ||||
9 | |||||
Yi Kong | cd08139 | 2014-07-23 09:00:21 +0000 | [diff] [blame] | 10 | explicit module acle { |
11 | header "arm_acle.h" | ||||
12 | export * | ||||
13 | } | ||||
14 | |||||
Douglas Gregor | 5cad45b | 2013-05-20 14:07:18 +0000 | [diff] [blame] | 15 | explicit module neon { |
16 | requires neon | ||||
17 | header "arm_neon.h" | ||||
18 | export * | ||||
19 | } | ||||
20 | } | ||||
21 | |||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 22 | explicit module intel { |
23 | requires x86 | ||||
Douglas Gregor | 3ec6663 | 2012-02-02 18:42:48 +0000 | [diff] [blame] | 24 | export * |
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 25 | |
26 | header "immintrin.h" | ||||
27 | header "x86intrin.h" | ||||
28 | |||||
Douglas Gregor | 3ec6663 | 2012-02-02 18:42:48 +0000 | [diff] [blame] | 29 | explicit module mm_malloc { |
30 | header "mm_malloc.h" | ||||
31 | export * // note: for <stdlib.h> dependency | ||||
32 | } | ||||
33 | |||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 34 | explicit module cpuid { |
35 | header "cpuid.h" | ||||
36 | } | ||||
37 | |||||
38 | explicit module mmx { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 39 | header "mmintrin.h" |
40 | } | ||||
41 | |||||
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 42 | explicit module f16c { |
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 43 | header "f16cintrin.h" |
44 | } | ||||
45 | |||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 46 | explicit module sse { |
John Thompson | debce24 | 2016-03-22 20:57:51 +0000 | [diff] [blame] | 47 | export mm_malloc |
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 48 | export mmx |
Richard Smith | 23d8d03 | 2015-05-14 00:45:20 +0000 | [diff] [blame] | 49 | export sse2 // note: for hackish <emmintrin.h> dependency |
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 50 | header "xmmintrin.h" |
51 | } | ||||
52 | |||||
53 | explicit module sse2 { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 54 | export sse |
55 | header "emmintrin.h" | ||||
56 | } | ||||
57 | |||||
58 | explicit module sse3 { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 59 | export sse2 |
60 | header "pmmintrin.h" | ||||
61 | } | ||||
62 | |||||
63 | explicit module ssse3 { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 64 | export sse3 |
65 | header "tmmintrin.h" | ||||
66 | } | ||||
67 | |||||
68 | explicit module sse4_1 { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 69 | export ssse3 |
70 | header "smmintrin.h" | ||||
71 | } | ||||
72 | |||||
73 | explicit module sse4_2 { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 74 | export sse4_1 |
75 | header "nmmintrin.h" | ||||
76 | } | ||||
77 | |||||
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 78 | explicit module sse4a { |
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 79 | export sse3 |
Douglas Gregor | 10b4f2a | 2012-11-05 20:41:30 +0000 | [diff] [blame] | 80 | header "ammintrin.h" |
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 81 | } |
82 | |||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 83 | explicit module avx { |
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 84 | export sse4_2 |
85 | header "avxintrin.h" | ||||
86 | } | ||||
87 | |||||
88 | explicit module avx2 { | ||||
Douglas Gregor | 71022ca | 2012-01-30 18:49:05 +0000 | [diff] [blame] | 89 | export avx |
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 90 | header "avx2intrin.h" |
91 | } | ||||
92 | |||||
Elena Demikhovsky | bd1a49b | 2014-07-22 12:08:25 +0000 | [diff] [blame] | 93 | explicit module avx512f { |
Elena Demikhovsky | bd1a49b | 2014-07-22 12:08:25 +0000 | [diff] [blame] | 94 | export avx2 |
95 | header "avx512fintrin.h" | ||||
96 | } | ||||
97 | |||||
98 | explicit module avx512er { | ||||
Elena Demikhovsky | bd1a49b | 2014-07-22 12:08:25 +0000 | [diff] [blame] | 99 | header "avx512erintrin.h" |
100 | } | ||||
101 | |||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 102 | explicit module bmi { |
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 103 | header "bmiintrin.h" |
104 | } | ||||
105 | |||||
106 | explicit module bmi2 { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 107 | header "bmi2intrin.h" |
108 | } | ||||
109 | |||||
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 110 | explicit module fma { |
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 111 | header "fmaintrin.h" |
112 | } | ||||
113 | |||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 114 | explicit module fma4 { |
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 115 | export sse3 |
116 | header "fma4intrin.h" | ||||
117 | } | ||||
118 | |||||
119 | explicit module lzcnt { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 120 | header "lzcntintrin.h" |
121 | } | ||||
122 | |||||
123 | explicit module popcnt { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 124 | header "popcntintrin.h" |
125 | } | ||||
126 | |||||
127 | explicit module mm3dnow { | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 128 | header "mm3dnow.h" |
129 | } | ||||
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 130 | |
131 | explicit module xop { | ||||
Douglas Gregor | 4c69859 | 2012-11-05 20:11:10 +0000 | [diff] [blame] | 132 | export fma4 |
133 | header "xopintrin.h" | ||||
134 | } | ||||
Douglas Gregor | dc779ab | 2012-11-05 23:30:26 +0000 | [diff] [blame] | 135 | |
136 | explicit module aes_pclmul { | ||||
Douglas Gregor | dc779ab | 2012-11-05 23:30:26 +0000 | [diff] [blame] | 137 | header "wmmintrin.h" |
John Thompson | b7892ff | 2015-05-27 18:26:41 +0000 | [diff] [blame] | 138 | export aes |
139 | export pclmul | ||||
Douglas Gregor | dc779ab | 2012-11-05 23:30:26 +0000 | [diff] [blame] | 140 | } |
141 | |||||
142 | explicit module aes { | ||||
Douglas Gregor | dc779ab | 2012-11-05 23:30:26 +0000 | [diff] [blame] | 143 | header "__wmmintrin_aes.h" |
144 | } | ||||
145 | |||||
146 | explicit module pclmul { | ||||
Douglas Gregor | dc779ab | 2012-11-05 23:30:26 +0000 | [diff] [blame] | 147 | header "__wmmintrin_pclmul.h" |
148 | } | ||||
Douglas Gregor | 0070c0b | 2012-01-30 06:38:25 +0000 | [diff] [blame] | 149 | } |
Ulrich Weigand | cc67344 | 2015-04-01 14:15:35 +0000 | [diff] [blame] | 150 | |
151 | explicit module systemz { | ||||
152 | requires systemz | ||||
153 | export * | ||||
154 | |||||
155 | header "s390intrin.h" | ||||
156 | |||||
157 | explicit module htm { | ||||
158 | requires htm | ||||
159 | header "htmintrin.h" | ||||
160 | header "htmxlintrin.h" | ||||
161 | } | ||||
Ulrich Weigand | ca25643 | 2015-07-30 14:10:43 +0000 | [diff] [blame] | 162 | |
163 | explicit module zvector { | ||||
164 | requires zvector, vx | ||||
165 | header "vecintrin.h" | ||||
166 | } | ||||
Ulrich Weigand | cc67344 | 2015-04-01 14:15:35 +0000 | [diff] [blame] | 167 | } |
Douglas Gregor | 3f09de6 | 2012-01-29 20:52:14 +0000 | [diff] [blame] | 168 | } |
Richard Smith | ef99e4d | 2014-10-03 00:31:35 +0000 | [diff] [blame] | 169 | |
170 | module _Builtin_stddef_max_align_t [system] [extern_c] { | ||||
171 | header "__stddef_max_align_t.h" | ||||
172 | } |