Merge SymbolBody and Symbol into one class, SymbolBody.
authorRui Ueyama <ruiu@google.com>
Tue, 31 Oct 2017 16:07:41 +0000 (16:07 +0000)
committerRui Ueyama <ruiu@google.com>
Tue, 31 Oct 2017 16:07:41 +0000 (16:07 +0000)
commitf1f00841d9846acbdd4a4f7f8a1c60bb3079541d
tree2e211b5348c52c40a259334f56b0cd65e595e916
parentf3c33ca83eb6d0ac09123ec862f3ea25e59c2dcd
Merge SymbolBody and Symbol into one class, SymbolBody.

SymbolBody and Symbol were separated classes due to a historical reason.
Symbol used to be a pointer to a SymbolBody, and the relationship
between Symbol and SymbolBody was n:1.

r2681780 changed that. Since that patch, SymbolBody and Symbol are
allocated next to each other to improve memory locality, and they have
1:1 relationship now. So, the separation of Symbol and SymbolBody no
longer makes sense.

This patch merges them into one class. In order to avoid updating too
many places, I chose SymbolBody as a unified name. I'll rename it Symbol
in a follow-up patch.

Differential Revision: https://reviews.llvm.org/D39406

llvm-svn: 317006
14 files changed:
lld/ELF/Config.h
lld/ELF/Driver.cpp
lld/ELF/InputFiles.cpp
lld/ELF/LTO.cpp
lld/ELF/LinkerScript.cpp
lld/ELF/MarkLive.cpp
lld/ELF/Relocations.cpp
lld/ELF/SymbolTable.cpp
lld/ELF/SymbolTable.h
lld/ELF/Symbols.cpp
lld/ELF/Symbols.h
lld/ELF/SyntheticSections.cpp
lld/ELF/Writer.cpp
lld/docs/NewLLD.rst