[llvm-commits] [llvm] r65289 - /llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp

Chris Lattner clattner at apple.com
Mon Feb 23 14:30:32 PST 2009


On Feb 22, 2009, at 10:06 AM, Dan Gohman wrote:

> Author: djg
> Date: Sun Feb 22 12:06:32 2009
> New Revision: 65289
>
> URL: http://llvm.org/viewvc/llvm-project?rev=65289&view=rev
> Log:
> Revert the part of 64623 that attempted to align the source in a
> memcpy to match the alignment of the destination. It isn't necessary
> for making loads and stores handled like the SSE loadu/storeu
> intrinsics, and it was causing a performance regression in
> MultiSource/Applications/JM/lencod.
>
> The problem appears to have been a memcpy that copies from some
> highly aligned array into an alloca; the alloca was then being
> assigned a large alignment, which required codegen to perform
> dynamic stack-pointer re-alignment, which forced the enclosing
> function to have a frame pointer, which led to increased spilling.

testcase?

-Chris

>
>
> Modified:
>    llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp
>
> Modified: llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp?rev=65289&r1=65288&r2=65289&view=diff
>
> =
> =
> =
> =
> =
> =
> =
> =
> ======================================================================
> --- llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp  
> (original)
> +++ llvm/trunk/lib/Transforms/Scalar/InstructionCombining.cpp Sun  
> Feb 22 12:06:32 2009
> @@ -9286,7 +9286,7 @@
>
> Instruction *InstCombiner::SimplifyMemTransfer(MemIntrinsic *MI) {
>   unsigned DstAlign = GetOrEnforceKnownAlignment(MI->getOperand(1));
> -  unsigned SrcAlign = GetOrEnforceKnownAlignment(MI->getOperand(2),  
> DstAlign);
> +  unsigned SrcAlign = GetOrEnforceKnownAlignment(MI->getOperand(2));
>   unsigned MinAlign = std::min(DstAlign, SrcAlign);
>   unsigned CopyAlign = MI->getAlignment()->getZExtValue();
>
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list