[PATCH] D92174: [VE] Optimize emitSPAdjustment function

Simon Moll via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Nov 26 06:54:03 PST 2020


simoll added inline comments.


================
Comment at: llvm/lib/Target/VE/VEFrameLowering.cpp:231
+  if (NumBytes == 0) {
+    // Nothin to do here.
+  } else if (isInt<7>(NumBytes)) {
----------------
typo: Nothing


================
Comment at: llvm/lib/Target/VE/VEFrameLowering.cpp:232-243
+  } else if (isInt<7>(NumBytes)) {
+    // adds.l %s11, NumBytes at lo, %s11
     BuildMI(MBB, MBBI, DL, TII.get(VE::ADDSLri), VE::SX11)
         .addReg(VE::SX11)
         .addImm(NumBytes);
-    return;
+  } else if (isInt<32>(NumBytes)) {
+    // lea %s11, NumBytes at lo(, %s11)
----------------
Consider factoring this into a separate "`LoadImm`" function.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D92174/new/

https://reviews.llvm.org/D92174



More information about the llvm-commits mailing list