[PATCH] D119909: [ELF] Parallelize initializeLocalSymbols
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 23 21:42:45 PST 2022
MaskRay marked an inline comment as done.
MaskRay added inline comments.
================
Comment at: lld/ELF/InputFiles.cpp:1160
+
+void elf::initializeLocalSymbols(ELFFileBase *file) {
+ switch (config->ekind) {
----------------
ikudrin wrote:
> `initializeLocalSymbols()` is very similar to `postParseObjectFile()` from D119908. I believe they should be defined in the same way: both in `InputFiles.cpp` after methods they call or both in `Driver.cpp`, as static functions before `LinkerDriver::link()`.
> Technically the new function initializeLocalSymbols can be merged into ObjFile::postParse, but functions like getSrcMsg may access the uninitialized (all nullptr) local part of InputFile::symbols.
Combing will cause null pointer reference for some diagnostics.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D119909/new/
https://reviews.llvm.org/D119909
More information about the llvm-commits
mailing list