[llvm-branch-commits] [llvm-branch] r236784 - Merging r234977:

Tom Stellard thomas.stellard at amd.com
Thu May 7 15:09:34 PDT 2015


Author: tstellar
Date: Thu May  7 17:09:33 2015
New Revision: 236784

URL: http://llvm.org/viewvc/llvm-project?rev=236784&view=rev
Log:
Merging r234977:

------------------------------------------------------------------------
r234977 | lhames | 2015-04-15 00:46:01 -0400 (Wed, 15 Apr 2015) | 5 lines

[RuntimeDyld] Add casts to make delta computation 64-bit.

Hopefully this will fix the i686/msvc build failure described at:
http://bb.pgr.jp/builders/ninja-clang-i686-msc18-R/builds/803

------------------------------------------------------------------------

Modified:
    llvm/branches/release_36/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp

Modified: llvm/branches/release_36/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_36/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp?rev=236784&r1=236783&r2=236784&view=diff
==============================================================================
--- llvm/branches/release_36/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp (original)
+++ llvm/branches/release_36/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldMachO.cpp Thu May  7 17:09:33 2015
@@ -243,7 +243,8 @@ unsigned char *RuntimeDyldMachOCRTPBase<
 }
 
 static int64_t computeDelta(SectionEntry *A, SectionEntry *B) {
-  int64_t ObjDistance = A->ObjAddress - B->ObjAddress;
+  int64_t ObjDistance =
+    static_cast<int64_t>(A->ObjAddress) - static_cast<int64_t>(B->ObjAddress);
   int64_t MemDistance = A->LoadAddress - B->LoadAddress;
   return ObjDistance - MemDistance;
 }





More information about the llvm-branch-commits mailing list