-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Expand file tree
/
Copy pathCMakePresets.json
More file actions
376 lines (376 loc) · 10.6 KB
/
Copy pathCMakePresets.json
File metadata and controls
376 lines (376 loc) · 10.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
{
"version": 6,
"cmakeMinimumRequired": {
"major": 3,
"minor": 28,
"patch": 0
},
"configurePresets": [
{
"name": "base",
"hidden": true,
"binaryDir": "build/${presetName}",
"installDir": "install/${presetName}"
},
{
"name": "ci",
"hidden": true,
"binaryDir": "build",
"installDir": "local",
"generator": "Ninja",
"toolchainFile": "$env{VCPKG_INSTALLATION_ROOT}/scripts/buildsystems/vcpkg.cmake",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "RelWithDebInfo",
"CMAKE_COMPILE_WARNING_AS_ERROR": "ON",
"FETCHCONTENT_FULLY_DISCONNECTED": "ON",
"VCPKG_CHAINLOAD_TOOLCHAIN_FILE": "${sourceDir}/cmake/toolchain.${presetName}.cmake",
"VCPKG_MANIFEST_FEATURES": "developer",
"Halide_BUILDING_IN_CI": "ON"
}
},
{
"name": "ci-linux-x86-64",
"inherits": "ci"
},
{
"name": "ci-linux-x86-32",
"inherits": "ci",
"cacheVariables": {
"WITH_PYTHON_BINDINGS": "NO"
}
},
{
"name": "ci-linux-arm-64",
"inherits": "ci",
"cacheVariables": {
"WITH_PYTHON_BINDINGS": "NO"
}
},
{
"name": "ci-linux-arm-32",
"inherits": "ci",
"cacheVariables": {
"WITH_PYTHON_BINDINGS": "NO"
}
},
{
"name": "ci-macos-arm-64",
"inherits": "ci"
},
{
"name": "ci-macos-x86-64",
"inherits": "ci"
},
{
"name": "ci-windows-x86-64",
"inherits": "ci"
},
{
"name": "ci-windows-x86-32",
"inherits": "ci",
"cacheVariables": {
"WITH_PYTHON_BINDINGS": "NO"
}
},
{
"name": "vcpkg",
"inherits": "base",
"displayName": "vcpkg deps",
"description": "Build dependencies (with Halide exclusions) with vcpkg",
"toolchainFile": "$env{VCPKG_ROOT}/scripts/buildsystems/vcpkg.cmake",
"cacheVariables": {
"VCPKG_MANIFEST_FEATURES": "developer",
"FETCHCONTENT_FULLY_DISCONNECTED": "ON"
}
},
{
"name": "vs2022",
"hidden": true,
"inherits": [
"vcpkg"
],
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Windows"
},
"generator": "Visual Studio 17 2022",
"toolset": "host=x64"
},
{
"name": "debug",
"inherits": "base",
"displayName": "Debug",
"description": "Debug build with no special settings",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug"
}
},
{
"name": "release",
"inherits": "base",
"displayName": "Release",
"description": "Release build with no special settings",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Release"
}
},
{
"name": "ubuntu",
"inherits": "base",
"hidden": true,
"cacheVariables": {
"Halide_WASM_BACKEND": "OFF"
}
},
{
"name": "ubuntu-debug",
"inherits": [
"ubuntu",
"debug"
],
"displayName": "Debug (Ubuntu)",
"description": "Debug build for a single-config generator, Ubuntu dependencies"
},
{
"name": "ubuntu-release",
"inherits": [
"ubuntu",
"release"
],
"displayName": "Release (Ubuntu)",
"description": "Release build for a single-config generator, Ubuntu dependencies"
},
{
"name": "debug-vcpkg",
"inherits": [
"debug",
"vcpkg"
],
"displayName": "Debug (vcpkg)",
"description": "Debug build for a single-config generator, vcpkg dependencies"
},
{
"name": "release-vcpkg",
"inherits": [
"release",
"vcpkg"
],
"displayName": "Release (vcpkg)",
"description": "Release build for a single-config generator, vcpkg dependencies"
},
{
"name": "win32",
"inherits": "vs2022",
"displayName": "Win32 (Visual Studio)",
"description": "Visual Studio-based Win32 build with vcpkg dependencies.",
"architecture": "Win32"
},
{
"name": "win64",
"inherits": "vs2022",
"displayName": "Win64 (Visual Studio)",
"description": "Visual Studio-based x64 build with vcpkg dependencies.",
"architecture": "x64"
},
{
"name": "macOS",
"displayName": "macOS (Apple Clang)",
"description": "macOS build using Apple Clang and Homebrew LLVM",
"generator": "Ninja",
"inherits": "release",
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Darwin"
},
"cacheVariables": {
"Halide_LLVM_ROOT": "/opt/homebrew/opt/llvm"
}
},
{
"name": "macOS-fuzz",
"displayName": "macOS (Fuzz)",
"description": "macOS fuzzing build",
"inherits": "macOS",
"toolchainFile": "${sourceDir}/cmake/toolchain.macos-homebrew.cmake",
"cacheVariables": {
"CMAKE_C_FLAGS": "-fsanitize=fuzzer-no-link -O1 -g3",
"CMAKE_CXX_FLAGS": "-fsanitize=fuzzer-no-link -O1 -g3",
"CMAKE_EXE_LINKER_FLAGS": "-fsanitize=fuzzer",
"CMAKE_MODULE_LINKER_FLAGS": "-fsanitize=fuzzer",
"CMAKE_SHARED_LINKER_FLAGS": "-fsanitize=fuzzer"
}
},
{
"name": "macOS-coverage",
"displayName": "macOS (Coverage)",
"description": "macOS build with source-based LLVM coverage instrumentation",
"inherits": "macOS",
"toolchainFile": "${sourceDir}/cmake/toolchain.macos-homebrew.cmake",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug",
"CMAKE_C_FLAGS": "-fprofile-instr-generate -fcoverage-mapping",
"CMAKE_CXX_FLAGS": "-fprofile-instr-generate -fcoverage-mapping",
"CMAKE_EXE_LINKER_FLAGS": "-fprofile-instr-generate",
"CMAKE_MODULE_LINKER_FLAGS": "-fprofile-instr-generate",
"CMAKE_SHARED_LINKER_FLAGS": "-fprofile-instr-generate",
"WITH_TUTORIALS": "NO",
"WITH_PYTHON_BINDINGS": "NO",
"WITH_UTILS": "NO",
"WITH_TEST_AUTO_SCHEDULE": "YES",
"WITH_TEST_ERROR": "YES",
"WITH_TEST_WARNING": "NO",
"WITH_TEST_PERFORMANCE": "NO",
"WITH_TEST_GENERATOR": "YES",
"WITH_TEST_RUNTIME": "NO",
"WITH_TEST_FUZZ": "NO",
"WITH_TEST_CORRECTNESS": "YES",
"WITH_SERIALIZATION_JIT_ROUNDTRIP_TESTING": "YES"
}
},
{
"name": "macOS-vcpkg",
"inherits": [
"macOS",
"vcpkg"
],
"displayName": "macOS (vcpkg)",
"description": "macOS build with vcpkg dependencies"
},
{
"name": "linux-x64-asan",
"inherits": "ci",
"displayName": "ASAN (Linux x64)",
"description": "Build everything with ASAN enabled",
"cacheVariables": {
"LLVM_ROOT": "$penv{LLVM_ROOT}"
}
},
{
"name": "linux-x64-fuzzer",
"inherits": "ci",
"displayName": "Fuzzer (Linux x64)",
"description": "Build everything with fuzzing enabled",
"cacheVariables": {
"LLVM_ROOT": "$penv{LLVM_ROOT}",
"WITH_TUTORIALS": "NO",
"WITH_UTILS": "NO",
"WITH_PYTHON_BINDINGS": "NO",
"WITH_TESTS": "YES",
"WITH_TEST_AUTO_SCHEDULE": "NO",
"WITH_TEST_CORRECTNESS": "NO",
"WITH_TEST_ERROR": "NO",
"WITH_TEST_WARNING": "NO",
"WITH_TEST_PERFORMANCE": "NO",
"WITH_TEST_RUNTIME": "NO",
"WITH_TEST_GENERATOR": "NO",
"WITH_TEST_FUZZ": "YES",
"BUILD_SHARED_LIBS": "NO"
}
},
{
"name": "valgrind",
"inherits": "debug",
"displayName": "Valgrind (ctest -T memcheck)",
"description": "Debug build wired up so 'ctest -T memcheck' reruns the test suite under valgrind",
"cacheVariables": {
"Halide_ENABLE_MEMCHECK": "ON"
}
},
{
"name": "sde",
"hidden": true,
"inherits": "release",
"description": "Base preset for running the test suite under Intel SDE emulation"
},
{
"name": "avx512-cannonlake",
"inherits": "sde",
"displayName": "AVX-512 (Intel SDE, Cannon Lake)",
"description": "Run every registered test under 'sde -cnl --' to emulate a Cannon Lake AVX-512 CPU",
"cacheVariables": {
"CMAKE_CROSSCOMPILING_EMULATOR": "sde;-cnl;--"
}
},
{
"name": "avx512-knights-landing",
"inherits": "sde",
"displayName": "AVX-512 (Intel SDE, Knights Landing)",
"description": "Run every registered test under 'sde -knl --' to emulate a Knights Landing AVX-512 CPU",
"cacheVariables": {
"CMAKE_CROSSCOMPILING_EMULATOR": "sde;-knl;--"
}
}
],
"buildPresets": [
{
"name": "valgrind",
"configurePreset": "valgrind",
"displayName": "Valgrind (ctest -T memcheck)"
},
{
"name": "avx512-cannonlake",
"configurePreset": "avx512-cannonlake",
"displayName": "AVX-512 (Intel SDE, Cannon Lake)"
},
{
"name": "avx512-knights-landing",
"configurePreset": "avx512-knights-landing",
"displayName": "AVX-512 (Intel SDE, Knights Landing)"
},
{
"name": "macOS-coverage",
"configurePreset": "macOS-coverage",
"displayName": "macOS (Coverage)",
"description": "Build with LLVM_PROFILE_FILE set so generator binaries write profiles to the profiles/ dir",
"environment": {
"LLVM_PROFILE_FILE": "${sourceDir}/build/macOS-coverage/profiles/%p-%m.profraw"
}
}
],
"testPresets": [
{
"name": "valgrind",
"configurePreset": "valgrind",
"displayName": "Valgrind (ctest -T memcheck)",
"description": "Selects the tests to run under valgrind; CTest presets can't select the '-T memcheck' action on their own, so pass it explicitly: 'ctest --preset valgrind -T memcheck'",
"filter": {
"exclude": {
"label": "no_memcheck"
}
},
"output": {
"outputOnFailure": true
}
},
{
"name": "avx512-cannonlake",
"configurePreset": "avx512-cannonlake",
"displayName": "AVX-512 (Intel SDE, Cannon Lake)",
"output": {
"outputOnFailure": true
}
},
{
"name": "avx512-knights-landing",
"configurePreset": "avx512-knights-landing",
"displayName": "AVX-512 (Intel SDE, Knights Landing)",
"output": {
"outputOnFailure": true
}
},
{
"name": "macOS-coverage",
"configurePreset": "macOS-coverage",
"displayName": "macOS (Coverage)",
"description": "Run correctness tests with LLVM source-based coverage profiling",
"environment": {
"LLVM_PROFILE_FILE": "${sourceDir}/build/macOS-coverage/profiles/%p-%m.profraw"
},
"output": {
"outputOnFailure": true
}
}
]
}