[llvm] r174743 - BBVectorize: Use TTI->getAddressComputationCost

Hal Finkel hfinkel at anl.gov
Fri Feb 8 13:50:43 PST 2013


----- Original Message -----
> From: "Renato Golin" <renato.golin at linaro.org>
> To: "Hal Finkel" <hfinkel at anl.gov>
> Cc: "llvm-commits at cs.uiuc.edu for LLVM" <llvm-commits at cs.uiuc.edu>
> Sent: Friday, February 8, 2013 3:40:01 PM
> Subject: Re: [llvm] r174743 - BBVectorize: Use TTI->getAddressComputationCost
> 
> 
> 
> Hi Hal, I can have a look at it next week, I will ping you to know
> what exactly do you need.
> 
> Btw, whenever you need something ARM related, feel free to copy me.

Thanks, will do!

 -Hal

> 
> Cheers,
> Renato
> On 8 Feb 2013 21:33, "Hal Finkel" < hfinkel at anl.gov > wrote:
> 
> 
> Author: hfinkel
> Date: Fri Feb 8 15:13:39 2013
> New Revision: 174743
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=174743&view=rev
> Log:
> BBVectorize: Use TTI->getAddressComputationCost
> 
> This is a follow-up to the cost-model change in r174713 which splits
> the cost of a memory operation between the address computation and
> the
> actual memory access. In r174713, this cost is always added to the
> memory operation cost, and so BBVectorize will do the same.
> 
> Currently, this new cost function is used only by ARM, and I don't
> have any ARM test cases for BBVectorize. Assistance in generating
> some
> good ARM test cases for BBVectorize would be greatly appreciated!
> 
> Modified:
> llvm/trunk/lib/Transforms/Vectorize/BBVectorize.cpp
> 
> Modified: llvm/trunk/lib/Transforms/Vectorize/BBVectorize.cpp
> URL:
> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Vectorize/BBVectorize.cpp?rev=174743&r1=174742&r2=174743&view=diff
> ==============================================================================
> --- llvm/trunk/lib/Transforms/Vectorize/BBVectorize.cpp (original)
> +++ llvm/trunk/lib/Transforms/Vectorize/BBVectorize.cpp Fri Feb 8
> 15:13:39 2013
> @@ -972,6 +972,11 @@ namespace {
> unsigned VCost = TTI->getMemoryOpCost(I->getOpcode(), VType,
> BottomAlignment,
> IAddressSpace);
> +
> + ICost += TTI->getAddressComputationCost(aTypeI);
> + JCost += TTI->getAddressComputationCost(aTypeJ);
> + VCost += TTI->getAddressComputationCost(VType);
> +
> if (VCost > ICost + JCost)
> return false;
> 
> 
> 
> _______________________________________________
> 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