Previous 199869 Revisions Next

r22014 Friday 22nd March, 2013 at 05:31:09 UTC by Fabio Priuli
(MESS) better fix for the pmac registers in SVP. thanks Arbee for noticing this veeeeeery
old out-of-bound access. I guess we originally had a single set of 12 registers...
nw.
[src/mess/machine]md_svp.c md_svp.h

trunk/src/mess/machine/md_svp.c
r22013r22014
8383{
8484   if (m_emu_status & SSP_PMC_SET)
8585   {
86      m_pmac_read[write ? reg + 6 : reg] = m_pmc.d;
86      if (write)
87         m_pmac_write[reg] = m_pmc.d;
88      else
89         m_pmac_read[reg] = m_pmc.d;
90
8791      m_emu_status &= ~SSP_PMC_SET;
8892      return 0;
8993   }
r22013r22014
155159      }
156160     
157161      // PMC value corresponds to last PMR accessed (not sure).
158      m_pmc.d = m_pmac_read[write ? reg + 6 : reg];
162      if (write)
163         m_pmc.d = m_pmac_write[reg];
164      else
165         m_pmc.d = m_pmac_read[reg];
159166     
160167      return d;
161168   }
trunk/src/mess/machine/md_svp.h
r22013r22014
5656
5757   UINT8 *m_iram; // IRAM (0-0x7ff)
5858   UINT8 *m_dram; // [0x20000];
59   UINT32 m_pmac_read[12];  // read modes/addrs for PM0-PM5
59   UINT32 m_pmac_read[6];  // read modes/addrs for PM0-PM5
6060   UINT32 m_pmac_write[6]; // write ...
6161   PAIR m_pmc;
6262   UINT32 m_emu_status;

Previous 199869 Revisions Next


© 1997-2024 The MAME Team