[PATCH] D51015: [MemorySSA] Make the Updater movable.

Alina Sbirlea via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 20 16:44:59 PDT 2018


asbirlea created this revision.
asbirlea added reviewers: george.burgess.iv, chandlerc.
Herald added subscribers: Prazek, jlebar, sanjoy.

Make the MemorySSAUpdater movable.


Repository:
  rL LLVM

https://reviews.llvm.org/D51015

Files:
  include/llvm/Analysis/MemorySSAUpdater.h


Index: include/llvm/Analysis/MemorySSAUpdater.h
===================================================================
--- include/llvm/Analysis/MemorySSAUpdater.h
+++ include/llvm/Analysis/MemorySSAUpdater.h
@@ -70,6 +70,12 @@
 
 public:
   MemorySSAUpdater(MemorySSA *MSSA) : MSSA(MSSA) {}
+  MemorySSAUpdater(MemorySSAUpdater &&MSSAU) : MSSA(MSSAU.MSSA) {}
+  MemorySSAUpdater& operator=(MemorySSAUpdater&& MSSAU) {
+    MSSA = MSSAU.MSSA;
+    MSSAU.MSSA = 0;
+    return *this;
+  }
   /// Insert a definition into the MemorySSA IR.  RenameUses will rename any use
   /// below the new def block (and any inserted phis).  RenameUses should be set
   /// to true if the definition may cause new aliases for loads below it.  This


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D51015.161618.patch
Type: text/x-patch
Size: 730 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180820/b626d9ac/attachment.bin>


More information about the llvm-commits mailing list