]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
The definition of type Addr has moved to VEX and
authorFlorian Krohm <florian@eich-krohm.de>
Wed, 31 Dec 2014 12:11:15 +0000 (12:11 +0000)
committerFlorian Krohm <florian@eich-krohm.de>
Wed, 31 Dec 2014 12:11:15 +0000 (12:11 +0000)
the resteer callback has changed (VEX r3050). Track those changes.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@14840

coregrind/m_translate.c
include/pub_tool_basics.h

index 386465733e2abfd1074ce6577f1e91dc103e9fa1..8f7b452d5507294c4123299a572b90d7a43abb9b 100644 (file)
@@ -855,9 +855,8 @@ static UInt needs_self_check ( void* closureV,
    Chasing across them obviously defeats the redirect mechanism, with
    bad effects for Memcheck, Helgrind, DRD, Massif, and possibly others.
 */
-static Bool chase_into_ok ( void* closureV, Addr64 addr64 )
+static Bool chase_into_ok ( void* closureV, Addr addr )
 {
-   Addr               addr    = (Addr)addr64;
    NSegment const*    seg     = VG_(am_find_nsegment)(addr);
 
    /* Work through a list of possibilities why we might not want to
@@ -872,11 +871,8 @@ static Bool chase_into_ok ( void* closureV, Addr64 addr64 )
       goto dontchase;
 
 #  if defined(VG_PLAT_USES_PPCTOC) || defined(VGP_ppc64le_linux)
-   /* This needs to be at the start of its own block.  Don't chase. Re
-      ULong_to_Ptr, be careful to ensure we only compare 32 bits on a
-      32-bit target.*/
-   if (ULong_to_Ptr(addr64)
-       == (void*)&VG_(ppctoc_magic_redirect_return_stub))
+   /* This needs to be at the start of its own block.  Don't chase. */
+   if (addr == (Addr)&VG_(ppctoc_magic_redirect_return_stub))
       goto dontchase;
 #  endif
 
@@ -893,9 +889,9 @@ static Bool chase_into_ok ( void* closureV, Addr64 addr64 )
       Chasing into EX increases the number of EX translations from 21 to
       102666 causing a 7x runtime increase for "none" and a 3.2x runtime
       increase for memcheck. */
-   if (((UChar *)ULong_to_Ptr(addr))[0] == 0x44 ||   /* EX */
-       ((UChar *)ULong_to_Ptr(addr))[0] == 0xC6)     /* EXRL */
-     goto dontchase;
+   if (((UChar *)addr)[0] == 0x44 ||   /* EX */
+       ((UChar *)addr)[0] == 0xC6)     /* EXRL */
+      goto dontchase;
 #  endif
 
    /* well, ok then.  go on and chase. */
index ebb75d20f6a5317a3edba3e5c7b3d557bcbbd82d..0ff597e87d2909df633491f2d483eb1f3cf12c84 100644 (file)
@@ -43,7 +43,7 @@
    ------------------------------------------------------------------ */
 
 // VEX defines Char, UChar, Short, UShort, Int, UInt, Long, ULong, SizeT,
-// Addr32, Addr64, HWord, HChar, Bool, False and True.
+// Addr, Addr32, Addr64, HWord, HChar, Bool, False and True.
 #include "libvex_basictypes.h"
 
 // For varargs types
@@ -86,9 +86,6 @@
 typedef unsigned long          UWord;     // 32             64
 typedef   signed long           Word;     // 32             64
 
-// Addr is for holding an address.
-typedef UWord                  Addr;      // 32             64
-
 // Our equivalent of POSIX 'ssize_t':
 // - ssize_t is "used for a count of bytes or an error indication".
 typedef  Word                 SSizeT;     // 32             64