-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakePresets.json
More file actions
173 lines (173 loc) · 4.38 KB
/
CMakePresets.json
File metadata and controls
173 lines (173 loc) · 4.38 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
{
"version": 6,
"cmakeMinimumRequired": {
"major": 3,
"minor": 28,
"patch": 0
},
"configurePresets": [
{
"name": "base",
"hidden": true,
"generator": "Ninja",
"binaryDir": "${sourceDir}/build/${presetName}",
"cacheVariables": {
"CMAKE_EXPORT_COMPILE_COMMANDS": "ON"
}
},
{
"name": "fast-debug",
"displayName": "Fast Debug (O1, minimal debug info)",
"description": "Optimized for fast edit-compile-debug cycles",
"inherits": "base",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Debug",
"CMAKE_CXX_FLAGS_DEBUG": "-O1 -g1 -fno-omit-frame-pointer -fno-inline-functions -gsplit-dwarf"
}
},
{
"name": "fast-debug-asan",
"displayName": "Fast Debug + AddressSanitizer",
"description": "Memory error detection (use-after-free, buffer overflows, leaks)",
"inherits": "fast-debug",
"cacheVariables": {
"LIBGLOT_ENABLE_ASAN": "ON"
}
},
{
"name": "fast-debug-tsan",
"displayName": "Fast Debug + ThreadSanitizer",
"description": "Data race detection for multithreaded code",
"inherits": "fast-debug",
"cacheVariables": {
"LIBGLOT_ENABLE_TSAN": "ON"
}
},
{
"name": "fast-debug-ubsan",
"displayName": "Fast Debug + UndefinedBehaviorSanitizer",
"description": "Undefined behavior detection (null deref, signed overflow, etc.)",
"inherits": "fast-debug",
"cacheVariables": {
"LIBGLOT_ENABLE_UBSAN": "ON"
}
},
{
"name": "release",
"displayName": "Release (O2 + LTO)",
"description": "Production build with Link-Time Optimization",
"inherits": "base",
"cacheVariables": {
"CMAKE_BUILD_TYPE": "Release",
"CMAKE_CXX_FLAGS_RELEASE": "-O2 -DNDEBUG",
"LIBGLOT_ENABLE_LTO": "ON"
}
},
{
"name": "release-o3",
"displayName": "Release (O3 + LTO)",
"description": "Maximum optimization (may increase binary size)",
"inherits": "release",
"cacheVariables": {
"CMAKE_CXX_FLAGS_RELEASE": "-O3 -DNDEBUG"
}
},
{
"name": "release-pgo-generate",
"displayName": "Release PGO Profile Generation",
"description": "Build instrumented binary for profile generation",
"inherits": "release",
"cacheVariables": {
"LIBGLOT_ENABLE_PGO_GENERATE": "ON",
"LIBGLOT_ENABLE_LTO": "OFF"
}
},
{
"name": "release-pgo-use",
"displayName": "Release PGO Profile Use",
"description": "Build with profile-guided optimizations",
"inherits": "release",
"cacheVariables": {
"LIBGLOT_ENABLE_PGO_USE": "ON"
}
},
{
"name": "ci",
"displayName": "CI Build",
"description": "For continuous integration (all warnings as errors)",
"inherits": "release",
"cacheVariables": {
"LIBGLOT_BUILD_TESTS": "ON",
"LIBGLOT_BUILD_BENCHMARKS": "ON"
}
}
],
"buildPresets": [
{
"name": "fast-debug",
"configurePreset": "fast-debug",
"jobs": 0
},
{
"name": "fast-debug-asan",
"configurePreset": "fast-debug-asan",
"jobs": 0
},
{
"name": "fast-debug-tsan",
"configurePreset": "fast-debug-tsan",
"jobs": 0
},
{
"name": "release",
"configurePreset": "release",
"jobs": 0
},
{
"name": "release-pgo-generate",
"configurePreset": "release-pgo-generate",
"jobs": 0
},
{
"name": "release-pgo-use",
"configurePreset": "release-pgo-use",
"jobs": 0
}
],
"testPresets": [
{
"name": "fast-debug",
"configurePreset": "fast-debug",
"output": {
"outputOnFailure": true
}
},
{
"name": "fast-debug-asan",
"configurePreset": "fast-debug-asan",
"environment": {
"ASAN_OPTIONS": "detect_leaks=1:check_initialization_order=1:strict_init_order=1"
},
"output": {
"outputOnFailure": true
}
},
{
"name": "fast-debug-tsan",
"configurePreset": "fast-debug-tsan",
"environment": {
"TSAN_OPTIONS": "second_deadlock_stack=1"
},
"output": {
"outputOnFailure": true
}
},
{
"name": "release",
"configurePreset": "release",
"output": {
"outputOnFailure": true
}
}
]
}