Commit Graph

52 Commits

Author SHA1 Message Date
Connor McLaughlin ea051c6d5f Everything: Get rid of wx entirely from the Qt build 2022-05-22 13:58:56 +01:00
Connor McLaughlin 850deed6c1 HwRegs: Swap wxString desc() for std::string 2022-04-15 08:15:40 +01:00
refractionpcsx2 3d43293a5d DMA: Correctly emulate QWC 0 on NORMAL transfers 2020-12-02 20:00:02 +00:00
refractionpcsx2 c78b5b706d MFIFO: Refactor of some of the VIF/GIF MFIFO functionality. Centralised the MFIFO resume function which should have been separate anyway.
Added some more memory address safeguards.
Logging now makes a bit more sense to look at.
2018-05-30 01:29:23 +01:00
refraction 35b5e6a923 GIF:
-Implemented GIF_MODE Masking fixed the All Star Pro Wrestling series slowness/hanging.

DMA: 
-Standardize the IPU and SIF dma's to use the standard chain handling in hw.c, fixed up some DMA resuming stuff in the forementioned units, VIF, GIF and SPR.

-Added some warnings for DMA stall control which isn't implemented, hopefully somebody will find a game that does it so we can add/test it :)

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@5915 96395faa-99c1-11dd-bbfe-3dabce05a288
2014-02-26 22:34:02 +00:00
refraction@gmail.com e3fead7f09 microVU:
- Fixed up the T/D Bit handling properly this time (or at least much better).
- Moved the interrupt outside of the recompiled code.

VU Interpreter:
-Fixed the T/D Bit handling when the interrupt wasn't enabled.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@5587 96395faa-99c1-11dd-bbfe-3dabce05a288
2013-03-11 21:54:05 +00:00
refraction@gmail.com 8d0f6701b7 microVU/VU Int: Implemented T-Bit/D-Bit handling on microVU.
-Dreamworks Over The Hedge actually requires this to load.  Interpreter kind of had it right, but didn't stop the VU on these flags, causing the graphics to look bad and hang on the start button, works fine now.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@5583 96395faa-99c1-11dd-bbfe-3dabce05a288
2013-03-09 11:03:59 +00:00
refraction 96ef86f560 - Standardized DMA Source chains, all DMA's now act exactly the same (within reason) Explanation for this in Hw.cpp. Consequently this fixed a hack id done for FFX videos (Not the one there is a game fix for)
- Slight tweak to Path3 masking, an overlooked situation where Path3 can wait between GIFTags.
- Improved the stability of MFIFO on both sides greatly for games such at Tekken Tag (which boots again) Gran Turismo 4 and FF7 Dirge of Cerberus.

