Search
lxdream.org :: lxdream :: r950:cc1e88104360
lxdream 0.9.1
released Jun 29
Download Now
changeset950:cc1e88104360 lxdream-mem
parent949:d7833018931f
child951:63483914846f
authornkeynes
dateWed Jan 07 04:54:32 2009 +0000 (15 years ago)
branchlxdream-mem
Remove xlat_get_post_recovery - no longer used and doesn't work correctly anyway
src/sh4/xltcache.c
src/sh4/xltcache.h
1.1 --- a/src/sh4/xltcache.c Wed Jan 07 04:39:58 2009 +0000
1.2 +++ b/src/sh4/xltcache.c Wed Jan 07 04:54:32 2009 +0000
1.3 @@ -202,29 +202,6 @@
1.4 return result;
1.5 }
1.6
1.7 -xlat_recovery_record_t xlat_get_post_recovery( void *code, void *native_pc, gboolean with_terminal )
1.8 -{
1.9 - if( code != NULL ) {
1.10 - uintptr_t pc_offset = ((uint8_t *)native_pc) - ((uint8_t *)code);
1.11 - xlat_cache_block_t block = XLAT_BLOCK_FOR_CODE(code);
1.12 - uint32_t count = block->recover_table_size;
1.13 - xlat_recovery_record_t records = (xlat_recovery_record_t)(&block->code[block->recover_table_offset]);
1.14 - uint32_t posn;
1.15 - if( count > 0 && !with_terminal )
1.16 - count--;
1.17 - if( records[count-1].xlat_offset < pc_offset ) {
1.18 - return NULL;
1.19 - }
1.20 - for( posn=count-1; posn > 0; posn-- ) {
1.21 - if( records[posn-1].xlat_offset < pc_offset ) {
1.22 - return &records[posn];
1.23 - }
1.24 - }
1.25 - return &records[0]; // shouldn't happen
1.26 - }
1.27 - return NULL;
1.28 -}
1.29 -
1.30 xlat_recovery_record_t xlat_get_pre_recovery( void *code, void *native_pc )
1.31 {
1.32 if( code != NULL ) {
2.1 --- a/src/sh4/xltcache.h Wed Jan 07 04:39:58 2009 +0000
2.2 +++ b/src/sh4/xltcache.h Wed Jan 07 04:54:32 2009 +0000
2.3 @@ -101,22 +101,10 @@
2.4 void * FASTCALL xlat_get_code( sh4addr_t address );
2.5
2.6 /**
2.7 - * Retrieve the post-instruction recovery record corresponding to the given
2.8 - * native address, or NULL if there is no recovery code for the address.
2.9 - * @param code The code block containing the recovery table.
2.10 - * @param native_pc A pointer that must be within the currently executing
2.11 - * @param with_terminal If false, return NULL instead of the final block record.
2.12 - * return the first record before or equal to the given pc.
2.13 - * translation block.
2.14 - */
2.15 -struct xlat_recovery_record *xlat_get_post_recovery( void *code, void *native_pc, gboolean with_terminal );
2.16 -
2.17 -/**
2.18 * Retrieve the pre-instruction recovery record corresponding to the given
2.19 * native address, or NULL if there is no recovery code for the address.
2.20 * @param code The code block containing the recovery table.
2.21 * @param native_pc A pointer that must be within the currently executing
2.22 - * @param with_terminal If false, return NULL instead of the final block record.
2.23 * return the first record before or equal to the given pc.
2.24 * translation block.
2.25 */
.