Commit Graph

17 Commits

Author SHA1 Message Date
Aaron Giles
b4e4b1d3f0 Oops, remove accidentally checked-in makefile changes. 2008-04-09 13:23:25 +00:00
Aaron Giles
eeee1cb437 Rewrote core memory handlers as inline functions. These should be easier to
trace through in a debug build, yet should operate the same as before.

Created a complete set of functions for all databus sizes (8,16,32,64) and
all endiannesses. A few functions are redundant, but it is now very clear
which functions to use in which scenarios. It is also now possible to rely
on being able to access values of 8, 16, 32 or 64 bits via the built-in
accessors without fear of crashing.

Updated all cores using 8-bit handlers to explicitly call the 8-bit handlers
with the appropriate endianness.

Fixed a few games which were calling n-bit handlers directly to use the
generic forms. In the future, this is all the access drivers will have.
2008-04-09 07:31:47 +00:00
smf-
d485e8ed3c Fixed the SR masks for MTC0.
Added ability to test the instruction/data cache ram. The scratchpad and BIU register are now handled internally to the CPU.

All writes are performed with masks. SWL/SWR used to be implemented with two writes ( one byte and one word ) when writing three bytes, now it only ever performs one. Byte and Word writes use masks as they leave the rest of the register on the bus, which can be picked up by larger registers.

The read/write functions to use are cached when the SR bits are updated, as are the bad address masks.

Added coprocessor 1 & 3 support, though they don't do anything useful.

All loads now go through the delay pipeline, a lwl/lwr will grab the value out of the pipeline if it's updating the same register.

Added undocumented behaviour of BLEZ/BGTZ. The comparison for zero can be changed by specifying an alternate register in the RT field ( the documentation says you should always use register 0 ).

Restricted to 16 COP0 registers & generate an exception if any of the 5 for the MMU are used.

Added BCF/BCT instructions, although I have found no conditions that affect them yet.

Generates an exception if any MMU instructions are executed.

Sets the CE instruction for all exceptions, not just those involving a coprocessor. The bits of the opcode that specify the coprocessor are grabbed no matter what the instruction.

Added TAR register and BT bit in SR. When an exception occurs during a branch, BT determines whether it was taken or not. The TAR register gets set to the destination of the branch.

Fixed the BD bit when you are in a branch delay slot and you didn't take the branch, this shows up in the pipeline as !pc.

Fixed branches within a branch delay slot.

Multiply & divide instructions can be aborted if you write to HI/LO before reading the result.
Added data breakpoints, you don't appear to be able to set breakpoints on any of the addresses internal to the CPU.

Multiply/divide/GTE instructions can execute when an exception is taken, although the EPC indicates that it hasn't. The BIOS avoids rerunning GTE instructions as they are destructive, so you have to make sure they run.

Added bus error handling, PSXCPU is limited to 8mb of ram & any access outside this range will trigger an exception. I believe this is to be an internal limit.

Added CXD8611R as a specific CPU type, System 12 appears to allow more than 8mb of ram & it's possible that this is different.

Mapped out all instructions to either generate an exception or ignore bits.

Updated the disassembler to match the decoding.

Fixed disassembling of branch instructions in a branch delay slot.

Lui checks for a ori/addiu following and will show you the result.

Added step over/out support.

Fixed standalone disassembler.
2008-04-06 16:42:10 +00:00
Aaron Giles
4d5014585a From: Fabio Priuli
Subject: small fix to cpu.mak

Attached please find a small patch to include M68000 CPU only when you're 
compiling a build with the M68K. this is needed to e.g. compile tiny 
builds .
2008-03-13 15:45:39 +00:00
Aaron Giles
3a082a644f From: notaz [mailto:notasas@gmail.com]
Subject: patch for SVP (Sega Virtua Processor) emulation

hello,

this patch adds support for Sega Virtua Processor, to run
Genesis/MegaDrive version of Virtua Racing, intended to be used by
MESS. It consists of a CPU core SSP1601, and updates in megadriv.c:
* SSP1601 replaces SSP1610, as it has been confirmed by Stiletto and
other sources that SVP actually contains SSP1601. The current SSP1610
is placeholder only (nearly completely unimplemented) anyway.
* Changes in megadriv.c add a new driver for Genesis/MegaDrive+SVP
combination, also add SVP memory controller logic and memory map.