I'm expecting *Something* to break, so please report it here if something does, please make sure it is THIS revision.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4035 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-11-19 16:29:28 +00:00
Jake.Stine 5fd2cf97d3 Made some minor tweaks to SIF to test some theories and fix some broken-looking code -- please report any regressions. Also commented some of SIF and IPU stuff. :)
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3812 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-09-20 12:47:17 +00:00
Jake.Stine 27a3f11278 Remove some code from DMAC.h and into LegacyDmac.cpp (these changes are mostly related to the new dmac prep on the other branch, but I'm doing them here to help keep major refactoring differences and merge conflicts to a minimum between the two branches).
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3710 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-08-31 21:22:39 +00:00
Jake.Stine 003da7d287 MAJOR: All new hwRead and hwWrite handlers (expect regressions). Details:
* Writes via 16 and 8 bit ops now use 32-bit read/modify/write operations by default; which should enable nearly complete support for all such operations (instead of the formerly spotty coverage before).
 * Eliminated almost all former 8/16-bit specific register operations.  All code shares the same 32 bit handlers now.
 * Completely revamped the developer trace logs for hardware registers!  *ALL* registers are logged now, complete with address, name, and value being read/written (and nicely formatted!).
 * Handlers are now fully page-based using templated functions (minor speedup)


git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3704 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-08-31 05:22:26 +00:00
Jake.Stine 1cac8d3948 * Added subdivided content to the u128 type (changed it from a struct to a union, added _u32[4], _u16[8], etc).
* Added ToString methods to the u128 type.
* Bugfixes for the FastFormat string utilities, namely when writing UTF8 content via the UTF16 formatter.
* MSVC: Removed obsolete disabling of unsigned/signed mismatch warning (4018)

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3703 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-08-31 05:14:00 +00:00
Jake.Stine bda94b16cd General emulator memory work, regarding my new policy that most (or all) cpu and hardware registers should be standard globals, as it makes our lives a lot easier in general (and their memory footprint is small so it won't adversely affect the virtual memory availability of the host operating systems). Details:
* Removed the hacky g_pVU1 pointer, which required VU1 cpu registers to be part of VU0.  Replaced it with a standard VU1 variable (mimics all other CPU registers, which are standard static vars).  We were using translation functions/tables for all VU0 memory operations anyway, so this was a no-brainer.
 * Removed code from microVU that was only there to help deal with the fact that g_pVU1 was annoying.
 * Turned eeMem->HW into a static global array eeHw [64k].

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3692 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-08-27 03:21:16 +00:00
Jake.Stine a8e406523b Improved EE/VTLB memory management: Removes various psM/psR/psS/psH pointers and replaces them with a single unified eeMem pointer. Members of eeMem correspond to Main, Scratchpad, Hardware, etc. This simplifies the EE's memory allocation, improves compiler optimization, gets rid of some macro mess, and allows templated code to deduce the size of memory buffers automatically.
* Includes a minor tweak to DMAC.h - removed tDMA_TADR / tDMA_MADR / etc. and replaced them with a single tDMAC_ADDR class.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3644 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-08-16 15:57:01 +00:00
Jake.Stine 8375b0a989 Refactoring:
* Added __fi and __ri, which are abbreviations for __forceinline and __releaseinline.
 * Added some static qualifiers to functions in mVU, MMI ops, and others where appropriate.
 * Removed some unnecessary __fastcall qualifiers (since GCC gets funny sometimes when you combine __fastcall and inlining).
 * Made _1mb, _16mb, _1gb values common to all emulation code (moved from newVif/mvu to Common.h) -- they're useful! :)

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3624 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-08-09 04:10:38 +00:00
Jake.Stine 61a4b537c4 IPU:
* Savestate mega-fix!  Removed all the old direct pointer types from decoder_t, which should fix the oddball random savestate crashes when IPU is active.
 * Moved iq/niq into decoder_t.
 * Moved all macroblocks into decoder_t (mb8, mb16, rgb16, rgb32).
 * Turned decoder.stride into a constant, since IPU can only decode in strides of 16 bytes only.
 * Added sanity checking to the ipu0_fifo stuff (was formerly g_nIPU0Data, etc).
 * Added some SSE moves to the Idct (very minor optimization).  There's a completely SSE from-ground-up implementation provided by newer versions of libmpeg2 that we should probably look into later, rather than rolling our own.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3587 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-08-01 21:50:59 +00:00
sudonim1 be9e225468 Fix unintentional alteration of tDMAC_STAT in r3550.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3552 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-07-22 17:21:13 +00:00
Jake.Stine 8d07e78b86 Unified the three DmaExec functions into one. :)
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3550 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-07-22 13:25:48 +00:00
Jake.Stine bc849cc042 Merge const qualifiers and cleanups from ReorderingMTGS: Includes the VIF DIRECT changes, which seem to be stable this time. ;)
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3549 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-07-22 12:20:11 +00:00
Jake.Stine 575e1ceb46 * Converted SPR.cpp and hwMFIFOWrite to use memcpy_qwc in the place of memcpy_fast.
* Fix a bug in my merge of the new MTGS code that caused crashes on some games (PATH1 queue bug).
* Added assertion checks to hwMFIFOWrite for qwc alignment and a SPR_LOG for null ringbuffer addresses (if a game specifies an invalid physical address).

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3533 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-07-19 05:40:35 +00:00
arcum42 93937901c5 pcsx2: Rearrange dmaGetAddr a bit.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3301 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-06-25 10:49:20 +00:00
arcum42 26c497ceea pcsx2: Added back a few headers. A non POD-safe argument was fixed. Commented out some unused variables. And added a few helper functions for later.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3300 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-06-25 09:18:14 +00:00
refraction a481875fb1 Apologies... Monkey problems, I'm sure you understand.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3287 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-06-24 15:29:25 +00:00
refraction b911ce1443 Game fixes:
- Batman Returns Issue 709 . 
- Fixed flashing in Sega Superstars Tennis. 
- Clawed back some of the speed loss from the XGKick delays.

