• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*===------- llvm/Config/llvm-config.h - llvm configuration -------*- C -*-===*/
2 /*                                                                            */
3 /* Part of the LLVM Project, under the Apache License v2.0 with LLVM          */
4 /* Exceptions.                                                                */
5 /* See https://llvm.org/LICENSE.txt for license information.                  */
6 /* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception                    */
7 /*                                                                            */
8 /*===----------------------------------------------------------------------===*/
9 
10 /* This file enumerates variables from the LLVM configuration so that they
11    can be in exported headers and won't override package specific directives.
12    This is a C header that can be included in the llvm-c headers. */
13 
14 #ifndef LLVM_CONFIG_H
15 #define LLVM_CONFIG_H
16 
17 #if !defined(__i386__) && defined(_M_IX86)
18 #define __i386__ 1
19 #endif
20 
21 #if !defined(__x86_64__) && (defined(_M_AMD64) || defined (_M_X64))
22 #define __x86_64__ 1
23 #endif
24 
25 #define LLVM_CONFIG_H
26 
27 /* Define if LLVM_ENABLE_DUMP is enabled */
28 /* #undef LLVM_ENABLE_DUMP */
29 
30 /* Target triple LLVM will generate code for by default */
31 /* Doesn't use `cmakedefine` because it is allowed to be empty. */
32 #if defined(__x86_64__)
33 #define LLVM_DEFAULT_TARGET_TRIPLE "x86_64-linux-android"
34 #elif defined(__i386__)
35 #define LLVM_DEFAULT_TARGET_TRIPLE "i686-linux-android"
36 #elif defined(__arm__)
37 #define LLVM_DEFAULT_TARGET_TRIPLE "armv7-linux-androideabi"
38 #elif defined(__aarch64__)
39 #define LLVM_DEFAULT_TARGET_TRIPLE "aarch64-linux-android"
40 #elif defined(__riscv)
41 #define LLVM_DEFAULT_TARGET_TRIPLE "riscv64-linux-android"
42 #else
43 #error "unknown architecture"
44 #endif
45 
46 /* Define if threads enabled */
47 #define LLVM_ENABLE_THREADS 1
48 
49 /* Has gcc/MSVC atomic intrinsics */
50 #define LLVM_HAS_ATOMICS 1
51 
52 /* Host triple LLVM will be executed on */
53 #if defined(__x86_64__)
54 #define LLVM_HOST_TRIPLE "x86_64-linux-android"
55 #elif defined(__i386__)
56 #define LLVM_HOST_TRIPLE "i686-linux-android"
57 #elif defined(__arm__)
58 #define LLVM_HOST_TRIPLE "armv7-linux-androideabi"
59 #elif defined(__aarch64__)
60 #define LLVM_HOST_TRIPLE "aarch64-linux-android"
61 #elif defined(__riscv)
62 #define LLVM_HOST_TRIPLE "riscv64-linux-android"
63 #else
64 #error "unknown architecture"
65 #endif
66 
67 /* LLVM architecture name for the native architecture, if available */
68 #if defined(__aarch64__)
69 #define LLVM_NATIVE_ARCH AArch64
70 #elif defined(__arm__)
71 #define LLVM_NATIVE_ARCH ARM
72 #elif defined(__i386__) || defined(__x86_64__)
73 #define LLVM_NATIVE_ARCH X86
74 #elif defined(__mips__)
75 #define LLVM_NATIVE_ARCH Mips
76 #elif defined(__powerpc64__)
77 #define LLVM_NATIVE_ARCH PowerPC
78 #elif defined(__riscv)
79 #define LLVM_NATIVE_ARCH RISCV
80 #else
81 #error "unknown architecture"
82 #endif
83 
84 /* LLVM name for the native AsmParser init function, if available */
85 #if defined(__aarch64__)
86 #define LLVM_NATIVE_ASMPARSER LLVMInitializeAArch64AsmParser
87 #elif defined(__arm__)
88 #define LLVM_NATIVE_ASMPARSER LLVMInitializeARMAsmParser
89 #elif defined(__i386__) || defined(__x86_64__)
90 #define LLVM_NATIVE_ASMPARSER LLVMInitializeX86AsmParser
91 #elif defined(__mips__)
92 #define LLVM_NATIVE_ASMPARSER LLVMInitializeMipsAsmParser
93 #elif defined(__powerpc64__)
94 #define LLVM_NATIVE_ASMPARSER LLVMInitializePowerPCAsmParser
95 #elif defined(__riscv)
96 #define LLVM_NATIVE_ASMPARSER LLVMInitializeRISCVAsmParser
97 #else
98 #error "unknown architecture"
99 #endif
100 
101 /* LLVM name for the native AsmPrinter init function, if available */
102 #if defined(__aarch64__)
103 #define LLVM_NATIVE_ASMPRINTER LLVMInitializeAArch64AsmPrinter
104 #elif defined(__arm__)
105 #define LLVM_NATIVE_ASMPRINTER LLVMInitializeARMAsmPrinter
106 #elif defined(__i386__) || defined(__x86_64__)
107 #define LLVM_NATIVE_ASMPRINTER LLVMInitializeX86AsmPrinter
108 #elif defined(__mips__)
109 #define LLVM_NATIVE_ASMPRINTER LLVMInitializeMipsAsmPrinter
110 #elif defined(__powerpc64__)
111 #define LLVM_NATIVE_ASMPRINTER LLVMInitializePowerPCAsmPrinter
112 #elif defined(__riscv)
113 #define LLVM_NATIVE_ASMPRINTER LLVMInitializeRISCVAsmPrinter
114 #else
115 #error "unknown architecture"
116 #endif
117 
118 /* LLVM name for the native Disassembler init function, if available */
119 #if defined(__aarch64__)
120 #define LLVM_NATIVE_DISASSEMBLER LLVMInitializeAArch64Disassembler
121 #elif defined(__arm__)
122 #define LLVM_NATIVE_DISASSEMBLER LLVMInitializeARMDisassembler
123 #elif defined(__i386__) || defined(__x86_64__)
124 #define LLVM_NATIVE_DISASSEMBLER LLVMInitializeX86Disassembler
125 #elif defined(__mips__)
126 #define LLVM_NATIVE_DISASSEMBLER LLVMInitializeMipsDisassembler
127 #elif defined(__powerpc64__)
128 #define LLVM_NATIVE_DISASSEMBLER LLVMInitializePowerPCDisassembler
129 #elif defined(__riscv)
130 #define LLVM_NATIVE_DISASSEMBLER LLVMInitializeRISCVDisassembler
131 #else
132 #error "unknown architecture"
133 #endif
134 
135 /* LLVM name for the native Target init function, if available */
136 #if defined(__aarch64__)
137 #define LLVM_NATIVE_TARGET LLVMInitializeAArch64Target
138 #elif defined(__arm__)
139 #define LLVM_NATIVE_TARGET LLVMInitializeARMTarget
140 #elif defined(__i386__) || defined(__x86_64__)
141 #define LLVM_NATIVE_TARGET LLVMInitializeX86Target
142 #elif defined(__mips__)
143 #define LLVM_NATIVE_TARGET LLVMInitializeMipsTarget
144 #elif defined(__powerpc64__)
145 #define LLVM_NATIVE_TARGET LLVMInitializePowerPCTarget
146 #elif defined(__riscv)
147 #define LLVM_NATIVE_TARGET LLVMInitializeRISCVTarget
148 #else
149 #error "unknown architecture"
150 #endif
151 
152 /* LLVM name for the native TargetInfo init function, if available */
153 #if defined(__aarch64__)
154 #define LLVM_NATIVE_TARGETINFO LLVMInitializeAArch64TargetInfo
155 #elif defined(__arm__)
156 #define LLVM_NATIVE_TARGETINFO LLVMInitializeARMTargetInfo
157 #elif defined(__i386__) || defined(__x86_64__)
158 #define LLVM_NATIVE_TARGETINFO LLVMInitializeX86TargetInfo
159 #elif defined(__mips__)
160 #define LLVM_NATIVE_TARGETINFO LLVMInitializeMipsTargetInfo
161 #elif defined(__powerpc64__)
162 #define LLVM_NATIVE_TARGETINFO LLVMInitializePowerPCTargetInfo
163 #elif defined(__riscv)
164 #define LLVM_NATIVE_TARGETINFO LLVMInitializeRISCVTargetInfo
165 #else
166 #error "unknown architecture"
167 #endif
168 
169 /* LLVM name for the native target MC init function, if available */
170 #if defined(__aarch64__)
171 #define LLVM_NATIVE_TARGETMC LLVMInitializeAArch64TargetMC
172 #elif defined(__arm__)
173 #define LLVM_NATIVE_TARGETMC LLVMInitializeARMTargetMC
174 #elif defined(__i386__) || defined(__x86_64__)
175 #define LLVM_NATIVE_TARGETMC LLVMInitializeX86TargetMC
176 #elif defined(__mips__)
177 #define LLVM_NATIVE_TARGETMC LLVMInitializeMipsTargetMC
178 #elif defined(__powerpc64__)
179 #define LLVM_NATIVE_TARGETMC LLVMInitializePowerPCTargetMC
180 #elif defined(__riscv)
181 #define LLVM_NATIVE_TARGETMC LLVMInitializeRISCVTargetMC
182 #else
183 #error "unknown architecture"
184 #endif
185 
186 /* LLVM name for the native target MCA init function, if available */
187 /* #undef LLVM_NATIVE_TARGETMCA */
188 
189 /* Define if this is Unixish platform */
190 #define LLVM_ON_UNIX 1
191 
192 /* Define if we have the Intel JIT API runtime support library */
193 #define LLVM_USE_INTEL_JITEVENTS 0
194 
195 /* Define if we have the oprofile JIT-support library */
196 #define LLVM_USE_OPROFILE 0
197 
198 /* Define if we have the perf JIT-support library */
199 #define LLVM_USE_PERF 0
200 
201 /* Major version of the LLVM API */
202 #define LLVM_VERSION_MAJOR 16
203 
204 /* Minor version of the LLVM API */
205 #define LLVM_VERSION_MINOR 0
206 
207 /* Patch version of the LLVM API */
208 #define LLVM_VERSION_PATCH 0
209 
210 /* LLVM version string */
211 #define LLVM_VERSION_STRING "16.0.0"
212 
213 /* Whether LLVM records statistics for use with GetStatistics(),
214  * PrintStatistics() or PrintStatisticsJSON()
215  */
216 #define LLVM_FORCE_ENABLE_STATS 0
217 
218 /* Define if we have z3 and want to build it */
219 /* #undef LLVM_WITH_Z3 */
220 
221 /* Define if we have curl and want to use it */
222 /* #undef LLVM_ENABLE_CURL */
223 
224 /* Define if we have cpp-httplib and want to use it */
225 /* #undef LLVM_ENABLE_HTTPLIB */
226 
227 /* Define if zlib compression is available */
228 #define LLVM_ENABLE_ZLIB 0
229 
230 /* Define if zstd compression is available */
231 #define LLVM_ENABLE_ZSTD 0
232 
233 /* Define if LLVM is using tflite instead of libtensorflow */
234 /* #undef LLVM_HAVE_TFLITE */
235 
236 /* Define to 1 if you have the <sysexits.h> header file. */
237 #define HAVE_SYSEXITS_H 1
238 
239 /* Define if the xar_open() function is supported on this platform. */
240 /* #undef LLVM_HAVE_LIBXAR */
241 
242 /* Define if building libLLVM shared library */
243 /* #undef LLVM_BUILD_LLVM_DYLIB */
244 
245 /* Define if building LLVM with BUILD_SHARED_LIBS */
246 /* #undef LLVM_BUILD_SHARED_LIBS */
247 
248 /* Define if building LLVM with LLVM_FORCE_USE_OLD_TOOLCHAIN_LIBS */
249 /* #undef LLVM_FORCE_USE_OLD_TOOLCHAIN */
250 
251 /* Define if llvm_unreachable should be optimized with undefined behavior
252  * in non assert builds */
253 #define LLVM_UNREACHABLE_OPTIMIZE 1
254 
255 /* Define to 1 if you have the DIA SDK installed, and to 0 if you don't. */
256 #define LLVM_ENABLE_DIA_SDK 0
257 
258 /* Define if plugins enabled */
259 #define LLVM_ENABLE_PLUGINS
260 
261 #endif
262