diff options
author | George Burgess IV <george.burgess.iv@gmail.com> | 2017-04-21 04:54:52 +0000 |
---|---|---|
committer | George Burgess IV <george.burgess.iv@gmail.com> | 2017-04-21 04:54:52 +0000 |
commit | 56169ed753fb1a6ae3cc6231b1e9ed024c0c6b00 (patch) | |
tree | c10ceec1e9370091187f847fbf3365a218968b30 /llvm/lib/Analysis/MemorySSAUpdater.cpp | |
parent | fa15de34b7a837619fd651af2021dc867175e336 (diff) | |
download | bcm5719-llvm-56169ed753fb1a6ae3cc6231b1e9ed024c0c6b00.tar.gz bcm5719-llvm-56169ed753fb1a6ae3cc6231b1e9ed024c0c6b00.zip |
[MSSA] Clean up the updater a bit. NFC
- Mark an internal function static
- Remove the llvm namespace (just holding on to the `using namespace
llvm;` Works on My Machine(TM))
llvm-svn: 300947
Diffstat (limited to 'llvm/lib/Analysis/MemorySSAUpdater.cpp')
-rw-r--r-- | llvm/lib/Analysis/MemorySSAUpdater.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/llvm/lib/Analysis/MemorySSAUpdater.cpp b/llvm/lib/Analysis/MemorySSAUpdater.cpp index c63677fe550..da5c79ab6c8 100644 --- a/llvm/lib/Analysis/MemorySSAUpdater.cpp +++ b/llvm/lib/Analysis/MemorySSAUpdater.cpp @@ -29,7 +29,7 @@ #define DEBUG_TYPE "memoryssa" using namespace llvm; -namespace llvm { + // This is the marker algorithm from "Simple and Efficient Construction of // Static Single Assignment Form" // The simple, non-marker algorithm places phi nodes at any join @@ -211,8 +211,8 @@ void MemorySSAUpdater::insertUse(MemoryUse *MU) { } // Set every incoming edge {BB, MP->getBlock()} of MemoryPhi MP to NewDef. -void setMemoryPhiValueForBlock(MemoryPhi *MP, const BasicBlock *BB, - MemoryAccess *NewDef) { +static void setMemoryPhiValueForBlock(MemoryPhi *MP, const BasicBlock *BB, + MemoryAccess *NewDef) { // Replace any operand with us an incoming block with the new defining // access. int i = MP->getBasicBlockIndex(BB); @@ -415,6 +415,7 @@ static MemoryAccess *onlySingleValue(MemoryPhi *MP) { } return MA; } + void MemorySSAUpdater::removeMemoryAccess(MemoryAccess *MA) { assert(!MSSA->isLiveOnEntryDef(MA) && "Trying to remove the live on entry def"); @@ -490,5 +491,3 @@ MemoryUseOrDef *MemorySSAUpdater::createMemoryAccessAfter( ++InsertPt->getIterator()); return NewAccess; } - -} // namespace llvm |