summaryrefslogtreecommitdiffstats
path: root/llvm/test
diff options
context:
space:
mode:
authorPavel Labath <labath@google.com>2018-07-20 15:24:13 +0000
committerPavel Labath <labath@google.com>2018-07-20 15:24:13 +0000
commit7f7e60694e37cef81423bf626950c59081c96b42 (patch)
tree5024dc2f082562c2d67a7069f108e411c023f5d5 /llvm/test
parent7c56bce996ff74a57e6536f2bb3c23612fd606fb (diff)
downloadbcm5719-llvm-7f7e60694e37cef81423bf626950c59081c96b42.tar.gz
bcm5719-llvm-7f7e60694e37cef81423bf626950c59081c96b42.zip
DwarfDebug: Reduce duplication in addAccel*** methods
Summary: Each of the four methods had a dozen lines and was doing almost exactly the same thing: get the appropriate accelerator table kind and insert an entry into it. I move this common logic to a helper function and make these methods delegate to it. This came up in the context of D49493, where I've needed to make adding a string to a string pool slightly more complicated, and it seemed to make sense to do it in one place instead of five. To make this work I've needed to unify the interface of the AccelTable data types, as some used to store DIE& and others DIE*. I chose to unify to a reference as that's what the caller uses. This technically isn't NFC, because it changes the StringPool used for apple tables in the DWO case (now it uses the main file like DWARF v5 instead of the DWO file). However, that shouldn't matter, as DWO is not a thing on apple targets (clang frontend simply ignores -gsplit-dwarf). Reviewers: JDevlieghere, aprantl, probinson Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D49542 llvm-svn: 337562
Diffstat (limited to 'llvm/test')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud