diff options
author | Owen Anderson <resistor@mac.com> | 2009-07-27 20:59:43 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2009-07-27 20:59:43 +0000 |
commit | 69c464dec4795af43b4a432bae2b329ee5f1bef5 (patch) | |
tree | 3e3a64f042f90003a35e4cc3a91386fe47c1d11c /llvm/lib/Bitcode | |
parent | 7b2b1ec6b1a573c7b5909bb082ff27766774db80 (diff) | |
download | bcm5719-llvm-69c464dec4795af43b4a432bae2b329ee5f1bef5.tar.gz bcm5719-llvm-69c464dec4795af43b4a432bae2b329ee5f1bef5.zip |
Move ConstantFP construction back to the 2.5-ish API.
llvm-svn: 77247
Diffstat (limited to 'llvm/lib/Bitcode')
-rw-r--r-- | llvm/lib/Bitcode/Reader/BitcodeReader.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp index 0c6162ccffb..687cae9ecf6 100644 --- a/llvm/lib/Bitcode/Reader/BitcodeReader.cpp +++ b/llvm/lib/Bitcode/Reader/BitcodeReader.cpp @@ -896,19 +896,19 @@ bool BitcodeReader::ParseConstants() { if (Record.empty()) return Error("Invalid FLOAT record"); if (CurTy == Type::FloatTy) - V = Context.getConstantFP(APFloat(APInt(32, (uint32_t)Record[0]))); + V = ConstantFP::get(Context, APFloat(APInt(32, (uint32_t)Record[0]))); else if (CurTy == Type::DoubleTy) - V = Context.getConstantFP(APFloat(APInt(64, Record[0]))); + V = ConstantFP::get(Context, APFloat(APInt(64, Record[0]))); else if (CurTy == Type::X86_FP80Ty) { // Bits are not stored the same way as a normal i80 APInt, compensate. uint64_t Rearrange[2]; Rearrange[0] = (Record[1] & 0xffffLL) | (Record[0] << 16); Rearrange[1] = Record[0] >> 48; - V = Context.getConstantFP(APFloat(APInt(80, 2, Rearrange))); + V = ConstantFP::get(Context, APFloat(APInt(80, 2, Rearrange))); } else if (CurTy == Type::FP128Ty) - V = Context.getConstantFP(APFloat(APInt(128, 2, &Record[0]), true)); + V = ConstantFP::get(Context, APFloat(APInt(128, 2, &Record[0]), true)); else if (CurTy == Type::PPC_FP128Ty) - V = Context.getConstantFP(APFloat(APInt(128, 2, &Record[0]))); + V = ConstantFP::get(Context, APFloat(APInt(128, 2, &Record[0]))); else V = Context.getUndef(CurTy); break; |