if (sr_isError(sres))
return NULL;
- stack = (VgStack*)(AddrH)sr_Res(sres);
+ stack = (VgStack*)(Addr)sr_Res(sres);
aspacem_assert(VG_IS_PAGE_ALIGNED(szB));
aspacem_assert(VG_IS_PAGE_ALIGNED(stack));
( cszB, VKI_PROT_READ|VKI_PROT_WRITE|VKI_PROT_EXEC );
if (sr_isError(sres))
return 0;
- sb = (Superblock*)(AddrH)sr_Res(sres);
+ sb = (Superblock*)(Addr)sr_Res(sres);
// Mark this segment as containing client heap. The leak
// checker needs to be able to identify such segments so as not
// to use them as sources of roots during leak checks.
/* NOTREACHED */
sb = NULL; /* keep gcc happy */
} else {
- sb = (Superblock*)(AddrH)sr_Res(sres);
+ sb = (Superblock*)(Addr)sr_Res(sres);
}
}
vg_assert(NULL != sb);
a->sblocks_size * 2);
/* NOTREACHED */
}
- array = (Superblock**)(AddrH)sr_Res(sres);
+ array = (Superblock**)(Addr)sr_Res(sres);
for (i = 0; i < a->sblocks_used; ++i) array[i] = a->sblocks[i];
a->sblocks_size *= 2;
if (LIKELY(VG_(tt_fast)[cno].guest == (Addr)tst->arch.vex.VG_INSTR_PTR))
host_code_addr = VG_(tt_fast)[cno].host;
else {
- AddrH res = 0;
+ Addr res = 0;
/* not found in VG_(tt_fast). Searching here the transtab
improves the performance compared to returning directly
to the scheduler. */
/* Clear return area. */
two_words[0] = two_words[1] = 0;
- AddrH hcode = 0;
+ Addr hcode = 0;
Addr ip = VG_(get_IP)(tid);
Bool found = VG_(search_unredir_transtab)( &hcode, ip );
8 * tc_sector_szQ );
/*NOTREACHED*/
}
- sec->tc = (ULong*)(AddrH)sr_Res(sres);
+ sec->tc = (ULong*)(Addr)sr_Res(sres);
sres = VG_(am_mmap_anon_float_valgrind)
( N_TTES_PER_SECTOR * sizeof(TTEntry) );
N_TTES_PER_SECTOR * sizeof(TTEntry) );
/*NOTREACHED*/
}
- sec->tt = (TTEntry*)(AddrH)sr_Res(sres);
+ sec->tt = (TTEntry*)(Addr)sr_Res(sres);
for (i = 0; i < N_TTES_PER_SECTOR; i++) {
sec->tt[i].status = Empty;
*/
void VG_(add_to_transtab)( const VexGuestExtents* vge,
Addr64 entry,
- AddrH code,
+ Addr code,
UInt code_len,
Bool is_self_checking,
Int offs_profInc,
requested, a successful search can also cause the fast-caches to be
updated.
*/
-Bool VG_(search_transtab) ( /*OUT*/AddrH* res_hcode,
+Bool VG_(search_transtab) ( /*OUT*/Addr* res_hcode,
/*OUT*/UInt* res_sNo,
/*OUT*/UInt* res_tteNo,
Addr64 guest_addr,
setFastCacheEntry(
guest_addr, sectors[sno].tt[k].tcptr );
if (res_hcode)
- *res_hcode = (AddrH)sectors[sno].tt[k].tcptr;
+ *res_hcode = (Addr)sectors[sno].tt[k].tcptr;
if (res_sNo)
*res_sNo = sno;
if (res_tteNo)
N_UNREDIR_TT * UNREDIR_SZB);
/*NOTREACHED*/
}
- unredir_tc = (ULong *)(AddrH)sr_Res(sres);
+ unredir_tc = (ULong *)(Addr)sr_Res(sres);
}
unredir_tc_used = 0;
for (i = 0; i < N_UNREDIR_TT; i++)
*/
void VG_(add_to_unredir_transtab)( const VexGuestExtents* vge,
Addr64 entry,
- AddrH code,
+ Addr code,
UInt code_len )
{
Int i, j, code_szQ;
vg_assert(&dstP[code_len] <= (HChar*)&unredir_tc[unredir_tc_used]);
}
-Bool VG_(search_unredir_transtab) ( /*OUT*/AddrH* result,
+Bool VG_(search_unredir_transtab) ( /*OUT*/Addr* result,
Addr64 guest_addr )
{
Int i;
if (!unredir_tt[i].inUse)
continue;
if (unredir_tt[i].vge.base[0] == guest_addr) {
- *result = (AddrH)unredir_tt[i].hcode;
+ *result = (Addr)unredir_tt[i].hcode;
return True;
}
}
extern
void VG_(add_to_transtab)( const VexGuestExtents* vge,
Addr64 entry,
- AddrH code,
+ Addr code,
UInt code_len,
Bool is_self_checking,
Int offs_profInc,
UInt to_tteNo,
Bool to_fastEP );
-extern Bool VG_(search_transtab) ( /*OUT*/AddrH* res_hcode,
+extern Bool VG_(search_transtab) ( /*OUT*/Addr* res_hcode,
/*OUT*/UInt* res_sNo,
/*OUT*/UInt* res_tteNo,
Addr64 guest_addr,
extern
void VG_(add_to_unredir_transtab)( const VexGuestExtents* vge,
Addr64 entry,
- AddrH code,
+ Addr code,
UInt code_len );
extern
-Bool VG_(search_unredir_transtab) ( /*OUT*/AddrH* result,
+Bool VG_(search_unredir_transtab) ( /*OUT*/Addr* result,
Addr64 guest_addr );
// SB profiling stuff
typedef unsigned long UWord; // 32 64
typedef signed long Word; // 32 64
-// Addr is for holding an address. AddrH was intended to be "Addr on the
-// host", for the notional case where host word size != guest word size.
-// But since the assumption that host arch == guest arch has become so
-// deeply wired in, it's a pretty pointless distinction now.
+// Addr is for holding an address.
typedef UWord Addr; // 32 64
-typedef UWord AddrH; // 32 64
// Our equivalents of POSIX 'size_t' and 'ssize_t':
// - size_t is an "unsigned integer type of the result of the sizeof operator".