Name Date Size #Lines LOC

..--

3-stage-base.cmakeH A D15-Nov-20221.5 KiB4739

3-stage.cmakeH A D25-Jun-2021315 1714

Android-stage2.cmakeH A D25-Jun-20213.5 KiB5345

Android.cmakeH A D29-Jan-20251.5 KiB4535

Apple-stage1.cmakeH A D25-Jun-20211.9 KiB6153

Apple-stage2-ThinLTO.cmakeH A D25-Jun-2021210 74

Apple-stage2.cmakeH A D08-Jul-20243.1 KiB9177

BOLT-PGO.cmakeH A D08-Jul-2024419 1815

BOLT.cmakeH A D08-Jul-2024421 1411

BaremetalARM.cmakeH A D18-Feb-20222.3 KiB5245

CrossWinToARMLinux.cmakeH A D29-Jan-202514.5 KiB276238

DistributionExample-stage2.cmakeH A D25-Jun-2021888 3428

DistributionExample.cmakeH A D25-Jun-20211.5 KiB5141

Fuchsia-stage2.cmakeH A D29-Jan-202526.9 KiB

Fuchsia.cmakeH A D29-Jan-20257.7 KiB227200

HLSL.cmakeH A D08-Jul-2024664 2015

MultiDistributionExample.cmakeH A D15-Nov-20222.6 KiB7568

PGO-stage2-instrumented.cmakeH A D25-Jun-2021542 2320

PGO-stage2.cmakeH A D15-Nov-2022173 43

PGO.cmakeH A D08-Jul-2024998 3327

README.txtH A D25-Jun-20212.4 KiB7550

Release.cmakeH A D29-Jan-20254.3 KiB9783

VectorEngine.cmakeH A D08-Jul-20245.9 KiB130111

hexagon-unknown-linux-musl-clang-cross.cmakeH A D29-Jan-2025691

hexagon-unknown-linux-musl-clang.cmakeH A D29-Jan-2025705

README.txt

1CMake Caches
2============
3
4This directory contains CMake cache scripts that pre-populate the CMakeCache in
5a build directory with commonly used settings.
6
7You can use the caches files with the following CMake invocation:
8
9cmake -G <build system>
10  -C <path to cache file>
11  [additional CMake options (i.e. -DCMAKE_INSTALL_PREFIX=<install path>)]
12  <path to llvm>
13
14Options specified on the command line will override options in the cache files.
15
16The following cache files exist.
17
18Apple-stage1
19------------
20
21The Apple stage1 cache configures a two stage build similar to how Apple builds
22the clang shipped with Xcode. The build files generated from this invocation has
23a target named "stage2" which performs an LTO build of clang.
24
25The Apple-stage2 cache can be used directly to match the build settings Apple
26uses in shipping builds without doing a full bootstrap build.
27
28PGO
29---
30
31The PGO CMake cache can be used to generate a multi-stage instrumented compiler.
32You can configure your build directory with the following invocation of CMake:
33
34cmake -G <generator> -C <path_to_clang>/cmake/caches/PGO.cmake <source dir>
35
36After configuration the following additional targets will be generated:
37
38stage2-instrumented:
39Builds a stage1 x86 compiler, runtime, and required tools (llvm-config,
40llvm-profdata) then uses that compiler to build an instrumented stage2 compiler.
41
42stage2-instrumented-generate-profdata:
43Depends on "stage2-instrumented" and will use the instrumented compiler to
44generate profdata based on the training files in <clang>/utils/perf-training
45
46stage2:
47Depends on "stage2-instrumented-generate-profdata" and will use the stage1
48compiler with the stage2 profdata to build a PGO-optimized compiler.
49
50stage2-check-llvm:
51Depends on stage2 and runs check-llvm using the stage3 compiler.
52
53stage2-check-clang:
54Depends on stage2 and runs check-clang using the stage3 compiler.
55
56stage2-check-all:
57Depends on stage2 and runs check-all using the stage3 compiler.
58
59stage2-test-suite:
60Depends on stage2 and runs the test-suite using the stage3 compiler (requires
61in-tree test-suite).
62
633-stage
64-------
65
66This cache file can be used to generate a 3-stage clang build. You can configure
67using the following CMake command:
68
69cmake -C <path to clang>/cmake/caches/3-stage.cmake -G Ninja <path to llvm>
70
71You can then run "ninja stage3-clang" to build stage1, stage2 and stage3 clangs.
72
73This is useful for finding non-determinism the compiler by verifying that stage2
74and stage3 are identical.
75