[PATCH] D120650: [ELF] Don't use multiple inheritance for OutputSection. NFC
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 28 01:36:25 PST 2022
MaskRay created this revision.
MaskRay added reviewers: ikudrin, peter.smith.
Herald added subscribers: arichardson, emaste.
MaskRay requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Add an OutputDesc class inheriting from SectionCommand. An OutputDesc wraps an
OutputSection.
With this change, we can inline InputSection::getParent.
My lld executable is 2KiB smaller.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D120650
Files:
lld/ELF/Driver.cpp
lld/ELF/ICF.cpp
lld/ELF/InputSection.cpp
lld/ELF/InputSection.h
lld/ELF/LinkerScript.cpp
lld/ELF/LinkerScript.h
lld/ELF/MapFile.cpp
lld/ELF/OutputSections.cpp
lld/ELF/OutputSections.h
lld/ELF/ScriptParser.cpp
lld/ELF/SyntheticSections.cpp
lld/ELF/Writer.cpp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D120650.411761.patch
Type: text/x-patch
Size: 23091 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220228/1a33a7b7/attachment.bin>
More information about the llvm-commits
mailing list