[llvm-commits] [llvm] r167111 - in /llvm/trunk: include/llvm/IRBuilder.h unittests/VMCore/IRBuilderTest.cpp
Duncan Sands
baldrick at free.fr
Wed Oct 31 03:28:49 PDT 2012
Hi Evgeniy,
> Add IRBuilderBase::getIntPtrTy.
> --- llvm/trunk/include/llvm/IRBuilder.h (original)
> +++ llvm/trunk/include/llvm/IRBuilder.h Wed Oct 31 04:50:01 2012
> @@ -266,6 +267,10 @@
> return Type::getInt8PtrTy(Context, AddrSpace);
> }
>
> + IntegerType* getIntPtrTy(DataLayout *DL, unsigned AddrSpace = 0) {
> + return DL->getIntPtrType(Context, AddrSpace);
> + }
> +
> //===--------------------------------------------------------------------===//
> // Intrinsic creation methods
> //===--------------------------------------------------------------------===//
>
I don't get it, why is this better than calling DataLayout directly? Also, I'm
not sure that providing a default address space is wise.
Ciao, Duncan.
More information about the llvm-commits
mailing list