41
41
standards : ' 20'
42
42
latest-factors : |
43
43
msvc Optimized-Debug
44
- gcc Coverage
44
+ gcc UBSan Coverage
45
+ clang UBSan
45
46
factors : ' '
46
47
runs-on : |
47
48
apple-clang: macos-15
@@ -65,21 +66,21 @@ jobs:
65
66
msvc: ''
66
67
extra-values : |
67
68
llvm-hash: dd7a3d4d798e30dfe53b5bbbbcd9a23c24ea1af9
68
- llvm-id : {{ substr llvm-hash 0 7 }}
69
- llvm-build-preset-prefix : {{#if optimized-debug}}debwithopt {{else}}{{lowercase build-type}} {{/if}}
70
- llvm-build-preset-suffix : {{#if (ieq os 'windows') }}win {{else}}unix {{/if}}
71
- llvm-build-preset: {{ llvm-build-preset-prefix }}-{{ llvm-build-preset-suffix }}
72
- llvm-compiler-key: {{ compiler }}-{{ version }}
73
- llvm-cache-key: llvm-libcxx-{{ lowercase os }}-{{ llvm-compiler-key }}-{{ llvm-build-preset-prefix }}-{{ llvm-hash }}
69
+ llvm-build-preset-prefix : {{#if optimized-debug}}debwithopt{{else}}{{{lowercase build-type}}}{{/if }}
70
+ llvm-build-preset-os : {{#if (ieq os 'windows') }}win {{else}}unix {{/if}}
71
+ llvm-build-preset-sanitizer : {{#if ubsan}}-UBSan{{else if asan}}-ASan {{else if msan}}-MSan {{/if}}
72
+ llvm-build-preset: {{{ llvm-build-preset-prefix }}} -{{{ llvm-build-preset-os } }}
73
+ llvm-compiler-key: {{{ compiler }}} -{{{ version } }}
74
+ llvm-cache-key: llvm-{{{ lowercase os }}} -{{{ llvm-compiler-key }}} -{{{ llvm-build-preset-prefix }}}{{{ llvm-build-preset-sanitizer }}}-{{{ substr llvm-hash 0 7 } }}
74
75
llvm-root: ../third-party/llvm-project/install
75
- llvm-archive-basename: llvm-{{ os }}-{{ llvm-build-preset-prefix }}-{{ llvm-id }}
76
76
llvm-archive-extension: {{#if (ieq os 'windows') }}7z{{else}}tar.bz2{{/if}}
77
- llvm-archive-filename: {{ llvm-archive-basename }}.{{ llvm-archive-extension }}
78
- mrdocs-ccflags: {{ ccflags }} {{#if (eq compiler 'gcc') }}-static{{/if}} {{#if asan }}-static-libasan{{/if}} {{#if tsan }}-static-libtsan {{/if}}
79
- mrdocs-cxxflags: {{ cxxflags }} {{#if (eq compiler 'gcc') }}-static{{/if}} {{#if asan }}-static-libasan{{/if}} {{#if tsan }}-static-libtsan {{/if}}
77
+ llvm-archive-filename: {{{ llvm-cache-key }}} .{{{ llvm-archive-extension } }}
78
+ mrdocs-ccflags: {{{ ccflags }}} {{#if (and ( eq compiler 'gcc') (not asan)) }}-static{{/if}}
79
+ mrdocs-cxxflags: {{{ cxxflags }}} {{#if (and ( eq compiler 'gcc') (not asan)) }}-static{{/if}}
80
80
mrdocs-package-generators: {{#if (ieq os 'windows') }}7Z ZIP WIX{{else}}TGZ TXZ{{/if}}
81
- mrdocs-release-package-artifact: release-packages-{{ lowercase os }}
81
+ mrdocs-release-package-artifact: release-packages-{{{ lowercase os } }}
82
82
output-file : matrix.json
83
+ trace-commands : true
83
84
84
85
# Set up the version as expected by the LLVM matrix script and @actions/core
85
86
- name : Setup Node.js
@@ -260,6 +261,10 @@ jobs:
260
261
build-type : ${{ matrix.build-type }}
261
262
extra-args : |
262
263
${{ runner.os == 'Windows' && '-DLLVM_ENABLE_RUNTIMES=libcxx' || '-DLLVM_ENABLE_RUNTIMES=libcxx;libcxxabi;libunwind' }}
264
+ # The UBSan vptr sanitizer needs RTTI.
265
+ ${{ matrix.ubsan && '-DLLVM_ENABLE_RTTI=ON' }}
266
+ # The LLVM_USE_SANITIZER option doesn't support GCC.
267
+ ${{ !matrix.compiler == 'gcc' && matrix.ubsan && '-DLLVM_USE_SANITIZER=Undefined' }}
263
268
cc : ${{ steps.setup-cpp.outputs.cc }}
264
269
cxx : ${{ steps.setup-cpp.outputs.cxx }}
265
270
generator : Ninja
0 commit comments