Detailed changes:
- CALL Tag DMAs that contain invalid next tag addresses ignore the call (Batman started sending corrupt information from invalid addresses)
- VU1 now flushes any pending transfers if it's trying to send another and doesnt process any packed/list regs
- Batman was checking for OPH to be high, this was a timing thing, something id completely got rid of accidently (same for APATH)
- XGKick will no longer queue if PATH3 is interrupted

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3285 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-06-24 14:55:57 +00:00
refraction 26fece9510 Summary of fixes
Games
- Resident Evil Dead Aim flickering graphics fixed.
- Flatout games should now boot everytime (instead of randomly)
- Sega Superstar Tennis flashing fixed
- Destruction Derby graphics fixed (NTSC confirmed, PAL unsure)
- Tenchu Fatal Shadows flickering textures fixed, Issue 748
- Spyro Hero's Tail should boot again, Issue 746

General Info
- General reworking of the GS paths with all paths prioritizing more correctly.
- XGKICK can stall if another GS transfer is in progress
- Major reworking of Path3 masking, could still be combined with normal Path3 transfers, but lets get it working first :P
- Taken in to account a few conditions which could have caused VIF to lock up/crash when stalling on ends.
- Unreversed GIF and SPR and VIF so its the normal way round
- all DMA paths should now resume correctly after being stopped by hardware
- GIF FIFO now actually transfers stuff :P
- VIF CMD's simulated by the length of the interrupts at the end.

