Skip to content

Commit f5cb455

Browse files
committed
Replace remote-opt-tool with remote-compiler
1 parent 68e088b commit f5cb455

File tree

26 files changed

+55
-55
lines changed

26 files changed

+55
-55
lines changed

clang/lib/Driver/ToolChains/Gnu.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -543,7 +543,7 @@ void tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
543543
CmdArgs.push_back(
544544
Args.MakeArgString("--thinlto-distributor=" + Twine(A->getValue())));
545545
CmdArgs.push_back(
546-
Args.MakeArgString("--thinlto-remote-opt-tool=" +
546+
Args.MakeArgString("--thinlto-remote-compiler=" +
547547
Twine(ToolChain.getDriver().getClangProgramPath())));
548548

549549
for (auto A : Args.getAllArgValues(options::OPT_Xthinlto_distributor_EQ))

clang/test/Driver/DTLTO/dtlto.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
// CHECK: ld.lld
1616
// CHECK-SAME: "--thinlto-distributor=dist.exe"
17-
// CHECK-SAME: "--thinlto-remote-opt-tool={{.*}}clang
17+
// CHECK-SAME: "--thinlto-remote-compiler={{.*}}clang
1818
// CHECK-SAME: "-mllvm=-thinlto-distributor-arg=distarg1"
1919
// CHECK-SAME: "-mllvm=-thinlto-distributor-arg=distarg2"
2020
// CHECK-SAME: "-mllvm=-thinlto-distributor-arg=distarg3"
@@ -30,7 +30,7 @@
3030
// NONE: warning: argument unused during compilation: '-Xthinlto-distributor=distarg2,distarg3'
3131
// NONE: ld.lld
3232
// NOMORE-NOT: --thinlto-distributor=
33-
// NOMORE-NOT: --thinlto-remote-opt-tool=
33+
// NOMORE-NOT: --thinlto-remote-compiler=
3434
// NOMORE-NOT: -mllvm
3535
// NOMORE-NOT: -thinlto-distributor-arg=
3636

@@ -43,4 +43,4 @@
4343

4444
// DEFAULT: ld.lld
4545
// DEFAULT-SAME: "--thinlto-distributor=dist.exe"
46-
// DEFAULT-SAME: "--thinlto-remote-opt-tool={{.*}}clang
46+
// DEFAULT-SAME: "--thinlto-remote-compiler={{.*}}clang

cross-project-tests/dtlto/archive-thin.test

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
# RUN: -nostdlib \
3333
# RUN: -nostartfiles \
3434
# RUN: -Wl,--save-temps \
35-
# RUN: -Wl,-mllvm,--thinlto-remote-opt-tool-arg=-save-temps=cwd \
35+
# RUN: -Wl,-mllvm,--thinlto-remote-compiler-arg=-save-temps=cwd \
3636
# RUN: -Werror
3737

3838
## Check that the required output files have been created.

cross-project-tests/dtlto/dtlto-translate-options.ll

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,24 +21,24 @@
2121
; DEFINE: %{triple} = dummy
2222
; DEFINE: %{command} = llvm-lto2 run \
2323
; DEFINE: -thinlto-distributor-arg=%llvm_src_root/utils/dtlto/%{distributor} \
24-
; DEFINE: -thinlto-remote-opt-tool-arg=-Wunused-command-line-argument \
24+
; DEFINE: -thinlto-remote-compiler-arg=-Wunused-command-line-argument \
2525
; DEFINE: @%{triple}.rsp %{extra_flags}
2626

2727

2828
;; Write common arguments to response files.
2929

3030
; RUN: echo "x86_64-unknown-linux-gnu.bc -o x86_64-unknown-linux-gnu.o \
3131
; RUN: -dtlto \
32-
; RUN: -dtlto-remote-opt-tool=%clang \
33-
; RUN: -thinlto-remote-opt-tool-arg=-Werror \
32+
; RUN: -dtlto-remote-compiler=%clang \
33+
; RUN: -thinlto-remote-compiler-arg=-Werror \
3434
; RUN: -dtlto-distributor=%python \
3535
; RUN: -r=x86_64-unknown-linux-gnu.bc,globalfunc1,plx" > x86_64-unknown-linux-gnu.rsp
3636

3737
; RUN: echo "x86_64-pc-windows-msvc.bc -o x86_64-pc-windows-msvc.o \
3838
; RUN: -dtlto \
39-
; RUN: -dtlto-remote-opt-tool=%clang \
40-
; RUN: -thinlto-remote-opt-tool-arg=-Werror \
41-
; RUN: -thinlto-remote-opt-tool-arg=-Wno-override-module \
39+
; RUN: -dtlto-remote-compiler=%clang \
40+
; RUN: -thinlto-remote-compiler-arg=-Werror \
41+
; RUN: -thinlto-remote-compiler-arg=-Wno-override-module \
4242
; RUN: -dtlto-distributor=%python \
4343
; RUN: -r=x86_64-pc-windows-msvc.bc,globalfunc2,plx" > x86_64-pc-windows-msvc.rsp
4444

lld/COFF/Config.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -194,8 +194,8 @@ struct Configuration {
194194

195195
// Used for --thinlto-distributor=
196196
StringRef dtltoDistributor;
197-
// Used for --thinlto-remote-opt-tool=
198-
StringRef dtltoRemoteOptTool;
197+
// Used for --thinlto-remote-compiler=
198+
StringRef dtltoRemoteCompiler;
199199

200200
// Used for /opt:[no]ltodebugpassmanager
201201
bool ltoDebugPassManager = false;

lld/COFF/Driver.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1520,8 +1520,8 @@ void LinkerDriver::linkerMain(ArrayRef<const char *> argsArr) {
15201520
}
15211521

15221522
if (!ctx.config.dtltoDistributor.empty())
1523-
for (auto o : {"-thinlto-remote-opt-tool-arg=-fdiagnostics-format",
1524-
"-thinlto-remote-opt-tool-arg=msvc"}) {
1523+
for (auto o : {"-thinlto-remote-compiler-arg=-fdiagnostics-format",
1524+
"-thinlto-remote-compiler-arg=msvc"}) {
15251525
v.push_back(o);
15261526
config->mllvmOpts.emplace_back(o);
15271527
}
@@ -2091,8 +2091,8 @@ void LinkerDriver::linkerMain(ArrayRef<const char *> argsArr) {
20912091

20922092
// Handle DTLTO options.
20932093
config->dtltoDistributor = args.getLastArgValue(OPT_thinlto_distributor_eq);
2094-
config->dtltoRemoteOptTool =
2095-
args.getLastArgValue(OPT_thinlto_remote_opt_tool_eq);
2094+
config->dtltoRemoteCompiler =
2095+
args.getLastArgValue(OPT_thinlto_remote_compiler_eq);
20962096

20972097
// Handle /dwodir
20982098
config->dwoDir = args.getLastArgValue(OPT_dwodir);

lld/COFF/LTO.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ BitcodeCompiler::BitcodeCompiler(COFFLinkerContext &c) : ctx(c) {
123123
/*OnWrite=*/nullptr,
124124
/*ShouldEmitIndexFiles=*/false,
125125
/*ShouldEmitImportFiles=*/false, ctx.config.outputFile,
126-
ctx.config.dtltoRemoteOptTool, ctx.config.dtltoDistributor,
126+
ctx.config.dtltoRemoteCompiler, ctx.config.dtltoDistributor,
127127
!ctx.config.saveTempsArgs.empty());
128128
} else if (ctx.config.thinLTOIndexOnly) {
129129
auto OnIndexWrite = [&](StringRef S) { thinIndices.erase(S); };

lld/COFF/Options.td

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ def thinlto_prefix_replace: P<
272272
"'old;new' replace old prefix with new prefix in ThinLTO outputs">;
273273
def thinlto_distributor_eq: Joined<["--"], "thinlto-distributor=">,
274274
HelpText<"Distributor to use for ThinLTO backend compilations">;
275-
def thinlto_remote_opt_tool_eq: Joined<["--"], "thinlto-remote-opt-tool=">,
275+
def thinlto_remote_compiler_eq: Joined<["--"], "thinlto-remote-compiler=">,
276276
HelpText<"Optimization tool to be invoked by the ThinLTO distributor">;
277277
def lto_obj_path : P<
278278
"lto-obj-path",

lld/ELF/Config.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ struct Config {
244244
llvm::SmallVector<llvm::StringRef, 0> symbolOrderingFile;
245245
llvm::SmallVector<llvm::StringRef, 0> thinLTOModulesToCompile;
246246
llvm::StringRef dtltoDistributor;
247-
llvm::StringRef dtltoRemoteOptTool;
247+
llvm::StringRef dtltoRemoteCompiler;
248248
llvm::SmallVector<llvm::StringRef, 0> undefined;
249249
llvm::SmallVector<SymbolVersion, 0> dynamicList;
250250
llvm::SmallVector<uint8_t, 0> buildIdVector;

lld/ELF/Driver.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1342,8 +1342,8 @@ static void readConfigs(Ctx &ctx, opt::InputArgList &args) {
13421342
ctx.arg.disableVerify = args.hasArg(OPT_disable_verify);
13431343
ctx.arg.discard = getDiscard(args);
13441344
ctx.arg.dtltoDistributor = args.getLastArgValue(OPT_thinlto_distributor_eq);
1345-
ctx.arg.dtltoRemoteOptTool =
1346-
args.getLastArgValue(OPT_thinlto_remote_opt_tool_eq);
1345+
ctx.arg.dtltoRemoteCompiler =
1346+
args.getLastArgValue(OPT_thinlto_remote_compiler_eq);
13471347
ctx.arg.dwoDir = args.getLastArgValue(OPT_plugin_opt_dwo_dir_eq);
13481348
ctx.arg.dynamicLinker = getDynamicLinker(ctx, args);
13491349
ctx.arg.ehFrameHdr =

0 commit comments

Comments
 (0)