summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/MCObjectFileInfo.cpp
diff options
context:
space:
mode:
authorGeorge Burgess IV <george.burgess.iv@gmail.com>2016-07-20 19:51:34 +0000
committerGeorge Burgess IV <george.burgess.iv@gmail.com>2016-07-20 19:51:34 +0000
commit400ae40348096d6f3fb22a4c9df38be0de7d2af2 (patch)
tree522030490141683237439addac97ae7262af01c5 /llvm/lib/MC/MCObjectFileInfo.cpp
parentd8388aaecbefec83a2e900903c04a1e63ebcfedb (diff)
downloadbcm5719-llvm-400ae40348096d6f3fb22a4c9df38be0de7d2af2.tar.gz
bcm5719-llvm-400ae40348096d6f3fb22a4c9df38be0de7d2af2.zip
[MSSA] Add an overload for getClobberingMemoryAccess.
A seemingly common use for the walker's getClobberingMemoryAccess function is: ``` MemoryAccess *getClobber(MemorySSAWalker *W, MemoryUseOrDef *MUD) { const Instruction *I = MUD->getMemoryInst(); return W->getClobberingMemoryAccess(I); } ``` Which is kind of redundant, since walkers will ultimately query MSSA to find out which MemoryAccess `I` maps to (...which is always `MUD`). So, this patch adds an overload of getClobberingMemoryAccess that accepts MemoryAccesses directly. As a result, the Instruction overload of getClobberingMemoryAccess becomes a lightweight wrapper around our new overload. Additionally, this patch un`virtual`izes the Instruction overload of getClobberingMemoryAccess, since there doesn't seem to be a walker that benefits from that being virtual, and I can't think of how else one would implement it. Happy to make it virtual again if we would benefit from doing so. llvm-svn: 276169
Diffstat (limited to 'llvm/lib/MC/MCObjectFileInfo.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud