[LLVMdev] Define Integer to be of 2 Bytes for a Target
Benjamin Kramer
benny.kra at gmail.com
Tue Apr 30 05:11:32 PDT 2013
On 30.04.2013, at 14:00, Shashidhar <shashidhar at rrlogic.co.in> wrote:
> Hi,
>
> Is there a way to specify the Integer type to be of 2Byte for a Target? LLVM IR produces 4Bytes(i32) for Integer type. Clang can be tweaked to make the integer to be of 2Byte(i16), but is there a way to specify in the LLVM CodeGen?
There is no "int" in LLVM, only fixed size types. You'll have to make that tweak in the program you're using to emit LLVM IR (e.g. clang).
- Ben
More information about the llvm-dev
mailing list