Skip to content

Commit b924c8c

Browse files
committed
[clang][LTO] Remove the use of -- for arange option
https://reviews.llvm.org/D134668 removed all `--` (double dashes) when using `plugin-opt` to pass linker options and replaced them with `-`. https://reviews.llvm.org/D133092 was committed later but introduced an instance of `--`. This patch replaces the `--` with `-`. Reviewed By: MaskRay Differential Revision: https://reviews.llvm.org/D135400
1 parent deba92d commit b924c8c

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

clang/lib/Driver/ToolChains/CommonArgs.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -514,7 +514,7 @@ void tools::addLTOOptions(const ToolChain &ToolChain, const ArgList &Args,
514514
// the way out.
515515
if (Args.hasArg(options::OPT_gdwarf_aranges)) {
516516
CmdArgs.push_back(
517-
Args.MakeArgString("--plugin-opt=-generate-arange-section"));
517+
Args.MakeArgString("-plugin-opt=-generate-arange-section"));
518518
}
519519

520520
// Try to pass driver level flags relevant to LTO code generation down to

clang/test/Driver/debug-options-aranges.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@
33
/// Check that the linker plugin will get -generate-arange-section.
44
// RUN: %clang -### -g --target=x86_64-linux -flto -gdwarf-aranges %s 2>&1 | FileCheck %s
55
// RUN: %clang -### -g --target=x86_64-linux -flto=thin -gdwarf-aranges %s 2>&1 | FileCheck %s
6-
// CHECK: --plugin-opt=-generate-arange-section
6+
// CHECK: "-plugin-opt=-generate-arange-section"

0 commit comments

Comments
 (0)