From abdb30d874e2815a72a6d4855c7c465eb0e87f15 Mon Sep 17 00:00:00 2001 From: MooglyGuy Date: Fri, 19 Apr 2019 00:54:15 +0200 Subject: [PATCH] -unsp: Fixed Multiply Signed*Signed opcode in DRC. Fixes controls in jak_pooh. [Ryan Holtz] --- src/devices/cpu/unsp/unsp.cpp | 2 ++ src/devices/cpu/unsp/unspdrc.cpp | 8 ++++---- src/mame/drivers/vii.cpp | 11 +++++------ 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/src/devices/cpu/unsp/unsp.cpp b/src/devices/cpu/unsp/unsp.cpp index 6c64eba3d50..bec95cafe71 100644 --- a/src/devices/cpu/unsp/unsp.cpp +++ b/src/devices/cpu/unsp/unsp.cpp @@ -226,6 +226,8 @@ void unsp_device::log_regs() void unsp_device::log_write(uint32_t addr, uint32_t data) { + if (m_log_ops == 0) + return; addr |= 0x80000000; fwrite(&addr, sizeof(uint32_t), 1, m_log_file); fwrite(&data, sizeof(uint32_t), 1, m_log_file); diff --git a/src/devices/cpu/unsp/unspdrc.cpp b/src/devices/cpu/unsp/unspdrc.cpp index d7ac50fb329..f2f8f409ee8 100644 --- a/src/devices/cpu/unsp/unspdrc.cpp +++ b/src/devices/cpu/unsp/unspdrc.cpp @@ -943,14 +943,14 @@ bool unsp_device::generate_opcode(drcuml_block &block, compiler_state &compiler, UML_TEST(block, I1, 0x00008000); UML_JMPc(block, uml::COND_Z, mul_opb_nohi); - UML_SHL(block, I0, I0, 16); - UML_SUB(block, I2, I2, I0); + UML_SHL(block, I3, I0, 16); + UML_SUB(block, I2, I2, I3); UML_LABEL(block, mul_opb_nohi); UML_TEST(block, I0, 0x00008000); UML_JMPc(block, uml::COND_Z, mul_opa_nohi); - UML_SHL(block, I1, I1, 16); - UML_SUB(block, I2, I2, I1); + UML_SHL(block, I3, I1, 16); + UML_SUB(block, I2, I2, I3); UML_LABEL(block, mul_opa_nohi); UML_SHR(block, mem(&m_core->m_r[REG_R4]), I2, 16); diff --git a/src/mame/drivers/vii.cpp b/src/mame/drivers/vii.cpp index e9e19146ffe..6e5e7691e91 100644 --- a/src/mame/drivers/vii.cpp +++ b/src/mame/drivers/vii.cpp @@ -81,7 +81,7 @@ "SunPlus PA7801" ( known as Sunplus SPG110? ) - see spg110.cpp instead - "GCM394" (this is clearly newer, has extra opcodes, different internal map etc. also scaling and higher resolutions based on Spongebob) + "GCM394" (this is clearly newer, has extra opcodes, different internal map etc. also scaling and higher resolutions based on Spongebob) - see sunplus_gcm394.cpp instead Status: @@ -100,12 +100,11 @@ jak_wall, jak_sdoo: Game seems unhappy with NVRAM, clears contents on each boot. jak_pooh: - In the 'Light Tag' minigame (select the rock) you can't move left with the DRC (ok with -nodrc) - and the game usually softlocks when you find a friend (with or without DRC) + In the 'Light Tag' minigame (select the rock) the game usually softlocks when you find a friend (with or without DRC) jak_disf: - shows corrupt logo on first boot with no valid nvram (possibly hardware does too, or layer disable?) + Shows corrupt logo on first boot with no valid nvram (possibly hardware does too, or layer disable?) jak_nick: - channel chasers (first game) title screen background should be blue, not the current pattern (possible layer disable?) + Channel chasers (first game) title screen background should be blue, not the current pattern (possible layer disable?) vii: When loading a cart from file manager, sometimes MAME will crash. @@ -122,7 +121,7 @@ Justice League : press UP, DOWN, LEFT, BT3 on the JAKKS logo in that order, quickly, to get test menu WWE : press UP, BT1, BT2 together during startup logos - Disney Friends, MS Pacman, WallE, Batman (and some other HotGen GameKKeys) for test mode, hold UP, + Disney Friends, MS Pacman, WallE, Batman (and some other HotGen GameKeys) for test mode, hold UP, press A, press DOWN during startup TODO: