[PATCH] D85062: [WebAssembly] GC constructor functions in otherwise unused objects

Sam Clegg via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 31 17:39:40 PDT 2020


sbc100 added a comment.

To be clear this change only relates to object files at are part of `ar` archives and are not part of the link?     Perhaps mention that in the PR title/description.



================
Comment at: lld/wasm/InputFiles.h:103
+    if (archiveName.empty())
+      markLive();
   }
----------------
My understanding is that any file that is created as an ObjFile is by definition live. and that all files in `symtab->objectFiles` are also by definition live.

Archive files don't create any `ObjFile`s until they are pulled into the link for some reason (i.e. they are live).

What am I missing here?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D85062/new/

https://reviews.llvm.org/D85062



More information about the llvm-commits mailing list