Lines Matching full:addr

70   llvm::LoadInst *CreateLoad(Address Addr, const llvm::Twine &Name = "") {
71 return CreateAlignedLoad(Addr.getPointer(),
72 Addr.getAlignment().getQuantity(),
75 llvm::LoadInst *CreateLoad(Address Addr, const char *Name) { in CreateLoad() argument
78 return CreateAlignedLoad(Addr.getPointer(), in CreateLoad()
79 Addr.getAlignment().getQuantity(), in CreateLoad()
82 llvm::LoadInst *CreateLoad(Address Addr, bool IsVolatile,
84 return CreateAlignedLoad(Addr.getPointer(),
85 Addr.getAlignment().getQuantity(),
91 llvm::LoadInst *CreateAlignedLoad(llvm::Value *Addr, CharUnits Align,
93 return CreateAlignedLoad(Addr, Align.getQuantity(), Name);
95 llvm::LoadInst *CreateAlignedLoad(llvm::Value *Addr, CharUnits Align, in CreateAlignedLoad() argument
97 return CreateAlignedLoad(Addr, Align.getQuantity(), Name); in CreateAlignedLoad()
99 llvm::LoadInst *CreateAlignedLoad(llvm::Type *Ty, llvm::Value *Addr,
102 assert(Addr->getType()->getPointerElementType() == Ty);
103 return CreateAlignedLoad(Addr, Align.getQuantity(), Name);
105 llvm::LoadInst *CreateAlignedLoad(llvm::Value *Addr, CharUnits Align,
108 return CreateAlignedLoad(Addr, Align.getQuantity(), IsVolatile, Name);
113 llvm::StoreInst *CreateStore(llvm::Value *Val, Address Addr,
115 return CreateAlignedStore(Val, Addr.getPointer(),
116 Addr.getAlignment().getQuantity(), IsVolatile);
120 llvm::StoreInst *CreateAlignedStore(llvm::Value *Val, llvm::Value *Addr,
122 return CreateAlignedStore(Val, Addr, Align.getQuantity(), IsVolatile);
127 llvm::LoadInst *CreateDefaultAlignedLoad(llvm::Value *Addr,
129 return CGBuilderBaseTy::CreateLoad(Addr, false, Name);
131 llvm::LoadInst *CreateDefaultAlignedLoad(llvm::Value *Addr, in CreateDefaultAlignedLoad() argument
133 return CGBuilderBaseTy::CreateLoad(Addr, false, Name); in CreateDefaultAlignedLoad()
135 llvm::LoadInst *CreateDefaultAlignedLoad(llvm::Value *Addr, bool IsVolatile,
137 return CGBuilderBaseTy::CreateLoad(Addr, IsVolatile, Name);
141 llvm::Value *Addr,
143 return CGBuilderBaseTy::CreateStore(Val, Addr, IsVolatile);
147 llvm::LoadInst *CreateFlagLoad(llvm::Value *Addr,
149 assert(Addr->getType()->getPointerElementType() == getInt1Ty());
150 return CreateAlignedLoad(getInt1Ty(), Addr, CharUnits::One(), Name);
154 llvm::StoreInst *CreateFlagStore(bool Value, llvm::Value *Addr) { in CreateFlagStore() argument
155 assert(Addr->getType()->getPointerElementType() == getInt1Ty()); in CreateFlagStore()
156 return CreateAlignedStore(getInt1(Value), Addr, CharUnits::One()); in CreateFlagStore()
160 Address CreateBitCast(Address Addr, llvm::Type *Ty,
162 return Address(CreateBitCast(Addr.getPointer(), Ty, Name),
163 Addr.getAlignment());
168 Address CreateElementBitCast(Address Addr, llvm::Type *Ty,
170 auto PtrTy = Ty->getPointerTo(Addr.getAddressSpace());
171 return CreateBitCast(Addr, PtrTy, Name);
175 Address CreatePointerBitCastOrAddrSpaceCast(Address Addr, llvm::Type *Ty,
178 CreatePointerBitCastOrAddrSpaceCast(Addr.getPointer(), Ty, Name);
179 return Address(Ptr, Addr.getAlignment());
183 Address CreateStructGEP(Address Addr, unsigned Index, CharUnits Offset,
185 return Address(CreateStructGEP(Addr.getElementType(),
186 Addr.getPointer(), Index, Name),
187 Addr.getAlignment().alignmentAtOffset(Offset));
189 Address CreateStructGEP(Address Addr, unsigned Index,
193 return CreateStructGEP(Addr, Index, Offset, Name);
197 /// %addr = [n x T]* ...
199 /// %name = getelementptr inbounds %addr, i64 0, i64 index
206 Address CreateConstArrayGEP(Address Addr, uint64_t Index, CharUnits EltSize,
208 return Address(CreateInBoundsGEP(Addr.getPointer(),
212 Addr.getAlignment().alignmentAtOffset(Index * EltSize));
216 /// %addr = T* ...
218 /// %name = getelementptr inbounds %addr, i64 index
222 Address CreateConstInBoundsGEP(Address Addr, uint64_t Index,
225 return Address(CreateInBoundsGEP(Addr.getElementType(), Addr.getPointer(),
227 Addr.getAlignment().alignmentAtOffset(Index * EltSize));
231 /// %addr = T* ...
233 /// %name = getelementptr inbounds %addr, i64 index
237 Address CreateConstGEP(Address Addr, uint64_t Index, CharUnits EltSize,
239 return Address(CreateGEP(Addr.getElementType(), Addr.getPointer(),
241 Addr.getAlignment().alignmentAtOffset(Index * EltSize));
245 Address CreateConstInBoundsByteGEP(Address Addr, CharUnits Offset,
247 assert(Addr.getElementType() == TypeCache.Int8Ty);
248 return Address(CreateInBoundsGEP(Addr.getPointer(), getSize(Offset), Name),
249 Addr.getAlignment().alignmentAtOffset(Offset));
251 Address CreateConstByteGEP(Address Addr, CharUnits Offset,
253 assert(Addr.getElementType() == TypeCache.Int8Ty);
254 return Address(CreateGEP(Addr.getPointer(), getSize(Offset), Name),
255 Addr.getAlignment().alignmentAtOffset(Offset));