Searched refs:WeightsNode (Results 1 – 6 of 6) sorted by relevance
157 MDNode *WeightsNode = TI->getMetadata(LLVMContext::MD_prof);158 if (!WeightsNode)161 MDString *MDName = cast<MDString>(WeightsNode->getOperand(0));166 if (OpNo >= WeightsNode->getNumOperands())169 mdconst::dyn_extract<ConstantInt>(WeightsNode->getOperand(OpNo));
73 MDNode *WeightsNode = llvm::MDNode::get(Context, Vec); in HandleSwitchExpect() local74 SI->setMetadata(LLVMContext::MD_prof, WeightsNode); in HandleSwitchExpect()119 MDNode *WeightsNode = MDNode::get(Context, Ops); in HandleIfExpect() local120 BI->setMetadata(LLVMContext::MD_prof, WeightsNode); in HandleIfExpect()
153 MDNode *WeightsNode = TI->getMetadata(LLVMContext::MD_prof); in calcMetadataWeights() local154 if (!WeightsNode) in calcMetadataWeights()159 if (WeightsNode->getNumOperands() != TI->getNumSuccessors() + 1) in calcMetadataWeights()168 for (unsigned i = 1, e = WeightsNode->getNumOperands(); i != e; ++i) { in calcMetadataWeights()169 ConstantInt *Weight = dyn_cast<ConstantInt>(WeightsNode->getOperand(i)); in calcMetadataWeights()
189 MDNode *WeightsNode = TI->getMetadata(LLVMContext::MD_prof); in calcMetadataWeights() local190 if (!WeightsNode) in calcMetadataWeights()198 if (WeightsNode->getNumOperands() != TI->getNumSuccessors() + 1) in calcMetadataWeights()207 for (unsigned i = 1, e = WeightsNode->getNumOperands(); i != e; ++i) { in calcMetadataWeights()209 mdconst::dyn_extract<ConstantInt>(WeightsNode->getOperand(i)); in calcMetadataWeights()
254 MDNode *WeightsNode = TI->getMetadata(LLVMContext::MD_prof); in calcMetadataWeights() local255 if (!WeightsNode) in calcMetadataWeights()263 if (WeightsNode->getNumOperands() != TI->getNumSuccessors() + 1) in calcMetadataWeights()274 for (unsigned i = 1, e = WeightsNode->getNumOperands(); i != e; ++i) { in calcMetadataWeights()276 mdconst::dyn_extract<ConstantInt>(WeightsNode->getOperand(i)); in calcMetadataWeights()
2116 MDNode *WeightsNode = TI->getMetadata(LLVMContext::MD_prof); in doesBlockHaveProfileData() local2117 if (!WeightsNode) in doesBlockHaveProfileData()2120 MDString *MDName = cast<MDString>(WeightsNode->getOperand(0)); in doesBlockHaveProfileData()2126 return WeightsNode->getNumOperands() == TI->getNumSuccessors() + 1; in doesBlockHaveProfileData()