Lines Matching refs:IRB
848 IRBuilder<> IRB(Pos); in runOnModule() local
849 Value *Ne = IRB.CreateICmpNE(V, DFSF.DFS.ZeroShadow); in runOnModule()
867 IRBuilder<> IRB(F->getEntryBlock().begin()); in getArgTLSPtr() local
868 return ArgTLSPtr = IRB.CreateCall(DFS.GetArgTLS); in getArgTLSPtr()
877 IRBuilder<> IRB(F->getEntryBlock().begin()); in getRetvalTLS() local
878 return RetvalTLSPtr = IRB.CreateCall(DFS.GetRetvalTLS); in getRetvalTLS()
882 IRBuilder<> IRB(Pos); in getArgTLS() local
883 return IRB.CreateConstGEP2_64(getArgTLSPtr(), 0, Idx); in getArgTLS()
900 IRBuilder<> IRB(ArgTLSPos); in getShadow() local
901 Shadow = IRB.CreateLoad(getArgTLS(A->getArgNo(), ArgTLSPos)); in getShadow()
930 IRBuilder<> IRB(Pos); in getShadowAddress() local
931 return IRB.CreateIntToPtr( in getShadowAddress()
932 IRB.CreateMul( in getShadowAddress()
933 IRB.CreateAnd(IRB.CreatePtrToInt(Addr, IntptrTy), ShadowPtrMask), in getShadowAddress()
973 IRBuilder<> IRB(Pos); in combineShadows() local
975 CallInst *Call = IRB.CreateCall2(DFS.DFSanCheckedUnionFn, V1, V2); in combineShadows()
984 Value *Ne = IRB.CreateICmpNE(V1, V2); in combineShadows()
1045 IRBuilder<> IRB(Pos); in loadShadow() local
1046 return IRB.CreateLoad(i->second); in loadShadow()
1077 IRBuilder<> IRB(Pos); in loadShadow() local
1078 Value *ShadowAddr1 = IRB.CreateGEP(DFS.ShadowTy, ShadowAddr, in loadShadow()
1080 return combineShadows(IRB.CreateAlignedLoad(ShadowAddr, ShadowAlign), in loadShadow()
1081 IRB.CreateAlignedLoad(ShadowAddr1, ShadowAlign), Pos); in loadShadow()
1096 IRBuilder<> IRB(Pos); in loadShadow() local
1098 IRB.CreateBitCast(ShadowAddr, Type::getInt64PtrTy(*DFS.Ctx)); in loadShadow()
1099 Value *WideShadow = IRB.CreateAlignedLoad(WideAddr, ShadowAlign); in loadShadow()
1100 Value *TruncShadow = IRB.CreateTrunc(WideShadow, DFS.ShadowTy); in loadShadow()
1101 Value *ShlShadow = IRB.CreateShl(WideShadow, DFS.ShadowWidth); in loadShadow()
1102 Value *ShrShadow = IRB.CreateLShr(WideShadow, 64 - DFS.ShadowWidth); in loadShadow()
1103 Value *RotShadow = IRB.CreateOr(ShlShadow, ShrShadow); in loadShadow()
1104 Value *ShadowsEq = IRB.CreateICmpEQ(WideShadow, RotShadow); in loadShadow()
1146 IRBuilder<> IRB(Pos); in loadShadow() local
1147 CallInst *FallbackCall = IRB.CreateCall2( in loadShadow()
1169 IRBuilder<> IRB(&LI); in visitLoadInst() local
1187 IRBuilder<> IRB(Pos); in storeShadow() local
1188 IRB.CreateStore(Shadow, i->second); in storeShadow()
1194 IRBuilder<> IRB(Pos); in storeShadow() local
1200 IRB.CreateBitCast(ShadowAddr, PointerType::getUnqual(ShadowTy)); in storeShadow()
1201 IRB.CreateAlignedStore(ExtZeroShadow, ExtShadowAddr, ShadowAlign); in storeShadow()
1211 ShadowVec = IRB.CreateInsertElement( in storeShadow()
1215 IRB.CreateBitCast(ShadowAddr, PointerType::getUnqual(ShadowVecTy)); in storeShadow()
1218 IRB.CreateConstGEP1_32(ShadowVecTy, ShadowVecAddr, Offset); in storeShadow()
1219 IRB.CreateAlignedStore(ShadowVec, CurShadowVecAddr, ShadowAlign); in storeShadow()
1227 IRB.CreateConstGEP1_32(DFS.ShadowTy, ShadowAddr, Offset); in storeShadow()
1228 IRB.CreateAlignedStore(Shadow, CurShadowAddr, ShadowAlign); in storeShadow()
1304 IRBuilder<> IRB(&I); in visitAllocaInst() local
1305 DFSF.AllocaShadowMap[&I] = IRB.CreateAlloca(DFSF.DFS.ShadowTy); in visitAllocaInst()
1333 IRBuilder<> IRB(&I); in visitMemSetInst() local
1335 IRB.CreateCall3( in visitMemSetInst()
1337 IRB.CreateBitCast(I.getDest(), Type::getInt8PtrTy(*DFSF.DFS.Ctx)), in visitMemSetInst()
1338 IRB.CreateZExtOrTrunc(I.getLength(), DFSF.DFS.IntptrTy)); in visitMemSetInst()
1342 IRBuilder<> IRB(&I); in visitMemTransferInst() local
1345 Value *LenShadow = IRB.CreateMul( in visitMemTransferInst()
1350 AlignShadow = IRB.CreateMul(I.getAlignmentCst(), in visitMemTransferInst()
1358 DestShadow = IRB.CreateBitCast(DestShadow, Int8Ptr); in visitMemTransferInst()
1359 SrcShadow = IRB.CreateBitCast(SrcShadow, Int8Ptr); in visitMemTransferInst()
1360 IRB.CreateCall5(I.getCalledValue(), DestShadow, SrcShadow, LenShadow, in visitMemTransferInst()
1369 IRBuilder<> IRB(&RI); in visitReturnInst() local
1370 IRB.CreateStore(S, DFSF.getRetvalTLS()); in visitReturnInst()
1374 IRBuilder<> IRB(&RI); in visitReturnInst() local
1377 IRB.CreateInsertValue(UndefValue::get(RT), RI.getReturnValue(), 0); in visitReturnInst()
1379 IRB.CreateInsertValue(InsVal, DFSF.getShadow(RI.getReturnValue()), 1); in visitReturnInst()
1403 IRBuilder<> IRB(CS.getInstruction()); in visitCallSite() local
1412 IRB.CreateCall(DFSF.DFS.DFSanUnimplementedFn, in visitCallSite()
1413 IRB.CreateGlobalStringPtr(F->getName())); in visitCallSite()
1464 IRB.CreateBitCast(*i, Type::getInt8PtrTy(*DFSF.DFS.Ctx))); in visitCallSite()
1481 auto LabelVAPtr = IRB.CreateStructGEP(LabelVATy, LabelVAAlloca, n); in visitCallSite()
1482 IRB.CreateStore(DFSF.getShadow(*i), LabelVAPtr); in visitCallSite()
1485 Args.push_back(IRB.CreateStructGEP(LabelVATy, LabelVAAlloca, 0)); in visitCallSite()
1500 CallInst *CustomCI = IRB.CreateCall(CustomF, Args); in visitCallSite()
1505 LoadInst *LabelLoad = IRB.CreateLoad(DFSF.LabelReturnAlloca); in visitCallSite()
1522 IRB.CreateStore(DFSF.getShadow(CS.getArgument(i)), in visitCallSite()
1555 IRB.CreateBitCast(CS.getCalledValue(), PointerType::getUnqual(NewFT)); in visitCallSite()
1571 Args.push_back(IRB.CreateConstGEP2_32(VarArgArrayTy, VarArgShadow, 0, 0)); in visitCallSite()
1573 IRB.CreateStore( in visitCallSite()
1575 IRB.CreateConstGEP2_32(VarArgArrayTy, VarArgShadow, 0, n)); in visitCallSite()
1582 NewCS = IRB.CreateInvoke(Func, II->getNormalDest(), II->getUnwindDest(), in visitCallSite()
1585 NewCS = IRB.CreateCall(Func, Args); in visitCallSite()