[llvm] r350144 - [WebAssembly] Fix comments in ExplicitLocals (NFC)

Heejin Ahn via llvm-commits llvm-commits at lists.llvm.org
Fri Dec 28 18:42:04 PST 2018


Author: aheejin
Date: Fri Dec 28 18:42:04 2018
New Revision: 350144

URL: http://llvm.org/viewvc/llvm-project?rev=350144&view=rev
Log:
[WebAssembly] Fix comments in ExplicitLocals (NFC)

Modified:
    llvm/trunk/lib/Target/WebAssembly/WebAssemblyExplicitLocals.cpp

Modified: llvm/trunk/lib/Target/WebAssembly/WebAssemblyExplicitLocals.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/WebAssembly/WebAssemblyExplicitLocals.cpp?rev=350144&r1=350143&r2=350144&view=diff
==============================================================================
--- llvm/trunk/lib/Target/WebAssembly/WebAssemblyExplicitLocals.cpp (original)
+++ llvm/trunk/lib/Target/WebAssembly/WebAssemblyExplicitLocals.cpp Fri Dec 28 18:42:04 2018
@@ -234,7 +234,7 @@ bool WebAssemblyExplicitLocals::runOnMac
         continue;
 
       // Replace tee instructions with tee_local. The difference is that tee
-      // instructins have two defs, while tee_local instructions have one def
+      // instructions have two defs, while tee_local instructions have one def
       // and an index of a local to write to.
       if (WebAssembly::isTee(MI)) {
         assert(MFI.isVRegStackified(MI.getOperand(0).getReg()));
@@ -296,8 +296,9 @@ bool WebAssemblyExplicitLocals::runOnMac
                 .addReg(NewReg);
           }
           MI.getOperand(0).setReg(NewReg);
-          // This register operand is now being used by the inserted drop
-          // instruction, so make it undead.
+          // This register operand of the original instruction is now being used
+          // by the inserted drop or set_local instruction, so make it not dead
+          // yet.
           MI.getOperand(0).setIsDead(false);
           MFI.stackifyVReg(NewReg);
           Changed = true;




More information about the llvm-commits mailing list