From 1b0cd0f1b10aed90719ee2a788a85c96758a4447 Mon Sep 17 00:00:00 2001 From: Eli Bendersky Date: Mon, 16 Jan 2012 09:31:10 +0000 Subject: A fix for the previous commit: "integer constant is too large for ‘long’ type" error on some 32-bit bots MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit llvm-svn: 148232 --- llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp') diff --git a/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp b/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp index 9ff95ff8b6e..54cb350552d 100644 --- a/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp +++ b/llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp @@ -183,9 +183,9 @@ void RuntimeDyldELF::resolveX86_64Relocation(StringRef Name, case ELF::R_X86_64_32S: { uint64_t Value = reinterpret_cast(Addr) + RE.Addend; // FIXME: Handle the possibility of this assertion failing - assert((RE.Type == ELF::R_X86_64_32 && !(Value & 0xFFFFFFFF00000000)) || + assert((RE.Type == ELF::R_X86_64_32 && !(Value & 0xFFFFFFFF00000000ULL)) || (RE.Type == ELF::R_X86_64_32S && - (Value & 0xFFFFFFFF00000000) == 0xFFFFFFFF00000000)); + (Value & 0xFFFFFFFF00000000ULL) == 0xFFFFFFFF00000000ULL)); uint32_t TruncatedAddr = (Value & 0xFFFFFFFF); uint32_t *Target = reinterpret_cast(TargetAddr); *Target = TruncatedAddr; -- cgit v1.2.3