[llvm] [llvm-symbolizer] Recognize AIX big archive (PR #150401)
James Henderson via llvm-commits
llvm-commits at lists.llvm.org
Wed Oct 22 02:59:48 PDT 2025
================
@@ -557,57 +558,149 @@ LLVMSymbolizer::getOrCreateObjectPair(const std::string &Path,
if (!DbgObj)
DbgObj = Obj;
ObjectPair Res = std::make_pair(Obj, DbgObj);
- std::string DbgObjPath = DbgObj->getFileName().str();
auto Pair =
ObjectPairForPathArch.emplace(std::make_pair(Path, ArchName), Res);
- BinaryForPath.find(DbgObjPath)->second.pushEvictor([this, I = Pair.first]() {
- ObjectPairForPathArch.erase(I);
- });
+ std::string DbgObjPath = DbgObj->getFileName().str();
+ auto BinIter = BinaryForPath.find(DbgObjPath);
+ if (BinIter != BinaryForPath.end()) {
----------------
jh7370 wrote:
I've given it some more thought and I'm fairly convinced the problem is that you're storing the wrong thing in `BinaryForPath` when dealing with archive members. Specifically, this should store the final binary (i.e. the archive child binary) and should be keyed on `t.a(t.o)` (or equivalent).
This will require some reorganisation of the code from what you've done, so that `loadOrGetBinary` knows that it's expecting an archive and fetches the child out of that.
Does this make sense?
https://github.com/llvm/llvm-project/pull/150401
More information about the llvm-commits
mailing list