Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to specify a hexadecimal number in LLVM IR code?

Tags:

llvm

llvm-ir

For example:

error: floating point constant invalid for type
      %3 = and i8 0x80, %2
                  ^
like image 406
andrewrk Avatar asked Nov 07 '25 02:11

andrewrk


1 Answers

From a scan of the IR reference manual, it looks like hexadecimal literals are reserved for the representation of floating point numbers that cannot be exactly represented in a reasonable number of digits.

Which explains why your error message says that the floating point constant is invalid.

like image 56
Aatch Avatar answered Nov 10 '25 22:11

Aatch



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!