Skip to content
This repository was archived by the owner on Sep 15, 2025. It is now read-only.

Commit 5fe7776

Browse files
SC llvm teamSC llvm team
authored andcommitted
Merged main:40e734e041fa into amd-gfx:709a102901c2
Local branch amd-gfx 709a102 Merged main:b195bb87e1a0 into amd-gfx:3af18d2c87d7 Remote branch main 40e734e [lld][MachO] Allow separate --irpgo-profile flag (llvm#121354)
2 parents 709a102 + 40e734e commit 5fe7776

35 files changed

+41
-38
lines changed

lld/MachO/Driver.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1842,7 +1842,7 @@ bool link(ArrayRef<const char *> argsArr, llvm::raw_ostream &stdoutOS,
18421842
args.hasArg(OPT_irpgo_profile_sort_eq))
18431843
warn("--irpgo-profile-sort is deprecated. Please use "
18441844
"--bp-startup-sort=function");
1845-
if (const Arg *arg = args.getLastArg(OPT_irpgo_profile_eq))
1845+
if (const Arg *arg = args.getLastArg(OPT_irpgo_profile))
18461846
config->irpgoProfilePath = arg->getValue();
18471847

18481848
if (const Arg *arg = args.getLastArg(OPT_irpgo_profile_sort)) {

lld/MachO/Options.td

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,10 @@ def no_call_graph_profile_sort : Flag<["--"], "no-call-graph-profile-sort">,
126126
def print_symbol_order_eq: Joined<["--"], "print-symbol-order=">,
127127
HelpText<"Print a symbol order specified by --call-graph-profile-sort into the specified file">,
128128
Group<grp_lld>;
129+
def irpgo_profile: Separate<["--"], "irpgo-profile">, Group<grp_lld>;
129130
def irpgo_profile_eq: Joined<["--"], "irpgo-profile=">,
130-
HelpText<"Read the IRPGO profile for use with -bp-startup-sort and other profile-guided optimizations">,
131+
Alias<!cast<Separate>(irpgo_profile)>, MetaVarName<"<profile>">,
132+
HelpText<"Read the IRPGO <profile> for use with -bp-startup-sort and other profile-guided optimizations">,
131133
Group<grp_lld>;
132134
def bp_startup_sort: Joined<["--"], "bp-startup-sort=">,
133135
MetaVarName<"[none,function]">,

lld/test/MachO/bp-section-orderer-errs.s

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,9 @@
1414
# RUN: not %lld -o /dev/null --bp-compression-sort-startup-functions 2>&1 | FileCheck %s --check-prefix=STARTUP
1515
# STARTUP: --bp-compression-sort-startup-functions must be used with --bp-startup-sort=function
1616

17+
# RUN: not %lld -o /dev/null --irpgo-profile %s --bp-startup-sort=function --call-graph-profile-sort 2>&1 | FileCheck %s --check-prefix=IRPGO-STARTUP
1718
# RUN: not %lld -o /dev/null --irpgo-profile=%s --bp-startup-sort=function --call-graph-profile-sort 2>&1 | FileCheck %s --check-prefix=IRPGO-STARTUP
1819
# IRPGO-STARTUP: --bp-startup-sort= is incompatible with --call-graph-profile-sort
1920

2021
# RUN: not %lld -o /dev/null --bp-startup-sort=function 2>&1 | FileCheck %s --check-prefix=STARTUP-COMPRESSION
21-
# STARTUP-COMPRESSION: --bp-startup-sort=function must be used with --irpgo-profile
22+
# STARTUP-COMPRESSION: --bp-startup-sort=function must be used with --irpgo-profile

lld/test/MachO/bp-section-orderer.s

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# RUN: %no-fatal-warnings-lld -arch arm64 -lSystem -e _main -o %t/a.out %t/a.o --irpgo-profile-sort=%t/a.profdata --verbose-bp-section-orderer 2>&1 | FileCheck %s --check-prefix=STARTUP
88
# RUN: %no-fatal-warnings-lld -arch arm64 -lSystem -e _main -o %t/a.out %t/a.o --irpgo-profile-sort=%t/a.profdata --verbose-bp-section-orderer --icf=all --compression-sort=none 2>&1 | FileCheck %s --check-prefix=STARTUP
99

10-
# RUN: %lld -arch arm64 -lSystem -e _main -o %t/a.out %t/a.o --irpgo-profile=%t/a.profdata --bp-startup-sort=function --verbose-bp-section-orderer 2>&1 | FileCheck %s --check-prefix=STARTUP
10+
# RUN: %lld -arch arm64 -lSystem -e _main -o %t/a.out %t/a.o --irpgo-profile %t/a.profdata --bp-startup-sort=function --verbose-bp-section-orderer 2>&1 | FileCheck %s --check-prefix=STARTUP
1111
# RUN: %lld -arch arm64 -lSystem -e _main -o %t/a.out %t/a.o --irpgo-profile=%t/a.profdata --bp-startup-sort=function --verbose-bp-section-orderer --icf=all --bp-compression-sort=none 2>&1 | FileCheck %s --check-prefix=STARTUP
1212
# STARTUP: Ordered 3 sections using balanced partitioning
1313

llvm/include/llvm/Config/llvm-config.h.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
/* Indicate that this is LLVM compiled from the amd-gfx branch. */
1818
#define LLVM_HAVE_BRANCH_AMD_GFX
19-
#define LLVM_MAIN_REVISION 522547
19+
#define LLVM_MAIN_REVISION 522552
2020

2121
/* Define if LLVM_ENABLE_DUMP is enabled */
2222
#cmakedefine LLVM_ENABLE_DUMP

llvm/test/Transforms/PhaseOrdering/AArch64/extra-unroll-simplifications.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
2-
; RUN: opt -passes='default<O3>' -S %s | FileCheck %s
2+
; RUN: opt -passes="default<O3>" -S %s | FileCheck %s
33

44
target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
55
target triple = "arm64-apple-macosx11.0.0"

llvm/test/Transforms/PhaseOrdering/AArch64/hoist-runtime-checks.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
2-
; RUN: opt -passes='default<O3>' -S %s | FileCheck %s
2+
; RUN: opt -passes="default<O3>" -S %s | FileCheck %s
33

44
target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
55
target triple = "arm64-apple-macosx11.0.0"

llvm/test/Transforms/PhaseOrdering/AArch64/hoisting-sinking-required-for-vectorization.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
2-
; RUN: opt -passes='default<O3>' -S %s | FileCheck %s
2+
; RUN: opt -passes="default<O3>" -S %s | FileCheck %s
33

44
target triple = "arm64-apple-darwin"
55

llvm/test/Transforms/PhaseOrdering/AArch64/indvars-vectorization.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
2-
; RUN: opt -passes='default<O3>' -S -o - %s | FileCheck %s
2+
; RUN: opt -passes="default<O3>" -S -o - %s | FileCheck %s
33

44
target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
55
target triple = "arm64-apple-macosx14.0.0"

llvm/test/Transforms/PhaseOrdering/AArch64/loopflatten.ll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
2-
; RUN: opt -passes='default<O3>' -enable-loop-flatten -loop-flatten-cost-threshold=3 -S %s | FileCheck %s
2+
; RUN: opt -passes="default<O3>" -enable-loop-flatten -loop-flatten-cost-threshold=3 -S %s | FileCheck %s
33

44
target datalayout = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"
55
target triple = "aarch64"

0 commit comments

Comments
 (0)