summaryrefslogtreecommitdiffstats
path: root/llvm/lib/ExecutionEngine/JIT
diff options
context:
space:
mode:
authorTim Northover <Tim.Northover@arm.com>2013-01-22 09:46:31 +0000
committerTim Northover <Tim.Northover@arm.com>2013-01-22 09:46:31 +0000
commit29178a348a719c4c4e14939dcc02218bcd5341d9 (patch)
tree01778be07ddb8b749cbb3275700c21293d107d51 /llvm/lib/ExecutionEngine/JIT
parent015333f88c21673a8d8958242ef24920dd0506a9 (diff)
downloadbcm5719-llvm-29178a348a719c4c4e14939dcc02218bcd5341d9.tar.gz
bcm5719-llvm-29178a348a719c4c4e14939dcc02218bcd5341d9.zip
Make APFloat constructor require explicit semantics.
Previously we tried to infer it from the bit width size, with an added IsIEEE argument for the PPC/IEEE 128-bit case, which had a default value. This default value allowed bugs to creep in, where it was inappropriate. llvm-svn: 173138
Diffstat (limited to 'llvm/lib/ExecutionEngine/JIT')
-rw-r--r--llvm/lib/ExecutionEngine/JIT/JIT.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/ExecutionEngine/JIT/JIT.cpp b/llvm/lib/ExecutionEngine/JIT/JIT.cpp
index 103c0c0d1b9..53ea0a26008 100644
--- a/llvm/lib/ExecutionEngine/JIT/JIT.cpp
+++ b/llvm/lib/ExecutionEngine/JIT/JIT.cpp
@@ -522,7 +522,8 @@ GenericValue JIT::runFunction(Function *F,
case Type::PPC_FP128TyID:
case Type::X86_FP80TyID:
case Type::FP128TyID:
- C = ConstantFP::get(F->getContext(), APFloat(AV.IntVal));
+ C = ConstantFP::get(F->getContext(), APFloat(ArgTy->getFltSemantics(),
+ AV.IntVal));
break;
case Type::PointerTyID:
void *ArgPtr = GVTOP(AV);
OpenPOWER on IntegriCloud