[LLVMdev] Intrinsic prototype has incorrect number of arguments!
F van der Meeren
llvm-dev at code2develop.com
Tue Sep 7 12:25:08 PDT 2010
That won't work when you are trying to limit yourself to C and only C.
Is there an LLVM-C alternative?
Filip
On 07 Sep 2010, at 20:37, Eric Christopher wrote:
>
> On Sep 7, 2010, at 11:30 AM, F van der Meeren wrote:
>
>>
>>
>> Any ideas on what I am doing wrong here ?
>>
>
>
> Why not just use something like:
>
> const Type *ArgPtr = Type::getInt8PtrTy(Context);
> const Type *IntPtr = getTargetData().getIntPtrType(Context);
>
> and then:
>
> const Type *ArgTypes[3] = {ArgPtr, ArgPtr, IntPtr };
> Intrinsic::getDeclaration(TheModule, Intrinsic::memcpy, ArgTypes, 3)
>
> to get the type of memcpy? Trying to declare it that way is likely confusing to the system.
>
> -eric
More information about the llvm-dev
mailing list