[PATCH] D51376: ELF: Don't examine values of linker script symbols during ICF.

Rui Ueyama via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 29 01:22:40 PDT 2018


ruiu accepted this revision.
ruiu added a comment.

LGTM



================
Comment at: lld/ELF/ICF.cpp:255
     auto *DB = dyn_cast<Defined>(&SB);
-    if (!DA || !DB)
+    if (!DA || !DB || DA->ScriptDefined || DB->ScriptDefined)
       return false;
----------------
Please add a comment saying that linker-script-generated placeholder symbols look the same at this moment but they would have different values later.


Repository:
  rL LLVM

https://reviews.llvm.org/D51376





More information about the llvm-commits mailing list