mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 04:02:41 +01:00
Change hex float constants for the sake of VC++.
llvm-svn: 22828
This commit is contained in:
parent
d3add16ed6
commit
2370cb4e85
@ -204,7 +204,10 @@ SDOperand SelectionDAGLegalize::ExpandLegalINT_TO_FP(bool isSigned,
|
||||
SDOperand Load = DAG.getLoad(MVT::f64, Store2, StackSlot,
|
||||
DAG.getSrcValue(NULL));
|
||||
// FP constant to bias correct the final result
|
||||
SDOperand Bias = DAG.getConstantFP(isSigned ? 0x1.000008p52 : 0x1.000000p52,
|
||||
uint64_t SignedBias = 0x4330000080000000ULL;
|
||||
uint64_t UnsignedBias = 0x4330000000000000ULL;
|
||||
SDOperand Bias = DAG.getConstantFP(isSigned ? *(double *)&SignedBias
|
||||
: *(double *)&UnsignedBias,
|
||||
MVT::f64);
|
||||
// subtract the bias
|
||||
SDOperand Sub = DAG.getNode(ISD::SUB, MVT::f64, Load, Bias);
|
||||
|
Loading…
Reference in New Issue
Block a user