Handle out-of-order COMDAT second symbols. In llvm codegen, the second symbol of COMDAT sequence always follows the first symbol in the global symbol list. But, when the object file came from MSVC compiler, these can come in out of order.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
Oh, good catch! Thanks
llvm/lib/ExecutionEngine/JITLink/COFFLinkGraphBuilder.cpp | ||
---|---|---|
524 | Shouldn't this assign to PendingComdatExports[Symbol.getSectionNumber()] now? |
llvm/lib/ExecutionEngine/JITLink/COFFLinkGraphBuilder.cpp | ||
---|---|---|
524 | good catch! it miraclely built succesfully as variable with the same name was introduced. |
llvm/lib/ExecutionEngine/JITLink/COFFLinkGraphBuilder.cpp | ||
---|---|---|
524 | For clearness, I changed PendinComdatExport to reference so that original node will be just set None. |
Comment Actions
LGTM.
llvm/lib/ExecutionEngine/JITLink/COFFLinkGraphBuilder.cpp | ||
---|---|---|
193 | What's the maximum number of sections in a COFF object? Could this get large for pathological objects? (In which case a DenseMap<SectionIndex, ComdatExportRequest> might be better?) |
What's the maximum number of sections in a COFF object? Could this get large for pathological objects? (In which case a DenseMap<SectionIndex, ComdatExportRequest> might be better?)