[LLVMdev] How to create an IntegerType of the native word size

Harel Cain harel.cain at gmail.com
Mon Jan 24 01:56:18 PST 2011


Hi all,

I couldn't find any reasonable way to create the IntegerType that would
match, say, intptr_t, that is the native word size of the machine I'm
building on. More accurately defined, when compiling on a 64 bit Mac OS
machine I want it to be Int64Ty, but if for example I'm using the "-arch
i386" command line option on that machine during compilation, I want it to
be Int32Ty.

I'm sure that has to be some perfect solution out there, does anyone know?


Thanks!

Harel Cain
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110124/fdd53a9e/attachment.html>


More information about the llvm-dev mailing list