Skip to content

Commit

Permalink
srcclean and cleanup (nw)
Browse files Browse the repository at this point in the history
  • Loading branch information
Vas Crabb committed Oct 28, 2018
1 parent 112bce1 commit 8250177
Show file tree
Hide file tree
Showing 71 changed files with 751 additions and 737 deletions.
6 changes: 6 additions & 0 deletions docs/source/techspecs/layout_files.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1055,6 +1055,12 @@ The following views will be automatically generated:
play games that don't automatically rotate the display for the second player.
The screen will be displayed at its physical aspect ratio, with rotation
applied.
* If the system has exactly two emulated screens, MAME will generate a view
showing the second screen above the first screen with a small gap between
them. The second screen will be rotated by 180 degrees. This view can be
used to play a dual-screen two-player game on a "cocktail table" cabinet with
a single screen. The screens will be displayed at their physical aspect
ratios, with rotation applied.
* If the system has exactly two emulated screens and no view in the internal or
external layouts shows all screens, or if the system has more than two
emulated screens, MAME will generate views with the screens arranged
Expand Down
66 changes: 33 additions & 33 deletions hash/mac_hdflop.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,37 +2,37 @@
<!DOCTYPE softwarelist SYSTEM "softwarelist.dtd">
<softwarelist name="mac_hdflop" description="Macintosh High Density Disk images">

<!-- S/N: Z93350-001A -->
<software name="clarisw">
<description>ClarisWorks (Swedish)</description>
<year>1993</year>
<publisher>Claris</publisher>
<info name="version" value="2.0" />
<part name="flop1" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 1).img" size="1474560" crc="25da86b7" sha1="99e9fa57e0d7d03fb89611745bd04b4d7c4af998" offset="0" />
</dataarea>
</part>
<part name="flop2" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 2).img" size="1474560" crc="76e73be8" sha1="46921d446169d949b37879f6cbbdfb802323b7ef" offset="0" />
</dataarea>
</part>
<part name="flop3" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 3).img" size="1474560" crc="8e2dbabc" sha1="6b2b982348874be31899b6b2bace55518e5e9477" offset="0" />
</dataarea>
</part>
<part name="flop4" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 4).img" size="1474560" crc="9ad039ef" sha1="18777ffd48cb9a016b169e38cf867f81367271b0" offset="0" />
</dataarea>
</part>
<part name="flop4" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 5).img" size="1474560" crc="f74f6289" sha1="b60aae3606fec538dc60ba15bbec47e3da607a65" offset="0" />
</dataarea>
</part>
</software>
<!-- S/N: Z93350-001A -->
<software name="clarisw">
<description>ClarisWorks (Swedish)</description>
<year>1993</year>
<publisher>Claris</publisher>
<info name="version" value="2.0" />
<part name="flop1" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 1).img" size="1474560" crc="25da86b7" sha1="99e9fa57e0d7d03fb89611745bd04b4d7c4af998" offset="0" />
</dataarea>
</part>
<part name="flop2" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 2).img" size="1474560" crc="76e73be8" sha1="46921d446169d949b37879f6cbbdfb802323b7ef" offset="0" />
</dataarea>
</part>
<part name="flop3" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 3).img" size="1474560" crc="8e2dbabc" sha1="6b2b982348874be31899b6b2bace55518e5e9477" offset="0" />
</dataarea>
</part>
<part name="flop4" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 4).img" size="1474560" crc="9ad039ef" sha1="18777ffd48cb9a016b169e38cf867f81367271b0" offset="0" />
</dataarea>
</part>
<part name="flop4" interface="floppy_3_5">
<dataarea name="flop" size="1474560">
<rom name="clarisworks 2.0 (swe) (disk 5).img" size="1474560" crc="f74f6289" sha1="b60aae3606fec538dc60ba15bbec47e3da607a65" offset="0" />
</dataarea>
</part>
</software>

</softwarelist>
2 changes: 1 addition & 1 deletion src/devices/bus/bbc/exp/mertec.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Mertec Compact Companion
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Mertec_CompactComp.html
http://chrisacorns.computinghistory.org.uk/8bit_Upgrades/Mertec_CompactComp.html
**********************************************************************/

