Revert r60042. IndVarSimplify should check if APFloat is PPCDoubleDouble first before trying to convert it to an integer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@60072 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Transforms/Scalar/IndVarSimplify.cpp b/lib/Transforms/Scalar/IndVarSimplify.cpp
index 128b197..fabbf6e 100644
--- a/lib/Transforms/Scalar/IndVarSimplify.cpp
+++ b/lib/Transforms/Scalar/IndVarSimplify.cpp
@@ -742,6 +742,8 @@
static bool convertToInt(const APFloat &APF, uint64_t *intVal) {
bool isExact = false;
+ if (&APF.getSemantics() == &APFloat::PPCDoubleDouble)
+ return false;
if (APF.convertToInteger(intVal, 32, APF.isNegative(),
APFloat::rmTowardZero, &isExact)
!= APFloat::opOK)