[LLVMdev] Need help in converting int to double

John McCall rjmccall at apple.com
Thu Sep 22 16:05:44 PDT 2011

On Sep 22, 2011, at 3:32 AM, James Molloy wrote:
> It’s in trouble by this point because it needs to do a fptosi on a double operand, but you’ve got an i64 operand and you can’t reinterpret-cast ints to floats in LLVM IR (AFAIK)

You can bitcast ints to floats and vice-versa if they're the same size — for example, i32 to float and i64 to double.


More information about the llvm-dev mailing list