The diff has already been reviewed by Reip and SSP1610 removal was one
of his suggestions (SSP1610 is not used by any drivers).
2008-03-13 15:35:17 +00:00
Aaron Giles
0104d6ff63 From: Wilbert Pol [mailto:wilbert@jdg.info]
Subject: uPD7801, uPD78C05, and uPD78C06 cpu cores added to the uPD7810
cpu core

This patch adds basic support for the NEC uPD7801, uPD78C05, and  
uPD78C06 cpus to the uPD7810 cpu core.
2008-02-28 03:22:38 +00:00
Couriersud
9c460a6248 Makefile & build system update:
* verinfo: New syntax.
	verinfo now uses the following syntax: verinfo.exe -b windows|winui|mess. 
	Does not depend on compile time defines any longer.

* makefile will include - if it exists - src/osd/$(CROSS_BUILD_OSD)/build.mak.
	This was necessary to enable cross builds for winui. winui adds mkhelp to build tools and the rules for mkhelp thus had to be moved outside src/osd/winui/winui.mak

* Tested on Linux 64bit, Linux 32bit, Windows 32bit mingw, Windows 32bit MSVC

* Cross build environment to be posted to the list
2008-02-21 23:53:29 +00:00
Curt Coder
1424fce298 Added i8749 CPU type for MESS. 2008-02-19 17:54:47 +00:00
Aaron Giles
4db5afa87e From: Atari Ace [mailto:atari_ace@verizon.net]
Subject: [patch] CPU/SOUND independence fixes

Hi mamedev,

Here's some updates to the CPU/SOUND cores to improve build
independence.  While I was at it, I rescued the M65CE02 core from
bitrot hell (perhaps m65ce02.[ch] should just be deleted), and fixed
some MESS cores that were broken by the deprecat.h changes.
2008-02-05 17:21:27 +00:00
Aaron Giles
aa16ee779d Changed debugger-related code to be based off a new makefile define (DEBUGGER) which sets
a new compile-time define (ENABLE_DEBUGGER). This means that MAME_DEBUG no longer means
"enable debugger", it simply enables debugging features such as assertions and debug code
in drivers.

Also removed the various levels of opbase protection in memory.h and always just turned 
on full bounds checking.

Fixed build break due to missing ampoker.lay -> ampoker2.lay renaming.
2008-02-02 08:57:39 +00:00
Couriersud
06cf28a0e6 build environment:
* added checks for CROSS_BUILD=1 to omit building m68kmake.exe, verinfo.exe, png2bdc.exe and file2str
* enables building mame using mingw on linux
2008-01-27 20:19:32 +00:00
Aaron Giles
f44732e5af Added XTAL clocks to zaxxon.c.
Cleaned up jaguar driver:
 * proper video timing, configured by the chipset
 * 32-bit rendering, removing 16bpp hacks
 * support for borders
 * proper object processor timing, including multiple passes per line
 * added R3041 as a clone of the R3000
 * fixed XTALs based on documentation
2008-01-13 01:15:32 +00:00
Couriersud
190e262fb3 i8039.c/mario.c:
* fixed movd instructions
* add MB8884 and M58715 cpu types
* moved timer hack to M58715
* added ram_mask for internal ram access
* added R.A11 as 'M' to dasm flags
* added EA "IO" port
* mario now uses M58715 as sound cpu
2008-01-12 22:10:02 +00:00
Aaron Giles
ee9f88963c Copyright cleanup:
- removed years from copyright notices
 - removed redundant (c) from copyright notices
 - updated "the MAME Team" to be "Nicola Salmoria and the MAME Team"
2008-01-06 00:47:40 +00:00
Aaron Giles
df34329a47 Changes for MAME 0.121u3. 2007-12-17 16:39:40 +00:00
Aaron Giles
8a8ccc5949 Changes for MAME 0.121u1. 2007-12-17 16:33:33 +00:00
Aaron Giles
7b77f12186 Initial checkin of MAME 0.121. 2007-12-17 15:19:59 +00:00