[PATCH] D25912: [PowerPC] Improvements for BUILD_VECTOR Vol. 1
Eric Christopher via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 31 14:38:53 PDT 2016
echristo added inline comments.
================
Comment at: lib/Target/PowerPC/PPCISelLowering.cpp:7214-7217
+ auto haveEfficientPattern = [&](BuildVectorSDNode *V) -> bool {
+ bool IsSplat = true;
+ bool IsLoad = false;
+ SDValue Op0 = V->getOperand(0);
----------------
nemanjai wrote:
> amehsan wrote:
> > Do we need a lambda that is called only once? Since this function is very long already, I think creating a separate function for this is reasonable to avoid making this function too long.
> I only added a lambda for two reasons:
> 1. The logic is very close to where it's used
> 2. The logic isn't needed anywhere else
>
> But I really don't feel strongly about that reasoning and would be happy to change it to a function if that's what is preferred. What do the others think?
No strong opinion here. I'm slightly more likely to want to outline code because it is a very long function, but no strong opinion.
Repository:
rL LLVM
https://reviews.llvm.org/D25912
More information about the llvm-commits
mailing list