[llvm] [lld] [llvm-readobj][Object][COFF] Print COFF import library symbol export name. (PR #78769)

Martin Storsjö via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 5 14:35:21 PST 2024


mstorsjo wrote:

> > Is `IMPORT_NAME_NOPREFIX` logic restricted to i386 (which actually uses `_@?`?
> 
> It is restricted on writer side, in tools that create import libraries (so I wouldn't expect such import libraries to be actually used). Both ignoring it on non-i386 and not restricting it would seem fine to me. LLD, when it parses import libraries in `ImportFile::parse`, doesn't restrict `IMPORT_NAME_NOPREFIX` to i386, so I did the same here.

I think this is fine, I don't think we need to explicitly restrict the handling of this case to i386 - if one crafts an import library for another architecture that says `NOPREFIX`, I think it is fine to try to run that logic.

https://github.com/llvm/llvm-project/pull/78769


More information about the llvm-commits mailing list