[PATCH] Include legalization cost when computing scalarization cost. When analyzing vectors of element type that require legalization, the legalization cost must be included to get an accurate estimation of the total cost of the scalarized vector. The...

Nadav Rotem nrotem at apple.com
Thu Mar 6 14:27:50 PST 2014


  +    }
  +    if (Extract) {
  +      Cost += LT.first *
  +              TopTTI->getVectorInstrCost(Instruction::ExtractElement, VecTy, i);

  I think that the type in this function call should be LT.second because we are evaluating the code of the legalized type.

http://llvm-reviews.chandlerc.com/D2992



More information about the llvm-commits mailing list