[PATCH] D122784: Add back ignored option --no-add-needed

Tom Stellard via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 30 23:56:57 PDT 2022


tstellar created this revision.
tstellar added a reviewer: MaskRay.
Herald added subscribers: StephenFan, arichardson, emaste.
Herald added a project: All.
tstellar requested review of this revision.
Herald added a project: LLVM.

This partially reverts commit 815a1207bfe121c8dcf3804a4f4638e580f63519 <https://reviews.llvm.org/rG815a1207bfe121c8dcf3804a4f4638e580f63519>.
gcc 12.0.1 passes this option to the linker when compiling with -fuse-ld=lld.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D122784

Files:
  lld/ELF/Options.td
  lld/test/ELF/silent-ignore.test


Index: lld/test/ELF/silent-ignore.test
===================================================================
--- lld/test/ELF/silent-ignore.test
+++ lld/test/ELF/silent-ignore.test
@@ -4,6 +4,7 @@
 RUN:   -detect-odr-violations \
 RUN:   -g \
 RUN:   -long-plt \
+RUN:   -no-add-needed \
 RUN:   -no-copy-dt-needed-entries \
 RUN:   -no-ctors-in-init-array \
 RUN:   -no-keep-memory \
Index: lld/ELF/Options.td
===================================================================
--- lld/ELF/Options.td
+++ lld/ELF/Options.td
@@ -692,6 +692,7 @@
 def: Flag<["-"], "dc">;
 def: Flag<["-"], "g">;
 def: F<"long-plt">;
+def: F<"no-add-needed">;
 def: F<"no-copy-dt-needed-entries">;
 def: F<"no-ctors-in-init-array">;
 def: F<"no-keep-memory">;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D122784.419340.patch
Type: text/x-patch
Size: 739 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220331/de49d0f9/attachment.bin>


More information about the llvm-commits mailing list