[LLVMdev] get unsigned integer pattern for ConstantFP

reed kotler rkotler at mips.com
Mon May 5 11:25:27 PDT 2014


On 05/05/2014 11:06 AM, Matt Arsenault wrote:
> On 05/05/2014 10:12 AM, reed kotler wrote:
>> What is the proper way to get the bit pattern associated with a 
>> ConstantFP?
>>
>> The 32 bit pattern if MVT::f32 or pair of 32 bit patterns with 
>> MVT::f64 ?
>>
> I recently did this, and I used 
> ConstantFP::getValueAPF().bitcastToAPInt()
thanks.

I just found that too.

I guess it's safe to do it this way then.

Reed




More information about the llvm-dev mailing list