This patch follows D89322 to add an initial skeleton of vplan-based cost model.
This difference is that instead of incorporating a cost() interface to VPRecipes,
all cost implementations are put together in VPlanCostModel.
This allows VPlanCostModel to concentrate on assigning costs to vplan,
thus seprating the cost model code from the vplan IR, similar to LLVM IR cost
modeling.
During the transition, it will still use the legacy model to obtain cost until
all cost calculation for recipes are implemented.
Please let me know if you agree with the main idea of this patch.
If there is a general consensus, I'll proceed to implement the cost for the
other recipes for review.
It's costly to create this object in every inner loop.
This should either be hoisted to the outer loop, or outside of the loop altogether if you allow expectedCost to have the Plan as an argument, since it's the only function in VPlanCostModel that uses it.