[llvm-commits] [llvm] r75798 - /llvm/trunk/lib/VMCore/Constants.cpp
Duncan Sands
baldrick at free.fr
Wed Jul 15 10:19:24 PDT 2009
Author: baldrick
Date: Wed Jul 15 12:19:24 2009
New Revision: 75798
URL: http://llvm.org/viewvc/llvm-project?rev=75798&view=rev
Log:
The static function TypeToFloatSemantics is now
unused - remove it.
Modified:
llvm/trunk/lib/VMCore/Constants.cpp
Modified: llvm/trunk/lib/VMCore/Constants.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/VMCore/Constants.cpp?rev=75798&r1=75797&r2=75798&view=diff
==============================================================================
--- llvm/trunk/lib/VMCore/Constants.cpp (original)
+++ llvm/trunk/lib/VMCore/Constants.cpp Wed Jul 15 12:19:24 2009
@@ -255,20 +255,6 @@
// ConstantFP
//===----------------------------------------------------------------------===//
-static const fltSemantics *TypeToFloatSemantics(const Type *Ty) {
- if (Ty == Type::FloatTy)
- return &APFloat::IEEEsingle;
- if (Ty == Type::DoubleTy)
- return &APFloat::IEEEdouble;
- if (Ty == Type::X86_FP80Ty)
- return &APFloat::x87DoubleExtended;
- else if (Ty == Type::FP128Ty)
- return &APFloat::IEEEquad;
-
- assert(Ty == Type::PPC_FP128Ty && "Unknown FP format");
- return &APFloat::PPCDoubleDouble;
-}
-
ConstantFP::ConstantFP(const Type *Ty, const APFloat& V)
: Constant(Ty, ConstantFPVal, 0, 0), Val(V) {
assert(&V.getSemantics() == TypeToFloatSemantics(Ty) &&
More information about the llvm-commits
mailing list