1.1 --- a/src/sh4/sh4core.h Mon Dec 12 21:13:36 2011 +1000
1.2 +++ b/src/sh4/sh4core.h Fri Dec 23 08:20:17 2011 +1000
1.4 void FASTCALL sh4_raise_tlb_multihit( sh4vma_t );
1.5 void FASTCALL sh4_accept_interrupt( void );
1.7 +#define RAISE_TLB_ERROR(code, vpn) sh4_raise_tlb_exception(code, vpn)
1.8 +#define RAISE_MEM_ERROR(code, vpn) \
1.9 + MMIO_WRITE(MMU, TEA, vpn); \
1.10 + MMIO_WRITE(MMU, PTEH, ((MMIO_READ(MMU, PTEH) & 0x000003FF) | (vpn&0xFFFFFC00))); \
1.11 + sh4_raise_exception(code);
1.12 +#define RAISE_TLB_MULTIHIT_ERROR(vpn) sh4_raise_tlb_multihit(vpn)
1.14 +#ifdef HAVE_FRAME_ADDRESS
1.15 +#define SH4_EXCEPTION_EXIT() do{ *(((void * volatile *)__builtin_frame_address(0))+1) = exc; } while(0)
1.17 +#define SH4_EXCEPTION_EXIT() sh4_core_exit(CORE_EXIT_EXCEPTION)
1.21 * Helper method to update the SH4 registers for an exception, without
1.22 * touching the MMU registers. Mainly for use in shadow mode.