Expand Down
10 changes: 4 additions & 6 deletions src/devices/bus/hp_dio/hp98265a.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,12 @@

DEFINE_DEVICE_TYPE_NS(HPDIO_98265A, bus::hp_dio, dio16_98265a_device, "hp98265a", "HP98265A SCSI S16 Interface")

namespace bus {
namespace hp_dio {
namespace bus { namespace hp_dio {

static void scsi_devices(device_slot_interface &device)
{
device.option_add("cdrom", NSCSI_CDROM);
device.option_add("harddisk", NSCSI_HARDDISK);
device.option_add("cdrom", NSCSI_CDROM);
device.option_add("harddisk", NSCSI_HARDDISK);
}

void dio16_98265a_device::mb87030_scsi_adapter(device_t *device)
Expand Down Expand Up @@ -299,5 +298,4 @@ WRITE_LINE_MEMBER(dio16_98265a_device::dmar0_w)

}

}
}
} } // namespace bus::hp_dio
4 changes: 2 additions & 2 deletions src/devices/bus/hp_dio/hp_dio.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,11 +257,11 @@ void dio16_device::install_memory(offs_t start, offs_t end,
switch (m_prgwidth) {
case 16:
m_prgspace->install_readwrite_handler(start, end, rhandler,
whandler);
whandler);
break;
case 32:
m_prgspace->install_readwrite_handler(start, end, rhandler,
whandler, 0xffffffff);
whandler, 0xffffffff);
break;
default:
fatalerror("DIO: Bus width %d not supported\n", m_prgwidth);
Expand Down
4 changes: 2 additions & 2 deletions src/devices/bus/hp_hil/hlekbd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,7 @@ int hle_hp_ipc_device::hil_poll()
return frames;

m_hp_hil_mlc->hil_write(m_device_id16 | 0x40); // Keycode Set 1, no coordinate data
while (!m_fifo.empty()) {
while (!m_fifo.empty()) {
m_hp_hil_mlc->hil_write(m_device_id16 | m_fifo.dequeue());
frames++;
}
Expand All @@ -490,7 +490,7 @@ int hle_hp_itf_device::hil_poll()
LOG("KBD HAVE DATA\n");
frames++;
m_hp_hil_mlc->hil_write(m_device_id16 | 0x40); // Keycode Set 1, no coordinate data
while (!m_fifo.empty()) {
while (!m_fifo.empty()) {
m_hp_hil_mlc->hil_write(m_device_id16 | m_fifo.dequeue());
frames++;
}
Expand Down
2 changes: 1 addition & 1 deletion src/devices/bus/hp_hil/hlemouse.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ int hle_hp_46060b_device::hil_poll()
frames+=2;
}

while (!m_fifo.empty()) {
while (!m_fifo.empty()) {
m_hp_hil_mlc->hil_write(m_device_id16 | m_fifo.dequeue());
frames++;
}
Expand Down
6 changes: 3 additions & 3 deletions src/devices/cpu/m6502/oxavix.lst
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ brk_xav_imp
else
{
PC = read_arg(0xfffa);
PC = set_h(PC, read_arg(0xfffb));
PC = set_h(PC, read_arg(0xfffb));
}
}

Expand All @@ -86,7 +86,7 @@ brk_xav_imp
else
{
PC = read_arg(0xfffe);
PC = set_h(PC, read_arg(0xffff));
PC = set_h(PC, read_arg(0xffff));
}
}

Expand Down Expand Up @@ -122,4 +122,4 @@ xavlda_idy
}
A = read_special(TMP+Y);
set_nz(A);
prefetch();
prefetch();
6 changes: 3 additions & 3 deletions src/devices/cpu/m6502/oxavix2000.lst
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ adcl3_acc
read_pc_noinc();
do_adc((m_l & 0xff000000) >> 24);
prefetch();

stal0_acc
read_pc_noinc();
m_l = (m_l & 0xffffff00) | (A & 0xff); // TODO: flags
Expand Down Expand Up @@ -241,7 +241,7 @@ lpa1_acc
read_pc_noinc();
A = (m_pa & 0x00ff00) >> 8; // TODO: Flags?
prefetch();

