Lines Matching defs:MIB
80 MDNode *llvm::memprof::getMIBStackNode(const MDNode *MIB) {
81 assert(MIB->getNumOperands() >= 2);
82 // The stack metadata is the first operand of each memprof MIB metadata.
83 return cast<MDNode>(MIB->getOperand(0));
86 AllocationType llvm::memprof::getMIBAllocType(const MDNode *MIB) {
87 assert(MIB->getNumOperands() >= 2);
89 // MIB metadata. This will need to change as we add additional allocation
91 auto *MDS = dyn_cast<MDString>(MIB->getOperand(1));
101 uint64_t llvm::memprof::getMIBTotalSize(const MDNode *MIB) {
102 if (MIB->getNumOperands() < 3)
104 return mdconst::dyn_extract<ConstantInt>(MIB->getOperand(2))->getZExtValue();
173 void CallStackTrie::addCallStack(MDNode *MIB) {
174 MDNode *StackMD = getMIBStackNode(MIB);
183 addCallStack(getMIBAllocType(MIB), CallStack, getMIBTotalSize(MIB));
207 // Add an MIB record for the current call stack prefix.
251 // Build and attach the minimal necessary MIB metadata. If the alloc has a