MC: Merge MCSymbol and MCSymbolData
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>
Sat, 16 May 2015 00:03:06 +0000 (00:03 +0000)
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>
Sat, 16 May 2015 00:03:06 +0000 (00:03 +0000)
commitc5f2ba0401433a191328fd110decba78f6c5482c
tree38b02f2c17d37c4f5a1c3619fa8f817f93eb5293
parentb42b9f8563918ab65d7db01ba116866fffa80a0a
MC: Merge MCSymbol and MCSymbolData

Turn `MCSymbolData` into a field inside of `MCSymbol`.  Keep all the old
API alive for now, so that consumers can be updated in a later commit.
This means we still temporarily need the back pointer from
`MCSymbolData` to `MCSymbol`, but I'll remove it in a follow-up.

This optimizes for object emission over assembly emission.  By removing
the `DenseMap` in `MCAssembler`, llc memory usage drops from around 1040
MB to 1001 MB (3.8%).

(I'm looking at `llc` memory usage on `verify-uselistorder.lto.opt.bc`;
see r236629 for details.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@237490 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/MC/MCAssembler.h
include/llvm/MC/MCSymbol.h
lib/MC/MCAssembler.cpp