Next PPC long double bits.  First cut at constants.
No compile-time support for constant operations yet,
just format transformations.  Make readers and
writers work.  Split constants into 2 doubles in
Legalize.

llvm-svn: 42865
diff --git a/llvm/lib/VMCore/Constants.cpp b/llvm/lib/VMCore/Constants.cpp
index 7de823b..350a306 100644
--- a/llvm/lib/VMCore/Constants.cpp
+++ b/llvm/lib/VMCore/Constants.cpp
@@ -114,6 +114,7 @@
   case Type::X86_FP80TyID:
     return ConstantFP::get(Ty, APFloat(APInt(80, 2, zero)));
   case Type::FP128TyID:
+    return ConstantFP::get(Ty, APFloat(APInt(128, 2, zero), true));
   case Type::PPC_FP128TyID:
     return ConstantFP::get(Ty, APFloat(APInt(128, 2, zero)));
   case Type::PointerTyID:
@@ -256,6 +257,8 @@
     assert(&V.getSemantics()==&APFloat::x87DoubleExtended);
   else if (Ty==Type::FP128Ty)
     assert(&V.getSemantics()==&APFloat::IEEEquad);
+  else if (Ty==Type::PPC_FP128Ty)
+    assert(&V.getSemantics()==&APFloat::PPCDoubleDouble);
   else
     assert(0);
 }
@@ -320,6 +323,8 @@
     assert(&V.getSemantics()==&APFloat::x87DoubleExtended);
   else if (Ty==Type::FP128Ty)
     assert(&V.getSemantics()==&APFloat::IEEEquad);
+  else if (Ty==Type::PPC_FP128Ty)
+    assert(&V.getSemantics()==&APFloat::PPCDoubleDouble);
   else
     assert(0);
   
@@ -747,6 +752,10 @@
     return &Val2.getSemantics() == &APFloat::IEEEsingle || 
            &Val2.getSemantics() == &APFloat::IEEEdouble ||
            &Val2.getSemantics() == &APFloat::IEEEquad;
+  case Type::PPC_FP128TyID:
+    return &Val2.getSemantics() == &APFloat::IEEEsingle || 
+           &Val2.getSemantics() == &APFloat::IEEEdouble ||
+           &Val2.getSemantics() == &APFloat::PPCDoubleDouble;
   }
 }