[llvm-commits] [llvm] r133858 - /llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
Eli Friedman
eli.friedman at gmail.com
Fri Jun 24 20:44:32 PDT 2011
On Fri, Jun 24, 2011 at 7:04 PM, Chad Rosier <mcrosier at apple.com> wrote:
> Author: mcrosier
> Date: Fri Jun 24 21:04:56 2011
> New Revision: 133858
>
> URL: http://llvm.org/viewvc/llvm-project?rev=133858&view=rev
> Log:
> Enable tail call optimization in the presence of a byval (x86-32 and x86-64).
> <rdar://problem/9483883>
>
> Modified:
> llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
>
> Modified: llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ISelLowering.cpp?rev=133858&r1=133857&r2=133858&view=diff
> ==============================================================================
> --- llvm/trunk/lib/Target/X86/X86ISelLowering.cpp (original)
> +++ llvm/trunk/lib/Target/X86/X86ISelLowering.cpp Fri Jun 24 21:04:56 2011
> @@ -2505,6 +2505,10 @@
> if (!FINode)
> return false;
> FI = FINode->getIndex();
> + } else if (Arg.getOpcode() == ISD::FrameIndex && Flags.isByVal()) {
> + FrameIndexSDNode *FINode = dyn_cast<FrameIndexSDNode>(Arg);
> + FI = FINode->getIndex();
> + Bytes = Flags.getByValSize();
> } else
> return false;
An interesting side-note: byval+tail calls was already partially
working, but before this commit it only worked outside the entry
block. :)
-Eli
More information about the llvm-commits
mailing list