Lines Matching defs:IRB
263 Value *memToShadow(Value *Shadow, IRBuilder<> &IRB);
322 Value *MemProfiler::memToShadow(Value *Shadow, IRBuilder<> &IRB) {
324 Shadow = IRB.CreateAnd(Shadow, Mapping.Mask);
325 Shadow = IRB.CreateLShr(Shadow, Mapping.Scale);
328 return IRB.CreateAdd(Shadow, DynamicShadowOffset);
333 IRBuilder<> IRB(MI);
335 IRB.CreateCall(isa<MemMoveInst>(MI) ? MemProfMemmove : MemProfMemcpy,
337 IRB.CreateIntCast(MI->getOperand(2), IntptrTy, false)});
339 IRB.CreateCall(
342 IRB.CreateIntCast(MI->getOperand(1), IRB.getInt32Ty(), false),
343 IRB.CreateIntCast(MI->getOperand(2), IntptrTy, false)});
462 IRBuilder<> IRB(I);
463 Value *MaskElem = IRB.CreateExtractElement(Mask, Idx);
468 IRBuilder<> IRB(InsertBefore);
470 IRB.CreateGEP(VTy, Addr, {Zero, ConstantInt::get(IntptrTy, Idx)});
505 IRBuilder<> IRB(InsertBefore);
506 Value *AddrLong = IRB.CreatePointerCast(Addr, IntptrTy);
509 IRB.CreateCall(MemProfMemoryAccessCallback[IsWrite], AddrLong);
516 Value *ShadowPtr = memToShadow(AddrLong, IRB);
517 Value *ShadowAddr = IRB.CreateIntToPtr(ShadowPtr, ShadowPtrTy);
518 Value *ShadowValue = IRB.CreateLoad(ShadowTy, ShadowAddr);
522 Value *Cmp = IRB.CreateICmpULT(ShadowValue, MaxCount);
525 IRB.SetInsertPoint(IncBlock);
528 ShadowValue = IRB.CreateAdd(ShadowValue, Inc);
529 IRB.CreateStore(ShadowValue, ShadowAddr);
607 IRBuilder<> IRB(*C);
616 FunctionType::get(IRB.getVoidTy(), Args1, false));
624 PtrTy, IRB.getInt32Ty(), IntptrTy);
638 IRBuilder<> IRB(&F.front(), F.front().begin());
639 IRB.CreateCall(MemProfInitFunction, {});
646 IRBuilder<> IRB(&F.front().front());
651 DynamicShadowOffset = IRB.CreateLoad(IntptrTy, GlobalDynamicAddress);