Home | History | Annotate | Download | only in Analysis

Lines Matching refs:Cost

1 //===- CostModel.cpp ------ Cost Model Analysis ---------------------------===//
10 // This file defines the cost model analysis. It provides a very basic cost
12 // to approximate the cost of any IR instruction when lowered to machine
13 // instructions. The cost results are unit-less and the cost number represents
15 // branches are predicted, etc. The cost numbers can be added in order to
20 #define CM_NAME "cost-model"
43 /// Returns the expected cost of the instruction.
44 /// Returns -1 if the cost is unknown.
45 /// Note, this method does not cache the cost calculation and it
63 static const char cm_name[] = "Cost Model Analysis";
216 unsigned Cost = getInstructionCost(Inst);
217 if (Cost != (unsigned)-1)
218 OS << "Cost Model: Found an estimated cost of " << Cost;
220 OS << "Cost Model: Unknown cost";