[PATCH] D94065: [NFC] Make remaining cost functions in LoopVectorize.cpp use InstructionCost

Caroline via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 5 04:08:23 PST 2021


CarolineConcatto added a comment.

Thank you David for this patch.
It looks all fine and the patch LGTM.
I have a question,  maybe out of the scope of this patch.
Can we also change LoopVectorizationCostModel::computePredInstDiscount to return InstructionCost as well?



================
Comment at: llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:4876
+  InstructionCost CallCost = Cost->getVectorCallCost(CI, VF, NeedToScalarize);
+  InstructionCost IntrinsicCost = InstructionCost::getInvalid();
+  if (ID)
----------------
Is it necessary to set IntrinsicCost here?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D94065



More information about the llvm-commits mailing list