[clang] [llvm] [CMake][Release] Add option for enabling PGO to release cache file. (PR #78823)

Petr Hosek via llvm-commits llvm-commits at lists.llvm.org
Sat Jan 20 17:07:29 PST 2024


================
@@ -37,11 +63,26 @@ set(BOOTSTRAP_CLANG_BOOTSTRAP_TARGETS
 
 # Stage 2 Options
 set(STAGE2_PROJECTS "clang")
-if (LLVM_RELEASE_ENABLE_LTO)
+set(STAGE2_RUNTIMES "")
+
+if (LLVM_RELEASE_ENABLE_LTO OR LLVM_RELEASE_ENABLE_PGO)
  list(APPEND STAGE2_PROJECTS "lld")
 endif()
+
+if (LLVM_RELEASE_ENABLE_PGO)
+  set(BOOTSTRAP_LLVM_BUILD_INSTRUMENTED ON CACHE BOOL "")
----------------
petrhosek wrote:

```suggestion
  set(BOOTSTRAP_LLVM_BUILD_INSTRUMENTED IR CACHE STRING "")
```

https://github.com/llvm/llvm-project/pull/78823


More information about the llvm-commits mailing list