diff options
| author | Tobias Grosser <tobias@grosser.es> | 2015-05-27 05:16:57 +0000 |
|---|---|---|
| committer | Tobias Grosser <tobias@grosser.es> | 2015-05-27 05:16:57 +0000 |
| commit | 7c3bad52dd0bab7e4e9c14e4d21fff0b8d530a29 (patch) | |
| tree | 9596d713f677ceb8f50a712a7a020496d4351d8c /polly/lib/CodeGen/IRBuilder.cpp | |
| parent | aa9fa355559c24b18f9e05f0c26b98feba5ba34d (diff) | |
| download | bcm5719-llvm-7c3bad52dd0bab7e4e9c14e4d21fff0b8d530a29.tar.gz bcm5719-llvm-7c3bad52dd0bab7e4e9c14e4d21fff0b8d530a29.zip | |
Use value semantics for list of ScopStmt(s) instead of std::owningptr
David Blaike suggested this as an alternative to the use of owningptr(s) for our
memory management, as value semantics allow to avoid the additional interface
complexity caused by owningptr while still providing similar memory consistency
guarantees. We could also have used a std::vector, but the use of std::vector
would yield possibly changing pointers which currently causes problems as for
example the memory accesses carry pointers to their parent statements. Such
pointers should not change.
Reviewer: jblaikie, jdoerfert
Differential Revision: http://reviews.llvm.org/D10041
llvm-svn: 238290
Diffstat (limited to 'polly/lib/CodeGen/IRBuilder.cpp')
| -rw-r--r-- | polly/lib/CodeGen/IRBuilder.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/polly/lib/CodeGen/IRBuilder.cpp b/polly/lib/CodeGen/IRBuilder.cpp index ff1ba1bffba..65f6fe84fb7 100644 --- a/polly/lib/CodeGen/IRBuilder.cpp +++ b/polly/lib/CodeGen/IRBuilder.cpp @@ -59,8 +59,8 @@ void ScopAnnotator::buildAliasScopes(Scop &S) { OtherAliasScopeListMap.clear(); SetVector<Value *> BasePtrs; - for (auto &Stmt : S) - for (MemoryAccess *MA : *Stmt) + for (ScopStmt &Stmt : S) + for (MemoryAccess *MA : Stmt) BasePtrs.insert(MA->getBaseAddr()); std::string AliasScopeStr = "polly.alias.scope."; |

