diff options
author | Dale Johannesen <dalej@apple.com> | 2007-09-12 03:30:33 +0000 |
---|---|---|
committer | Dale Johannesen <dalej@apple.com> | 2007-09-12 03:30:33 +0000 |
commit | 9d5f45607793052bf5b4436d1b43013fab9999ac (patch) | |
tree | da064f263b6242adf84ced2a98439707a6114ddd /lib/CodeGen/MachOWriter.cpp | |
parent | 257500db0437b6089f46ccf58bcdf04ad8dae9d9 (diff) | |
download | external_llvm-9d5f45607793052bf5b4436d1b43013fab9999ac.zip external_llvm-9d5f45607793052bf5b4436d1b43013fab9999ac.tar.gz external_llvm-9d5f45607793052bf5b4436d1b43013fab9999ac.tar.bz2 |
Revise previous patch per review comments.
Next round of x87 long double stuff.
Getting close now, basically works.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41875 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/MachOWriter.cpp')
-rw-r--r-- | lib/CodeGen/MachOWriter.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/CodeGen/MachOWriter.cpp b/lib/CodeGen/MachOWriter.cpp index 1c9b0fe..0c74375 100644 --- a/lib/CodeGen/MachOWriter.cpp +++ b/lib/CodeGen/MachOWriter.cpp @@ -861,8 +861,8 @@ void MachOWriter::InitMem(const Constant *C, void *Addr, intptr_t Offset, break; } case Type::FloatTyID: { - uint32_t val = (uint32_t)*cast<ConstantFP>(PC)-> - getValueAPF().convertToAPInt().getRawData(); + uint32_t val = cast<ConstantFP>(PC)->getValueAPF().convertToAPInt(). + getZExtValue(); if (TD->isBigEndian()) val = ByteSwap_32(val); ptr[0] = val; @@ -872,8 +872,8 @@ void MachOWriter::InitMem(const Constant *C, void *Addr, intptr_t Offset, break; } case Type::DoubleTyID: { - uint64_t val = *cast<ConstantFP>(PC)->getValueAPF().convertToAPInt(). - getRawData(); + uint64_t val = cast<ConstantFP>(PC)->getValueAPF().convertToAPInt(). + getZExtValue(); if (TD->isBigEndian()) val = ByteSwap_64(val); ptr[0] = val; |