| /freebsd/contrib/llvm-project/llvm/lib/Transforms/Utils/ |
| H A D | SanitizerStats.cpp | 46 IntegerType *IntPtrTy = B.getIntPtrTy(M->getDataLayout()); in create() 53 ConstantInt::get(IntPtrTy, uint64_t(SK) << (IntPtrTy->getBitWidth() - in create() 64 ConstantInt::get(IntPtrTy, 0), ConstantInt::get(B.getInt32Ty(), 2), in create() 65 ConstantInt::get(IntPtrTy, Inits.size() - 1), in create() 45 IntegerType *IntPtrTy = B.getIntPtrTy(M->getDataLayout()); create() local
|
| H A D | RelLookupTableConverter.cpp | 134 Type *IntPtrTy = M.getDataLayout().getIntPtrType(M.getContext()); in createRelLookupTable() local 135 Constant *Base = llvm::ConstantExpr::getPtrToInt(RelLookupTable, IntPtrTy); in createRelLookupTable() 136 Constant *Target = llvm::ConstantExpr::getPtrToInt(Element, IntPtrTy); in createRelLookupTable()
|
| /freebsd/contrib/llvm-project/clang/lib/CodeGen/ |
| H A D | CGPointerAuth.cpp | 35 IntPtrTy, getContext().getPointerAuthTypeDiscriminator(Type)); in getPointerAuthOtherDiscriminator() 40 return llvm::ConstantInt::get(IntPtrTy, in getPointerAuthOtherDiscriminator() 44 return llvm::ConstantInt::get(IntPtrTy, Schema.getConstantDiscrimination()); in getPointerAuthOtherDiscriminator() 96 StorageAddress = Builder.CreatePtrToInt(StorageAddress, IntPtrTy); in EmitPointerAuthBlendDiscriminator() 120 Discriminator = Builder.CreatePtrToInt(StorageAddress, IntPtrTy); in EmitPointerAuthInfo() 137 Discriminator = llvm::ConstantInt::get(IntPtrTy, Extra); in EmitPointerAuthInfo() 147 Discriminator = Builder.CreatePtrToInt(StoragePtr, IntPtrTy); in EmitPointerAuthInfo() 322 Value = Builder.CreatePtrToInt(Value, IntPtrTy); in emitPointerAuthResignCall() 355 Null = llvm::ConstantInt::get(IntPtrTy, 0); in emitPointerAuthResign() 631 Discriminator = llvm::ConstantInt::get(IntPtrTy, ExtraDiscriminator); in getVTablePointerAuthInfo() [all …]
|
| H A D | ConstantInitBuilder.cpp | 141 base = llvm::ConstantExpr::getPtrToInt(base, Builder.CGM.IntPtrTy); in getRelativeOffsetToPosition() 142 target = llvm::ConstantExpr::getPtrToInt(target, Builder.CGM.IntPtrTy); in getRelativeOffsetToPosition() 146 if (Builder.CGM.IntPtrTy != offsetType) { in getRelativeOffsetToPosition()
|
| H A D | CodeGenTypeCache.h | 49 llvm::IntegerType *IntPtrTy; member
|
| H A D | CGExpr.cpp | 801 llvm::Value *Size = llvm::ConstantInt::get(IntPtrTy, TySize); in EmitTypeCheck() 813 llvm::Type *Tys[2] = {IntPtrTy, Int8PtrTy}; in EmitTypeCheck() 839 PtrAsInt = Builder.CreatePtrToInt(Ptr, IntPtrTy); in EmitTypeCheck() 841 PtrAsInt, llvm::ConstantInt::get(IntPtrTy, AlignVal->value() - 1)); in EmitTypeCheck() 843 Builder.CreateICmpEQ(Align, llvm::ConstantInt::get(IntPtrTy, 0)); in EmitTypeCheck() 898 Address VPtrAddr(Ptr, IntPtrTy, getPointerAlign()); in EmitTypeCheck() 902 VPtrVal = Builder.CreateBitOrPointerCast(VPtrVal, IntPtrTy); in EmitTypeCheck() 906 Hash = Builder.CreateTrunc(Hash, IntPtrTy); in EmitTypeCheck() 910 llvm::Type *HashTable = llvm::ArrayType::get(IntPtrTy, CacheSize); in EmitTypeCheck() 914 llvm::ConstantInt::get(IntPtrTy, in EmitTypeCheck() [all …]
|
| H A D | ABIInfoImpl.cpp | 157 llvm::Intrinsic::ptrmask, {Ptr->getType(), CGF.IntPtrTy}, in emitRoundPointerUpToAlignment() 158 {RoundUp, llvm::ConstantInt::get(CGF.IntPtrTy, -Align.getQuantity())}, in emitRoundPointerUpToAlignment()
|
| H A D | CodeGenFunction.cpp | 2185 = llvm::ConstantInt::get(CGF.IntPtrTy, baseSize.getQuantity()); in emitNonZeroVLAInit() 2669 if (Alignment->getType() != IntPtrTy) in emitAlignmentAssumption() 2671 Builder.CreateIntCast(Alignment, IntPtrTy, false, "casted.align"); in emitAlignmentAssumption() 2672 if (OffsetValue && OffsetValue->getType() != IntPtrTy) in emitAlignmentAssumption() 2674 Builder.CreateIntCast(OffsetValue, IntPtrTy, true, "casted.offset"); in emitAlignmentAssumption() 2678 Builder.CreatePtrToInt(PtrValue, IntPtrTy, "ptrint"); in emitAlignmentAssumption() 2689 llvm::Value *Zero = llvm::ConstantInt::get(IntPtrTy, 0); in emitAlignmentAssumption() 2691 Builder.CreateSub(Alignment, llvm::ConstantInt::get(IntPtrTy, 1)); in emitAlignmentAssumption() 3307 Pointer = CGF.Builder.CreatePtrToInt(Pointer, CGF.IntPtrTy); in EmitPointerAuthCommon() 3336 StripIntrinsic, {CGF.Builder.CreatePtrToInt(Pointer, CGF.IntPtrTy), Key}); in EmitStrip()
|
| H A D | CGExprScalar.cpp | 4244 llvm::Type *IntPtrTy = DL.getIntPtrType(PtrTy); in emitPointerArithmetic() local 4245 Value *IntPtr = llvm::Constant::getNullValue(IntPtrTy); in emitPointerArithmetic() 4246 Value *ComputedGEP = CGF.Builder.CreateZExtOrTrunc(index, IntPtrTy); in emitPointerArithmetic() 5984 auto *IntPtrTy = DL.getIntPtrType(GEP->getPointerOperandType()); in EmitGEPOffsetInBytes() local 5987 auto *Zero = llvm::ConstantInt::getNullValue(IntPtrTy); in EmitGEPOffsetInBytes() 5989 CGM.getIntrinsic(llvm::Intrinsic::sadd_with_overflow, IntPtrTy); in EmitGEPOffsetInBytes() 5991 CGM.getIntrinsic(llvm::Intrinsic::smul_with_overflow, IntPtrTy); in EmitGEPOffsetInBytes() 6032 IntPtrTy, DL.getStructLayout(STy)->getElementOffset(FieldNo)); in EmitGEPOffsetInBytes() 6037 llvm::ConstantInt::get(IntPtrTy, GTI.getSequentialElementStride(DL)); in EmitGEPOffsetInBytes() 6038 auto *IndexS = Builder.CreateIntCast(Index, IntPtrTy, /*isSigned=*/true); in EmitGEPOffsetInBytes() [all …]
|
| H A D | CGBuiltin.cpp | 448 Exchange = CGF.Builder.CreatePtrToInt(Exchange, CGF.IntPtrTy); in EmitAtomicCmpXchgForMSIntrin() 449 Comparand = CGF.Builder.CreatePtrToInt(Comparand, CGF.IntPtrTy); in EmitAtomicCmpXchgForMSIntrin() 685 QualType IntPtrTy = E->getArg(1)->getType()->getPointeeType(); in emitFrexpBuiltin() local 686 llvm::Type *IntTy = CGF.ConvertType(IntPtrTy); in emitFrexpBuiltin() 692 LValue LV = CGF.MakeNaturalAlignAddrLValue(Src1, IntPtrTy); in emitFrexpBuiltin() 3528 if (SizeValue->getType() != IntPtrTy) in EmitBuiltinExpr() 3530 Builder.CreateIntCast(SizeValue, IntPtrTy, false, "casted.size"); in EmitBuiltinExpr() 4738 Value *Result = Builder.CreatePtrToInt(Ptr, IntPtrTy, "extend.cast"); in EmitBuiltinExpr() 4741 if (IntPtrTy->getBitWidth() == 64) in EmitBuiltinExpr() 5599 Args[0] = Builder.CreatePtrToInt(Args[0], IntPtrTy); in EmitBuiltinExpr() [all …]
|
| /freebsd/contrib/llvm-project/llvm/lib/Target/RISCV/ |
| H A D | RISCVGatherScatterLowering.cpp | 347 Type *IntPtrTy = DL->getIntPtrType(BasePtr->getType()); in determineBaseAndStride() local 348 return std::make_pair(BasePtr, ConstantInt::get(IntPtrTy, 0)); in determineBaseAndStride() 444 Type *IntPtrTy = DL->getIntPtrType(BasePtr->getType()); in determineBaseAndStride() local 445 assert(Stride->getType() == IntPtrTy && "Unexpected type"); in determineBaseAndStride() 449 Stride = Builder.CreateMul(Stride, ConstantInt::get(IntPtrTy, TypeScale)); in determineBaseAndStride() 484 Type *IntPtrTy = DL->getIntPtrType(BasePtr->getType()); in determineBaseAndStride() local 485 assert(Stride->getType() == IntPtrTy && "Unexpected type"); in determineBaseAndStride() 489 Stride = Builder.CreateMul(Stride, ConstantInt::get(IntPtrTy, TypeScale)); in determineBaseAndStride()
|
| /freebsd/contrib/llvm-project/llvm/lib/CodeGen/ |
| H A D | SafeStack.cpp | 119 Type *IntPtrTy; member in __anon0b441ea90111::SafeStack 195 IntPtrTy(DL.getIntPtrType(F.getContext())), in SafeStack() 561 IRB.CreatePtrToInt(BasePointer, IntPtrTy), in moveStaticAllocasToUnsafeStack() 562 ConstantInt::get(IntPtrTy, ~(FrameAlignment.value() - 1))), in moveStaticAllocasToUnsafeStack() 672 if (ArraySize->getType() != IntPtrTy) in moveDynamicAllocasToUnsafeStack() 673 ArraySize = IRB.CreateIntCast(ArraySize, IntPtrTy, false); in moveDynamicAllocasToUnsafeStack() 677 Value *Size = IRB.CreateMul(ArraySize, ConstantInt::get(IntPtrTy, TySize)); in moveDynamicAllocasToUnsafeStack() 680 IntPtrTy); in moveDynamicAllocasToUnsafeStack() 689 ConstantInt::get(IntPtrTy, ~uint64_t(Align.value() - 1))), in moveDynamicAllocasToUnsafeStack()
|
| H A D | CodeGenPrepare.cpp | 3175 Value *GetFieldAsValue(FieldName Field, Type *IntPtrTy) { in GetFieldAsValue() 3186 return ConstantInt::get(IntPtrTy, BaseOffs); in GetFieldAsValue() 4254 Type *IntPtrTy = SQ.DL.getIntPtrType(AddrModes[0].OriginalValue->getType()); in initializeMap() local 4256 Value *DV = AM.GetFieldAsValue(DifferentField, IntPtrTy); in initializeMap() 5940 Type *IntPtrTy = DL->getIntPtrType(Addr->getType()); in optimizeMemoryInst() local 5969 SunkAddr = Builder.CreatePtrToInt(SunkAddr, IntPtrTy, "sunkaddr"); in optimizeMemoryInst() 6008 if (cast<IntegerType>(IntPtrTy)->getBitWidth() > in optimizeMemoryInst() 6056 if (V->getType() != IntPtrTy) in optimizeMemoryInst() 6057 V = Builder.CreateIntCast(V, IntPtrTy, /*isSigned=*/true, "sunkaddr"); in optimizeMemoryInst() 6065 if (V->getType() == IntPtrTy) { in optimizeMemoryInst() [all …]
|
| /freebsd/contrib/llvm-project/llvm/lib/Transforms/IPO/ |
| H A D | LowerTypeTests.cpp | 451 IntegerType *IntPtrTy = M.getDataLayout().getIntPtrType(M.getContext(), 0); member in __anonc00fd2a30111::LowerTypeTestsModule 668 Constant *Idxs[] = {ConstantInt::get(IntPtrTy, 0), in allocateByteArrays() 669 ConstantInt::get(IntPtrTy, ByteArrayOffsets[I])}; in allocateByteArrays() 775 Value *PtrAsInt = B.CreatePtrToInt(Ptr, IntPtrTy); in lowerTypeTestCall() 778 ConstantExpr::getPtrToInt(TIL.OffsetedGlobal, IntPtrTy); in lowerTypeTestCall() 796 Value *BitOffset = B.CreateIntrinsic(IntPtrTy, Intrinsic::fshr, in lowerTypeTestCall() 1017 auto *MinC = ConstantAsMetadata::get(ConstantInt::get(IntPtrTy, Min)); in importTypeId() 1018 auto *MaxC = ConstantAsMetadata::get(ConstantInt::get(IntPtrTy, Max)); in importTypeId() 1022 if (AbsWidth == IntPtrTy->getBitWidth()) in importTypeId() 1049 TIL.AlignLog2 = ImportConstant("align", TTRes.AlignLog2, 8, IntPtrTy); in importTypeId() [all …]
|
| H A D | WholeProgramDevirt.cpp | 583 IntegerType *IntPtrTy; member 625 IntPtrTy(M.getDataLayout().getIntPtrType(M.getContext(), 0)), in DevirtModule() 1724 auto *MinC = ConstantAsMetadata::get(ConstantInt::get(IntPtrTy, Min)); in importConstant() 1725 auto *MaxC = ConstantAsMetadata::get(ConstantInt::get(IntPtrTy, Max)); in importConstant() 1730 if (AbsWidth == IntPtrTy->getBitWidth()) in importConstant()
|
| /freebsd/contrib/llvm-project/llvm/lib/Transforms/Scalar/ |
| H A D | SeparateConstOffsetFromGEP.cpp | 958 Type *IntPtrTy = DL->getIntPtrType(Variadic->getType()); in lowerToArithmetics() local 959 assert(IntPtrTy == DL->getIndexType(Variadic->getType()) && in lowerToArithmetics() 963 Value *ResultPtr = Builder.CreatePtrToInt(Variadic->getOperand(0), IntPtrTy); in lowerToArithmetics() 976 APInt ElementSize = APInt(IntPtrTy->getIntegerBitWidth(), in lowerToArithmetics() 982 Idx, ConstantInt::get(IntPtrTy, ElementSize.logBase2())); in lowerToArithmetics() 984 Idx = Builder.CreateMul(Idx, ConstantInt::get(IntPtrTy, ElementSize)); in lowerToArithmetics() 995 ResultPtr, ConstantInt::get(IntPtrTy, AccumulativeByteOffset)); in lowerToArithmetics()
|
| H A D | LowerMatrixIntrinsics.cpp | 1829 Type *IntPtrTy = Builder.getIntPtrTy(Load->getDataLayout()); in getNonAliasingPointer() local 1831 const_cast<Value *>(StoreLoc.Ptr), IntPtrTy, "store.begin"); in getNonAliasingPointer() 1833 StoreBegin, ConstantInt::get(IntPtrTy, StoreLoc.Size.getValue()), in getNonAliasingPointer() 1836 IntPtrTy, "load.begin"); in getNonAliasingPointer() 1846 LoadBegin, ConstantInt::get(IntPtrTy, LoadLoc.Size.getValue()), in getNonAliasingPointer()
|
| /freebsd/contrib/llvm-project/llvm/lib/IR/ |
| H A D | IRBuilder.cpp | 259 CallInst *IRBuilderBase::CreateMalloc(Type *IntPtrTy, Type *AllocTy, in CreateMalloc() argument 268 ArraySize = ConstantInt::get(IntPtrTy, 1); in CreateMalloc() 269 else if (ArraySize->getType() != IntPtrTy) in CreateMalloc() 270 ArraySize = CreateIntCast(ArraySize, IntPtrTy, false); in CreateMalloc() 281 assert(AllocSize->getType() == IntPtrTy && "malloc arg is wrong size"); in CreateMalloc() 288 MallocFunc = M->getOrInsertFunction("malloc", BPTy, IntPtrTy); in CreateMalloc() 302 CallInst *IRBuilderBase::CreateMalloc(Type *IntPtrTy, Type *AllocTy, in CreateMalloc() argument 306 return CreateMalloc(IntPtrTy, AllocTy, AllocSize, ArraySize, {}, MallocF, in CreateMalloc() 1237 Type *IntPtrTy = getIntPtrTy(DL, PtrTy->getAddressSpace()); in CreateAlignmentAssumption() local 1238 Value *AlignValue = ConstantInt::get(IntPtrTy, Alignment); in CreateAlignmentAssumption()
|
| /freebsd/contrib/llvm-project/llvm/lib/Transforms/Instrumentation/ |
| H A D | InstrProfiling.cpp | 1804 auto *IntPtrTy = M.getDataLayout().getIntPtrType(M.getContext()); in createDataVariable() local 1844 Constant *RelativeBitmapPtr = ConstantInt::get(IntPtrTy, 0); in createDataVariable() 1850 RelativeCounterPtr = ConstantExpr::getPtrToInt(CounterPtr, IntPtrTy); in createDataVariable() 1852 RelativeBitmapPtr = ConstantExpr::getPtrToInt(BitmapPtr, IntPtrTy); in createDataVariable() 1858 ConstantExpr::getSub(ConstantExpr::getPtrToInt(CounterPtr, IntPtrTy), in createDataVariable() 1859 ConstantExpr::getPtrToInt(Data, IntPtrTy)); in createDataVariable() 1862 ConstantExpr::getSub(ConstantExpr::getPtrToInt(BitmapPtr, IntPtrTy), in createDataVariable() 1863 ConstantExpr::getPtrToInt(Data, IntPtrTy)); in createDataVariable()
|
| /freebsd/contrib/llvm-project/llvm/lib/Target/Hexagon/ |
| H A D | HexagonLoopIdiomRecognition.cpp | 2030 Type *IntPtrTy = Builder.getIntPtrTy(*DL, SI->getPointerAddressSpace()); in processCopyingStore() local 2140 BECount = SE->getTruncateOrZeroExtend(BECount, IntPtrTy); in processCopyingStore() 2144 SE->getAddExpr(BECount, SE->getOne(IntPtrTy), SCEV::FlagNUW); in processCopyingStore() 2146 NumBytesS = SE->getMulExpr(NumBytesS, SE->getConstant(IntPtrTy, StoreSize), in processCopyingStore() 2148 Value *NumBytes = Expander.expandCodeFor(NumBytesS, IntPtrTy, ExpPt); in processCopyingStore() 2194 Value *LA = Builder.CreatePtrToInt(LoadBasePtr, IntPtrTy); in processCopyingStore() 2195 Value *SA = Builder.CreatePtrToInt(StoreBasePtr, IntPtrTy); in processCopyingStore()
|
| /freebsd/contrib/llvm-project/llvm/lib/CodeGen/GlobalISel/ |
| H A D | CallLowering.cpp | 412 LLT IntPtrTy = LLT::scalar(OrigTy.getSizeInBits()); in buildCopyFromRegs() local 413 B.buildIntToPtr(OrigRegs[0], B.buildTrunc(IntPtrTy, SrcReg)); in buildCopyFromRegs() 1310 LLT IntPtrTy = LLT::scalar(ValRegTy.getSizeInBits()); in extendRegister() local 1311 ValReg = MIRBuilder.buildPtrToInt(IntPtrTy, ValReg).getReg(0); in extendRegister()
|
| H A D | IRTranslator.cpp | 3099 LLT IntPtrTy = getLLTForType(*IntPtrIRTy, *DL); in translateAlloca() local 3100 if (MRI->getType(NumElts) != IntPtrTy) { in translateAlloca() 3101 Register ExtElts = MRI->createGenericVirtualRegister(IntPtrTy); in translateAlloca() 3108 Register AllocSize = MRI->createGenericVirtualRegister(IntPtrTy); in translateAlloca() 3117 auto SAMinusOne = MIRBuilder.buildConstant(IntPtrTy, StackAlign.value() - 1); in translateAlloca() 3118 auto AllocAdd = MIRBuilder.buildAdd(IntPtrTy, AllocSize, SAMinusOne, in translateAlloca() 3121 MIRBuilder.buildConstant(IntPtrTy, ~(uint64_t)(StackAlign.value() - 1)); in translateAlloca() 3122 auto AlignedAlloc = MIRBuilder.buildAnd(IntPtrTy, AllocAdd, AlignCst); in translateAlloca()
|
| /freebsd/contrib/llvm-project/llvm/lib/Analysis/ |
| H A D | ConstantFolding.cpp | 1216 Type *IntPtrTy = DL.getIntPtrType(CE0->getType()); in ConstantFoldCompareInstOperands() local 1219 if (Constant *C = ConstantFoldIntegerCast(CE0->getOperand(0), IntPtrTy, in ConstantFoldCompareInstOperands() 1229 Type *IntPtrTy = DL.getIntPtrType(CE0->getOperand(0)->getType()); in ConstantFoldCompareInstOperands() local 1230 if (CE0->getType() == IntPtrTy) { in ConstantFoldCompareInstOperands() 1241 Type *IntPtrTy = DL.getIntPtrType(CE0->getType()); in ConstantFoldCompareInstOperands() local 1245 Constant *C0 = ConstantFoldIntegerCast(CE0->getOperand(0), IntPtrTy, in ConstantFoldCompareInstOperands() 1247 Constant *C1 = ConstantFoldIntegerCast(CE1->getOperand(0), IntPtrTy, in ConstantFoldCompareInstOperands() 1256 Type *IntPtrTy = DL.getIntPtrType(CE0->getOperand(0)->getType()); in ConstantFoldCompareInstOperands() local 1257 if (CE0->getType() == IntPtrTy && in ConstantFoldCompareInstOperands()
|
| /freebsd/contrib/llvm-project/llvm/lib/Target/XCore/ |
| H A D | XCoreISelLowering.cpp | 430 Type *IntPtrTy = DAG.getDataLayout().getIntPtrType(Context); in LowerLOAD() local 434 Entry.Ty = IntPtrTy; in LowerLOAD() 440 CallingConv::C, IntPtrTy, in LowerLOAD() 481 Type *IntPtrTy = DAG.getDataLayout().getIntPtrType(Context); in LowerSTORE() local 485 Entry.Ty = IntPtrTy; in LowerSTORE()
|
| /freebsd/contrib/llvm-project/clang/lib/CodeGen/Targets/ |
| H A D | Mips.cpp | 405 llvm::Type *IntTy = (OrigTy->isIntegerType() ? ValTy : CGF.IntPtrTy); in EmitVAArg()
|