HomePhabricator

[MemCpyOpt] Fix MemorySSA preservation

Authored by nikic on Sat, Oct 3, 2:26 AM.

Description

[MemCpyOpt] Fix MemorySSA preservation

moveUp() moves instructions, so we should move the corresponding
memory accesses as well. We should also move the store instruction
itself: Even though we'll end up removing it later, this gives us
a correct MemoryDef to replace.

The implementation is somewhat more complicated than it should be,
because we also handle the case where P does not have a memory
access due to a degnerate AA pipeline. Hopefully, the need for this
will go away in the future, when the rest of the pass is based on
MSSA.

Differential Revision: https://reviews.llvm.org/D88778

Details

Committed
nikicTue, Oct 13, 12:39 PM
Differential Revision
D88778: [MemCpyOpt] Fix MemorySSA preservation
Parents
rG0ec1cf13f2a4: Revert "DirectoryWatcher: add an implementation for Windows"
Branches
Unknown
Tags
Unknown