[llvm] [VPlan] First step towards VPlan cost modeling. (PR #92555)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 7 11:39:41 PDT 2024
================
@@ -920,6 +980,13 @@ void VPlan::execute(VPTransformState *State) {
"DT not preserved correctly");
}
+InstructionCost VPlan::cost(ElementCount VF, VPCostContext &Ctx) {
+ InstructionCost Cost = 0;
+ for (VPBlockBase *Block : vp_depth_first_shallow(getEntry()))
+ Cost += Block->cost(VF, Ctx);
+ return Cost;
----------------
fhahn wrote:
Updated, thanks!
https://github.com/llvm/llvm-project/pull/92555
More information about the llvm-commits
mailing list