[PATCH] D20263: X86: Avoid using _chkstk when lowering WIN_ALLOCA instructions

Michael Kuperstein via llvm-commits llvm-commits at lists.llvm.org
Fri May 13 17:24:54 PDT 2016


mkuper added inline comments.

================
Comment at: lib/Target/X86/X86WinAllocaExpander.cpp:197
@@ +196,3 @@
+  if (Amount != -1) {
+    assert((Amount % (Is64Bit ? 8 : 4) == 0) && "Stack would not be aligned!");
+  }
----------------
rnk wrote:
> Maybe cache `Is64Bit ? 8 : 4` as a `SlotSize` member variable. Also RAX as... some variable. RegA?
We can probably just query MRI for getSlotSize instead.



http://reviews.llvm.org/D20263





More information about the llvm-commits mailing list