spa2_acc
read_pc_noinc();
m_pa = (m_pa & 0x00ffff) | (A << 16); // TODO: Flags?
Expand Down Expand Up @@ -341,7 +341,7 @@ cmppa_imp
sbcpa_imp
do_sbc(read_full_data_sp(m_pa+Y));
prefetch();

orapb_imp
fatalerror("unhandled opcode %02x%04x: %02x\n", m_codebank, PPC, inst_state);
read_pc_noinc();
Expand Down
6 changes: 3 additions & 3 deletions src/devices/cpu/m6502/xavix.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,11 @@ class xavix_device : public m6502_device {
virtual space_config_vector memory_space_config() const override;

address_space_config m_special_data_config;
address_space *m_special_data_space;
address_space *m_special_data_space;
address_space_config m_lowbus_config;
address_space_config m_extbus_config;
address_space *m_lowbus_space;
address_space *m_extbus_space;
address_space *m_lowbus_space;
address_space *m_extbus_space;

uint8_t read_special(uint16_t adr);

Expand Down
80 changes: 40 additions & 40 deletions src/devices/cpu/m6502/xavix2000.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,51 +25,51 @@
some of the documented but 'undocumented' opcodes on the 6502 to have additonal
meaning for one specific function on startup
this just seems to be some very buggy checksum code where the games don't even care about the result...
(actually it looks like some games might be using it as a PRNG seed?)
a is 80 when entering here?
01BC37: A0 3F ldy #$3f
01BC39: B2 clr a // clear acculuator
01BC3A: 1B spa0 a // store 'accumulator' into byte 0 of PA 'address' register
01BC3B: 9B spa2 a // store 'accumulator' into byte 2 of PA 'address' register
-- loop point 2
01BC3C: 98 tya // y -> a (3f on first run of loop)
01BC3D: 5B spa1 a // store 'accumulator' into byte 1 of PA 'address' register (003f00 on first loop?)
-- loop point 1
01BC3E: A3 ldal0 a // read byte 0 of 32-bit 'long' register into accumulator
01BC3F: 73 adcpa // adc ($Address PA), y
01BC40: 83 stal0 a // store accumulator back in byte 0 of 32-bit 'long' register (even byte checksum?)
01BC41: FB incpa // increase 'address' register PA
01BC42: A7 ldal1 a // read byte 1 of 32-bit 'long' register into accumulator
01BC43: 73 adcpa // adc ($Address PA), y
01BC44: 87 stal1 a // store accumulator back in byte 0 of 32-bit 'long' register (odd byte checksum?)
01BC45: FB incpa // increase 'address' register PA
01BC46: D0 F6 bne $1bc3e // (branch based on PA increase, so PA must set flags?, probably overflows after 0xffff if upper byte is 'bank'? or at 0xff if this really is a mirror of the function below
01BC48: 88 dey // decrease y, which contained 3f at the start
01BC49: 10 F1 bpl $1bc3c // branch back to loop point 2 to reload counter
// contains the odd byte checksum once we drop out the loop
01BC4B: 8D FB 00 sta $00fb // store it in zero page memory
01BC4E: A3 ldal0 a // get the even byte checksum from byte 0 of 32-bit 'long' register
01BC4F: 8D FA 00 sta $00fa // store it in zero page memory
01BC52: 07 oral1 a // why do we want to do this? (routine below does it too)
01BC53: D0 03 bne $1bc58
01BC55: CE FA 00 dec $00fa
01BC58: 80 retf
this just seems to be some very buggy checksum code where the games don't even care about the result...
(actually it looks like some games might be using it as a PRNG seed?)
a is 80 when entering here?
01BC37: A0 3F ldy #$3f
01BC39: B2 clr a // clear acculuator
01BC3A: 1B spa0 a // store 'accumulator' into byte 0 of PA 'address' register
01BC3B: 9B spa2 a // store 'accumulator' into byte 2 of PA 'address' register
-- loop point 2
01BC3C: 98 tya // y -> a (3f on first run of loop)
01BC3D: 5B spa1 a // store 'accumulator' into byte 1 of PA 'address' register (003f00 on first loop?)
-- loop point 1
01BC3E: A3 ldal0 a // read byte 0 of 32-bit 'long' register into accumulator
01BC3F: 73 adcpa // adc ($Address PA), y
01BC40: 83 stal0 a // store accumulator back in byte 0 of 32-bit 'long' register (even byte checksum?)
01BC41: FB incpa // increase 'address' register PA
01BC42: A7 ldal1 a // read byte 1 of 32-bit 'long' register into accumulator
01BC43: 73 adcpa // adc ($Address PA), y
01BC44: 87 stal1 a // store accumulator back in byte 0 of 32-bit 'long' register (odd byte checksum?)
01BC45: FB incpa // increase 'address' register PA
01BC46: D0 F6 bne $1bc3e // (branch based on PA increase, so PA must set flags?, probably overflows after 0xffff if upper byte is 'bank'? or at 0xff if this really is a mirror of the function below
01BC48: 88 dey // decrease y, which contained 3f at the start
01BC49: 10 F1 bpl $1bc3c // branch back to loop point 2 to reload counter
// contains the odd byte checksum once we drop out the loop
01BC4B: 8D FB 00 sta $00fb // store it in zero page memory
01BC4E: A3 ldal0 a // get the even byte checksum from byte 0 of 32-bit 'long' register
01BC4F: 8D FA 00 sta $00fa // store it in zero page memory
01BC52: 07 oral1 a // why do we want to do this? (routine below does it too)
01BC53: D0 03 bne $1bc58
01BC55: CE FA 00 dec $00fa
01BC58: 80 retf
this is presumably meant to be similar to the function found in Namco
Nostalgia 2
// A is 80 on entry
// A is 80 on entry
09FFD8: A9 3F lda #$3f
09FFDA: 85 01 sta $01 // set upper bit of pointer at 0x0000 to 3f (it completely fails to initialize the ram at 00, we currently init it to ff, but should probably be 0?)
09FFDC: A0 00 ldy #$00 // clear inner loop counter
-- loop point 1 and 2
-- loop point 1 and 2
09FFDE: AD FA 00 lda $00fa // read current even byte checksum value from zero page ram fa (game also completely fails to initialize this)
09FFE1: 71 00 adc ($00), y // so 3f00 + y first outer loop, 3e00 + y second outer loop with y increasing in inner loop (add byte read to even checksum byte?)
09FFE3: 8D FA 00 sta $00fa // store even checksum at 0xfa in zero page ram
Expand All @@ -82,8 +82,8 @@
09FFF2: C6 01 dec $01 // decrease accumulator (started at 3f) (inner loop counter already 0 because it overflowed)
09FFF4: 10 E8 bpl $9ffde // branch back
// checksums are already in place after loop so no need to copy them like in above
09FFF6: 0D FA 00 ora $00fa // same weird 'or' call
// checksums are already in place after loop so no need to copy them like in above
09FFF6: 0D FA 00 ora $00fa // same weird 'or' call
--
09FFF9: D0 03 bne $9fffe
09FFFB: CE FA 00 dec $00fa
Expand Down
2 changes: 1 addition & 1 deletion src/devices/cpu/m6502/xavix2000.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ class xavix2000_device : public xavix_device {
O(adcl1_acc);
O(adcl2_acc);
O(adcl3_acc);

O(stal0_acc);
O(stal1_acc);
O(stal2_acc);
Expand Down
6 changes: 3 additions & 3 deletions src/devices/cpu/m68000/m68kmmu.h
Original file line number Diff line number Diff line change
Expand Up @@ -247,12 +247,12 @@ bool pmmu_atc_lookup(const uint32_t addr_in, const int fc, const int ptest, uint
for (int i = 0; i < MMU_ATC_ENTRIES; i++)
{
if (m_mmu_atc_tag[i] != atc_tag)
continue;
continue;

if (!m_mmu_tmp_rw && (m_mmu_atc_data[i] & M68K_MMU_ATC_WRITE_PR))
continue;
continue;
if (!m_mmu_tmp_rw && !(m_mmu_atc_data[i] & M68K_MMU_ATC_MODIFIED))
continue;
continue;

// read access or write access and not write protected
if (!ptest)
Expand Down
Loading

0 comments on commit 8250177

Please sign in to comment.