[clang] 922bf57 - [Driver][Gnu] Delete unneeded -Bstatic dispatch for arm/thumb
Fangrui Song via cfe-commits
cfe-commits at lists.llvm.org
Tue Oct 19 15:24:12 PDT 2021
Author: Fangrui Song
Date: 2021-10-19T15:24:07-07:00
New Revision: 922bf57fc8fe41ebcbbe581a7c8e730fbebf572f
URL: https://github.com/llvm/llvm-project/commit/922bf57fc8fe41ebcbbe581a7c8e730fbebf572f
DIFF: https://github.com/llvm/llvm-project/commit/922bf57fc8fe41ebcbbe581a7c8e730fbebf572f.diff
LOG: [Driver][Gnu] Delete unneeded -Bstatic dispatch for arm/thumb
Historically -static and -Bstatic are synonym.
gold made the semantics of -static slightly stronger but that does not matter.
Added:
Modified:
clang/lib/Driver/ToolChains/Gnu.cpp
Removed:
################################################################################
diff --git a/clang/lib/Driver/ToolChains/Gnu.cpp b/clang/lib/Driver/ToolChains/Gnu.cpp
index 2b5c34b9a63d..e599f5d2a53e 100644
--- a/clang/lib/Driver/ToolChains/Gnu.cpp
+++ b/clang/lib/Driver/ToolChains/Gnu.cpp
@@ -477,11 +477,7 @@ void tools::gnutools::Linker::ConstructJob(Compilation &C, const JobAction &JA,
CmdArgs.push_back("-shared");
if (IsStatic) {
- if (Arch == llvm::Triple::arm || Arch == llvm::Triple::armeb ||
- Arch == llvm::Triple::thumb || Arch == llvm::Triple::thumbeb)
- CmdArgs.push_back("-Bstatic");
- else
- CmdArgs.push_back("-static");
+ CmdArgs.push_back("-static");
} else {
if (Args.hasArg(options::OPT_rdynamic))
CmdArgs.push_back("-export-dynamic");
More information about the cfe-commits
mailing list