64-bit cleanness: lots more replacing of UInt with UWord as necessary.
git-svn-id: svn://svn.valgrind.org/valgrind/trunk@2920 a5019735-40e9-0310-863c-91ae7b9d1cf9
diff --git a/memcheck/mac_needs.c b/memcheck/mac_needs.c
index 87b5826..e6231a0 100644
--- a/memcheck/mac_needs.c
+++ b/memcheck/mac_needs.c
@@ -227,7 +227,7 @@
}
break;
case Freed: case Mallocd: case UserG: case Mempool: {
- UInt delta;
+ SizeT delta;
UChar* relative;
UChar* kind;
if (ai->akind == Mempool) {
@@ -236,7 +236,7 @@
kind = "block";
}
if (ai->rwoffset < 0) {
- delta = (UInt)(- ai->rwoffset);
+ delta = (SizeT)(- ai->rwoffset);
relative = "before";
} else if (ai->rwoffset >= ai->blksize) {
delta = ai->rwoffset - ai->blksize;
@@ -246,8 +246,8 @@
relative = "inside";
}
VG_(message)(Vg_UserMsg,
- " Address 0x%x is %d bytes %s a %s of size %d %s",
- a, delta, relative, kind,
+ " Address 0x%x is %llu bytes %s a %s of size %d %s",
+ a, (ULong)delta, relative, kind,
ai->blksize,
ai->akind==Mallocd ? "alloc'd"
: ai->akind==Freed ? "free'd"
@@ -412,8 +412,7 @@
for the --workaround-gcc296-bugs kludge. */
static Bool is_just_below_ESP( Addr esp, Addr aa )
{
- if ((UInt)esp > (UInt)aa
- && ((UInt)esp - (UInt)aa) <= VG_GCC296_BUG_STACK_SLOP)
+ if (esp > aa && (esp - aa) <= VG_GCC296_BUG_STACK_SLOP)
return True;
else
return False;
diff --git a/memcheck/mc_clientreqs.c b/memcheck/mc_clientreqs.c
index 5f6df2e..d27541d 100644
--- a/memcheck/mc_clientreqs.c
+++ b/memcheck/mc_clientreqs.c
@@ -146,7 +146,7 @@
/* OK - maybe it's a mempool, too? */
mp = (MAC_Mempool*)VG_(HT_get_node)(MAC_(mempool_list),
- (UInt)vg_cgbs[i].start,
+ (UWord)vg_cgbs[i].start,
(void*)&d);
if(mp != NULL) {
if(mp->chunks != NULL) {
@@ -197,14 +197,14 @@
ok = MC_(check_writable) ( arg[1], arg[2], &bad_addr );
if (!ok)
MC_(record_user_error) ( tid, bad_addr, True );
- *ret = ok ? (UInt)NULL : bad_addr;
+ *ret = ok ? (UWord)NULL : bad_addr;
break;
case VG_USERREQ__CHECK_READABLE: /* check readable */
ok = MC_(check_readable) ( arg[1], arg[2], &bad_addr );
if (!ok)
MC_(record_user_error) ( tid, bad_addr, False );
- *ret = ok ? (UInt)NULL : bad_addr;
+ *ret = ok ? (UWord)NULL : bad_addr;
break;
case VG_USERREQ__DO_LEAK_CHECK: