[PATCH] D65338: [MemorySSA] Extend allowed behavior for simplified instructions.
George Burgess IV via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 29 22:15:49 PDT 2019
george.burgess.iv added a comment.
Thanks for this! Two nits and a question
================
Comment at: lib/Analysis/MemorySSAUpdater.cpp:487
bool CloneWasSimplified) {
- auto GetNewDefiningAccess = [&](MemoryAccess *MA) -> MemoryAccess * {
+ std::function<MemoryAccess *(MemoryAccess *)> GetNewDefiningAccess =
+ [&](MemoryAccess *MA) -> MemoryAccess * {
----------------
nit: if it's straightforward to turn this into a `static` helper, please do so.
================
Comment at: lib/Analysis/MemorySSAUpdater.cpp:538
CloneWasSimplified ? nullptr : MUD);
- MSSA->insertIntoListsForBlock(NewUseOrDef, NewBB, MemorySSA::End);
+ if (NewUseOrDef)
+ MSSA->insertIntoListsForBlock(NewUseOrDef, NewBB, MemorySSA::End);
----------------
`NewUseOrDef` should always be non-null, no?
================
Comment at: test/Analysis/MemorySSA/loop-rotate-simplified-clone.ll:2
+; RUN: opt -verify-memoryssa -enable-mssa-loop-dependency -loop-rotate %s -S | FileCheck %s
+
+; CHECK-LABEL: @test()
----------------
`; REQUIRES: asserts`
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65338/new/
https://reviews.llvm.org/D65338
More information about the llvm-commits
mailing list