68k, some fixes for musashi

This commit is contained in:
kub 2024-03-10 01:26:06 +00:00
parent eac7a97e4f
commit 5adcc16534
5 changed files with 15 additions and 7 deletions

View file

@ -787,12 +787,12 @@ void m68k_set_cpu_type(unsigned int cpu_type)
/* ASG: removed per-instruction interrupt checks */
int m68k_execute(int num_cycles)
{
// notaz
m68ki_check_interrupts();
/* Make sure we're not stopped */
if(!CPU_STOPPED)
{
// notaz
m68ki_check_interrupts();
/* Set our pool of clock cycles available */
SET_CYCLES(num_cycles);
m68ki_initial_cycles = num_cycles;

View file

@ -71,8 +71,12 @@ typedef uint8_t UINT8;
#define uint32 unsigned int /* AWJ: changed from long to int */
/* signed and unsigned int must be at least 32 bits wide */
#define sint signed int
#define uint unsigned int
//#define sint signed int
//#define uint unsigned int
#define sint _sint
#define uint _uint
typedef signed int sint;
typedef unsigned int uint;
#if M68K_USE_64_BIT
@ -1537,7 +1541,7 @@ INLINE void m68ki_set_sr_noint_nosp(uint value)
INLINE void m68ki_set_sr(uint value)
{
m68ki_set_sr_noint(value);
if (GET_CYCLES() >= 0) // notaz
if (GET_CYCLES() > 0) // notaz
m68ki_check_interrupts();
}