Commit Graph

1684 Commits

Author SHA1 Message Date
smf-
dbb034ad61 PSX CPU: hookup debugger_exception_hook & debugger_interrupt_hook [smf] 2018-07-27 09:49:51 +01:00
David Haywood
f3537b3b30 tlcs870 updates (#3787)
* tlcs870 updates

* basic devcb3 stuff to make a start on the ports (nw)
2018-07-26 10:58:31 +10:00
ajrhacker
b4a0012777
Merge pull request #3785 from MoochMcGee/i386-fix
i386: Properly fix that detection check this time (nw)
2018-07-24 22:16:40 -04:00
AJR
87f729ce23 m6809: Disassembly tweaks
- Use FCB directive to represent illegal opcodes
- Remove unnecessary spaces for instructions without operands
2018-07-24 20:21:51 -04:00
Melissa Goad
668e583152 dsp16: Fixed a couple of typos pointed out by Coverity (nw) 2018-07-24 15:18:55 +02:00
Melissa Goad
66b65191d5 Fix tiny dead code bug (nw) 2018-07-24 13:25:18 +02:00
Melissa Goad
44dc0950c5 i386: Properly fix that detection check this time (nw) 2018-07-24 05:26:58 -05:00
ajrhacker
e658a261ef
Merge pull request #3776 from MoochMcGee/master5
i386: Fix a bug that could cause a relatively common CPU detection check to see a 386 as a 486
2018-07-23 10:55:59 -04:00
Vas Crabb
621106e577 Merge remote-tracking branch 'mainline/release0200' 2018-07-23 12:32:06 +10:00
Vas Crabb
ccfcb431d0 cherry-pick fixes from mainline and clean up some stuff (nw) 2018-07-23 12:29:25 +10:00
smf-
3527a722a1 fix for ambiguous call to overloaded function when using MSVC (nw) 2018-07-23 02:45:02 +01:00
Vas Crabb
47e045d545 (nw) clean up some superfluous semicolons, make constants static, fix const-qualified members 2018-07-23 10:26:49 +10:00
David Haywood
88b1546f30 Flesh out TLCS870 core (#3763)
* rewrote most of the execution for my tlcs870 core

* no longer the case (nw)

* note updates (nw)

* address concerns, const qualify more things where possible (nw)

* more const (nw)

* oops (nw)

* consistency (nw)
2018-07-23 10:24:10 +10:00
Melissa Goad
10094b242a i386: Fix a bug that could cause a relatively common CPU detection check to see a 386 as a 486 2018-07-22 18:21:42 -05:00
smf-
38369086a6 Take 2. Use include files to get class definition instead of relying purely on forward declarations to allow building on MSVC, solving the circular reference problem using forward declarations of own classes before the #include where necessary. (nw) 2018-07-22 20:21:20 +01:00
Vas Crabb
c0ab1c5aa4 (nw) srcclean and some cleanup:
* Make more #include guards follow standard format - using MAME_ as the prefix makes it easy to see which ones come from our code in a preprocessor dump, and having both src/devices/machine/foo.h and src/mame/machine/foo.h causes issues anyway
* Get #include "emu.h" out of headers - it should only be the first thing in a complilation unit or we get differences in behaviour with PCH on/off
* Add out-of-line destructors to some devices - it forces the compiler to instantiate the vtable in a certain location and avoids some non-deterministic compiler behaviours
2018-07-22 20:41:57 +10:00
smf-
f667051179 build with MSVC (nw) 2018-07-22 11:17:17 +01:00
smf-
06ee590873 appease msvc (nw) 2018-07-21 12:01:24 +01:00
smf-
28ab5679f2 You can't require a forward declared class (nw) 2018-07-21 11:18:35 +01:00
Robbbert
19ff23d2fd (nw) fixed the build. 2018-07-21 19:54:15 +10:00
mooglyguy
4d0feb2486 ps2sony: Checkpoint, nw 2018-07-21 10:07:00 +02:00
mooglyguy
eed782f1e3 ps2sony: Some basic VU1 support, major file reshuffling, nw 2018-07-21 10:07:00 +02:00
AJR
37918a690c cosmac.cpp: Clarify some minor stuff (nw) 2018-07-19 10:12:14 -04:00
AJR
13c663f17a cosmac.cpp: Interface overhaul (nw)
- Split execution of long branch/long skip instructions into two separate states
- Eliminate reset state
- Sample pushed EF lines at the right time
- Implement a few CDP1801 differences
- Correct disassembly of destinations for skip instructions
- SC callback also includes state of N lines for I/O instructions
- TPB callback added (not used yet)
- Callbacks can be configured through devcb3 bindings
2018-07-19 01:01:59 -04:00
mooglyguy
5db11a5e02 ps2sony: Checkpoint, nw 2018-07-17 18:14:24 +02:00
Melissa Goad
b33867d92a Avoid some unintended undefined behavior in devices/cpu/i386. Spotted by cppcheck (#3753)
* Avoid some unintended undefined behavior. Spotted by cppcheck

* Some more undefined behavior caught by cppcheck (nw)

* fixup (nw)
2018-07-17 21:58:03 +10:00
Vas Crabb
a28b2b5a19 remove lots of MCFG_ (nw) 2018-07-17 04:46:25 +10:00
Vas Crabb
f18c7cd65f Allow per-device internal layouts and remove some more MCFG_ macros.
Input and screen tags are now resolved relative to a layout's owner
device.

Easy way to demonstrate is with: mame64 intlc440 -tty ie15

Previously you'd only get the IE15 terminal's layout and you'd be unable
to use the INTELLEC 4/40 front panel.  Now you'll get the choice of
layouts from both the system and the terminal device in video options.
2018-07-16 16:26:01 +10:00
AJR
47a460a35a New skeleton device: Western Digital WD1007A ESDI hard disk controller [Al Kossow] 2018-07-14 18:15:42 -04:00
Vas Crabb
68dc93b74c more cleanup and removal of mcfg (nw) 2018-07-15 02:51:13 +10:00
AJR
bb9612f4b8 cosmac.cpp: More helper functions (nw) 2018-07-14 12:36:41 -04:00
Melissa Goad
73d05332ab Wow. I can't believe I missed this. (nw) 2018-07-15 00:56:11 +10:00
Melissa Goad
9540d7d944 Add a driver for the original iPhone. (#3742)
* Add ARM1176JZF-S CPU device and a driver for the original iPhone.
2018-07-15 00:24:48 +10:00
mooglyguy
cf34ccd3b4 ps2sony: Checkpoint. Adds a bunch of vector and parallel ops to the EE core, and skeleton GIF VIF1, and GS devices. 2018-07-14 04:00:29 +02:00
AJR
aeab957b52 cosmac: Fix disassembly; very minor cleanup (nw) 2018-07-13 20:03:27 -04:00
Vas Crabb
2c7e42261a witness the power of devcb3 to tear through boilerplate (in Taito C-Chip), also misc cleanup/MCFG_ reduction (nw) 2018-07-14 04:21:03 +10:00
AJR
233039edf7 Add dump of preprogrammed Z8671 MCU with BASIC/DEBUG interpreter 2018-07-11 22:48:32 -04:00
mooglyguy
03927c3426 ps2sony: Checkpoint, nw 2018-07-10 02:04:36 +02:00
Olivier Galibert
bad31ea61c Gross fix (nw) 2018-07-09 21:59:50 +02:00
mooglyguy
cc4867d092 Disable debug prints, nw 2018-07-07 19:55:23 +02:00
mooglyguy
4134ea509b ps2sony: checkpoint, nw 2018-07-07 19:55:23 +02:00
Vas Crabb
11b47cb003 remove more MCFG_ (nw) 2018-07-07 23:39:05 +10:00
smf-
b747b711bb fix building with clang 6.0.1 (nw) 2018-07-07 11:28:01 +01:00
Vas Crabb
c3fb11c2c9 devcb3
There are multiple issues with the current device callbacks:
* They always dispatch through a pointer-to-member
* Chained callbacks are a linked list so the branch unit can't predict the early
* There's a runtime decision made on the left/right shift direction
* There are runtime NULL checks on various objects
* Binding a lambda isn't practical
* Arbitrary transformations are not supported
* When chaining callbacks it isn't clear what the MCFG_DEVCB_ modifiers apply to
* It isn't possible to just append to a callback in derived configuration
* The macros need a magic, hidden local called devcb
* Moving code that uses the magic locals around is error-prone
* Writing the MCFG_ macros to make a device usable is a pain
* You can't discover applicable MCFG_ macros with intellisense
* Macros are not scoped
* Using an inappropriate macro isn't detected at compile time
* Lots of other things

This changeset overcomes the biggest obstacle to remving MCFG_ macros
altogether.  Essentially, to allow a devcb to be configured, call
.bind() and expose the result (a bind target for the callback).  Bind
target methods starting with "set" repace the current callbacks; methods
starting with "append" append to them.  You can't reconfigure a callback
after resolving it.  There's no need to use a macro matching the
handler signatures - use FUNC for everything.  Current device is implied
if no tag/finder is supplied (no need for explicit this).

Lambdas are supported, and the memory space and offset are optional.
These kinds of things work:
* .read_cb().set([this] () { return something; });
* .read_cb().set([this] (offs_t offset) { return ~offset; });
* .write_cb().set([this] (offs_t offset, u8 data) { m_array[offset] = data; });
* .write_cb().set([this] (int state) { some_var = state; });

Arbitrary transforms are allowed, and they can modify offset/mask for example:
* .read_cb().set(FUNC(my_state::handler)).transform([] (u8 data) { return bitswap<4>(data, 1, 3, 0, 2); });
* .read_cb().set(m_dev, FUNC(some_device::member)).transform([] (offs_t &offset, u8 data) { offset ^= 3; return data; });

It's possible to stack arbitrary transforms, at the cost of compile
time (the whole transform stack gets inlined at compile time).  Shifts
count as an arbitrary transform, but mask/exor does not.

Order of mask/shift/exor now matters.  Modifications are applied in the
specified order.  These are NOT EQUIVALENT:
* .read_cb().set(FUNC(my_state::handler)).mask(0x06).lshift(2);
* .read_cb().set(FUNC(my_state::handler)).lshift(2).mask(0x06);

The bit helper no longer reverses its behaviour for read callbacks, and
I/O ports are no longer aware of the field mask.  Binding a read
callback to no-op is not supported - specify a constant.  The GND and
VCC aliases have been removed intentionally - they're TTL-centric, and
were already being abused.

Other quirks have been preserved, including write logger only logging
when the data is non-zero (quite unhelpful in many of the cases where
it's used).  Legacy syntax is still supported for simple cases, but will
be phased out.  New devices should not have MCFG_ macros.

I don't think I've missed any fundamental issues, but if I've broken
something, let me know.
2018-07-07 02:40:29 +10:00
Robbbert
7285b74fc6 (nw) Fixed the build.... hopefully 2018-07-06 20:21:08 +10:00
Patrick Mackinlay
06700b3c52 clipper: minor bugfix (nw) (#3731)
This enables SoftPC to run.
2018-07-06 11:11:13 +02:00
mooglyguy
f3ccd1f7f2 -ps2sony: Various DMA and SIF bug fixes, initial OSDSYS ELF transfers to IOP now, but EE and IOP hang immediately thereafter. nw 2018-07-05 19:04:50 +02:00
Patrick Mackinlay
7bee6e6f1e interpro: CLIX boots (on the ip2000) (#3730)
Too many changes to describe in detail. A rewrite of the interrupt and dma code in the ioga, and fixes to the cpu and mmu were the most important things.
2018-07-05 16:22:05 +02:00
mooglyguy
cd4c3b694e ps2sony: Disable debug printing, nw 2018-07-05 13:32:59 +02:00
mooglyguy
ba4f99c559 ps2sony: Added skeleton DMAC, INTC, and SIF devices, nw 2018-07-05 13:14:17 +02:00