Phew, i think that's everything :S

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@3274 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-06-22 23:10:40 +00:00
arcum42 5d7facfa15 Get the database reader working in Linux.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2985 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-05-12 10:25:43 +00:00
Jake.Stine 70d47bf240 Copyright 2010 : PCSX2 and plugins! (notable exception: didn't update copyright info in any Gabest plugins)
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2937 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-05-03 14:08:02 +00:00
sudonim1 4457fe40fc Removed all trailing whitespace in *.c *.cpp *.h because it irritates me.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2897 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-25 00:31:27 +00:00
sudonim1 0fa4a5e433 Reinstated 0x10000000 limit on uninstalled memory map for DMA. Removed scratchpad support from toSPR/fromSPR address translation (this is documented as absent).
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2892 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-24 20:21:09 +00:00
refraction 662d589217 Improved my previous fix, Psychonaughts exhibited behaviour sudo mentioned (data not being grabbed from VU) so added a seperate SPR handler.
Removed an old check which is useless now and added a new replacement one.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2890 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-24 18:59:31 +00:00
refraction e99837abaf Fix for Neo Contra to stop crashes and DMA spam
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2889 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-24 17:22:22 +00:00
sudonim1 d97484a008 Oops, lost the quadword alignment in dmaGetAddr
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2887 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-22 16:44:21 +00:00
sudonim1 5643a95a0e For some reason we're getting a lot of 0x2XXXXXXX addresses in DMA. No games seem to break because of this but it's very noisy. Putting the mask back in dmaGetAddr for now for a little peace and quiet. (Maybe it's even right. The high bits could be handled by the bus.)
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2884 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-22 00:34:05 +00:00
sudonim1 a21fb4b984 Map uninstalled main memory (>32MB). I can't see any suggestion in the manuals that accessing these addresses generates a bus error or tlb miss (and they are in the bios default tlb initialisation), so I'm assuming that it acts as write only memory for both DMA and normal accesses. The write-only implementation is a little sketchy for DMA, but it's very unlikely to matter in practice.
Changed dmaGetAddr to not lookup addresses in the TLB.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2883 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-22 00:11:53 +00:00
refraction f01e10fc9a -Rewrote the DMA checking functions as per the manual specs so certain situations can alter the DMA's while busy.
-Improved DMA Queuing slightly, less "all over the place" code.
-Jiggled some IPU bits around to clean up some clutter.
-Added the FFX and Digital Devil Saga video fixes as a Gamefix for now. Due to the delay involved, this causes other videos to terminate early, so now disabled by default.
-Added a load of logging for hardware in dev builds (also now label more correctly) and some bits for debugging IPU easier. Some are commented out, but can be enabled for testing.
-Made a small clarification in VIF

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2875 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-20 01:18:31 +00:00
ramapcsx2 d857fec233 Clear interrupts on double dma requests. Fixes the game Fahrenheit (Indigo Prophecy).
Thanks to "blood" for the discovery :)

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2873 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-19 13:22:00 +00:00
refraction b1954edc3d - Better implementation of Reverse FIFO (Fatal Frame QWC Warning and more!)
- Improved handling of suspended DMA's, Also some traps in case DMA values are changed during suspend (please report if they don't start with 5 or 6)
- Better handling of GS Path priorities, this improves many Path3 Masked games such as Star Wars Episode 3, Gran Turismo 4 (slightly) and Videos like Digital Devil Saga/FFX
- Removed Voodoo Cycles
- Doesn't kill everything this time :P

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2853 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-04-15 00:32:58 +00:00
Jake.Stine a9165dfbf6 Added more info to GS window. Added const qualifiers to VIF and DMAC hw register structs/unions.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2529 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-01-27 15:25:40 +00:00
arcum42 6fdeb8d64a The usual Linux stuff. Plus one or two minor things that I hadn't had a chance to commit yet.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2513 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-01-24 14:49:07 +00:00
arcum42 3c132690f5 Sif: Revert one of the changes from r2490. Rework safeDmaGetAddr.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2509 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-01-24 08:10:20 +00:00
arcum42 bb3eda1524 More Sif stuff. Factor out a few functions. Played around with SIF0Dma & SIF1Dma a bit.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2496 96395faa-99c1-11dd-bbfe-3dabce05a288
2010-01-23 16:08:39 +00:00
arcum42 d7c0cb64d3 Revised dmaGetAddr. Fixed a thread error message.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2337 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-12-11 04:15:50 +00:00
arcum42 f3a2c44112 Did some work on HwWrite. Updated my structures in GS.h. Fixed some podsafe object warnings I'd missed previously.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2335 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-12-10 06:33:14 +00:00
arcum42 1b42c82faf A continuation of what I was doing in r2305.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2309 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-12-05 08:01:00 +00:00
arcum42 8a4d58ff76 More Tag stuff, mainly in Gif and HwWrite.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2305 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-12-04 07:01:27 +00:00
arcum42 6d99798fad Start actually using tDMA_TAG. (IPU.h now uses it, and all the transfer code got moved to it.)
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2291 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-12-03 13:01:17 +00:00
arcum42 867bc0fb17 Simplified transfers. Removed some extraneous code, and moved some enums to Dmac.h.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2273 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-11-29 14:06:38 +00:00
arcum42 fd141f08e7 Fixed the return result of FStype_ToString, added some missing GPL statements in a few files, merged a few redundant functions, and such...
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2267 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-11-28 08:13:49 +00:00
arcum42 b78944866b Fix a if statement I missed in the last commit, and add in a couple functions for printing structs.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2262 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-11-27 15:25:26 +00:00
arcum42 82a506cd04 I'm not trying that again anytime soon...
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2260 96395faa-99c1-11dd-bbfe-3dabce05a288
2009-11-27 07:54:40 +00:00