[PATCH] D131034: [Backend][X86] Improved tail call optimization for functions marked as musttail

William Junda Huang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 4 12:57:55 PDT 2022


huangjd added inline comments.


================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:4314
   int FPDiff = 0;
-  if (isTailCall &&
+  if (isTailCall && !IsSibcall &&
       shouldGuaranteeTCO(CallConv,
----------------
davidxl wrote:
> what is this change for?
Sibcall should not adjust stack because all arguments are already in place. This is previously causing the bug I posted on github 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D131034



More information about the llvm-commits mailing list