aboutsummaryrefslogtreecommitdiff
path: root/www/iridium/files/patch-build_config_compiler_pgo_BUILD.gn
blob: c1229fcc61c931b2c22842b105951527db5441a2 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
--- build/config/compiler/pgo/BUILD.gn.orig	2023-08-28 20:17:35 UTC
+++ build/config/compiler/pgo/BUILD.gn
@@ -128,13 +128,14 @@ config("pgo_optimization_flags") {
 
     # Enable basic block layout based on the extended TSP problem. This aims to
     # improve icache utilization and reduce the binary size.
-    if (use_thin_lto) {
+    # __clang_major__ >= 15
+    if (use_thin_lto && !is_bsd) {
       if (is_win) {
         ldflags = [ "-mllvm:-enable-ext-tsp-block-placement=1" ]
       } else {
         ldflags = [ "-Wl,-mllvm,-enable-ext-tsp-block-placement=1" ]
       }
-    } else {
+    } else if (!is_bsd) {
       cflags += [
         "-mllvm",
         "-enable-ext-tsp-block-placement=1",