Project

General

Profile

Actions

Emulator Issues #4844

closed

Testing/Review request for new-shadercache-uids

Added by NeoBrainX over 12 years ago.

Status:
Fixed
Priority:
Normal
Assignee:
Category:
GFX
% Done:

0%

Operating system:
N/A
Issue type:
Bug
Milestone:
Regression:
No
Relates to usability:
No
Relates to performance:
No
Easy:
No
Relates to maintainability:
No
Regression start:
Fixed in:

Description

Name of branch:
new-shadercache-uids

Purpose of code changes on this branch:
Reduce stuttering caused by redundant shader compilations and possibly fix some obscure graphical glitches.
The current pixel shader UID generator has two problems: a) It often assigns different UIDs to equivalent pipeline states (i.e. states which are emulated with the same shader code) b) In some cases, it assigned the same UID to different pipeline states (i.e. making us emulate the current state with a wrong shader).
This branch addresses both problems: It reduces the number of redundant shader compilations (case a) almost to a minimum (it's only one redundant compilations in the games I tested, compared to up to roughly 600 before). This should be very noticeable in games like F-Zero GX which supposedly have been very pixel shader intensive before. But it also reduced stuttering in many games perceptibly (only affects "loading scenes", for example the opening screen of Super Mario Sunshine or the menu/start of a race of Mario Kart Wii).
Additionally, this branches fixes case b. I'm not sure if any games where actually affected by this, it certainly is possible, though.

Another addition of this branch is the graphics setting "Enable Shader Debugging" (intentionally without a GUI option) which will make sure case b never gets hit with the new code (you never know ;)). I.e. if this branch causes any regressions, it's almost trivial to figure out what's broken.

When reviewing my code changes, please focus on:
I'm pretty confident that this doesn't break anything (and if it does, it's fairly trivial to debug with the EnableShaderDebugging setting mentioned above), so I don't really need any further testing for regressions.
Instead, I'd rather like people to test any games out there which show graphics glitches - i.e. all kinds of graphical issues apart from crashes or blackscreens. It's hard to describe, just take all those games with glitches which need less than 10 minutes to check ;)
For example, some Sonic game had various lighting issues IIRC, that would be an example.

Apart from that, I'd like to head about any differences in stuttering / game speed in particular about Red Steel 2, F-Zero GX, SSX Blur and any other games which suffer from heavy stuttering.

After the review, please merge to branch:
I'll just merge it myself to master once I've got enough feedback ;)
(still want to change a few little things before merging)

Actions #1

Updated by NeoBrainX over 12 years ago

NOTE: Disable pixel lighting when testing. It will not work, yet.

Actions #2

Updated by NeoBrainX over 12 years ago

NOTE2: I just want to stress that this won't magically fix all kinds of issues - but it might fix one or two of them. If you happen to find something which is fixed, please provide "before and after" screenshots :)

Actions #3

Updated by NeoBrainX over 12 years ago

Fwiw, I just tried Red Steel 2 and this branch GREATLY improves gameplay experience.. the fights are actually enjoyable now and have received a speed increase from sth like 7-25 FPS to a more solid 45 FPS.

Actions #4

Updated by cole.roddy over 12 years ago

Resident Evil 4 really takes benefit from this commit. It reduced stuttering greatly in the cut scenes, wich was caused by constant shader compilation activity. Only tested RE4 so far. Don't know about other games beyond the ones you've already mentioned.

Actions #5

Updated by hatarumoroboshi over 12 years ago

I've just tried Mario Kart Wii and Metroi Other M on a "3.0-94 dirty new shader cache uids" Dolphin version, but on my system E8400, hd4850, WinXP 32-bit I cannot see any benefit, Mario Kart still almost "freezes" when showing the circuit intro and Metroid Other M still stutters the same way during the tutorial. Where's the problem?

Actions #6

Updated by NeoBrainX over 12 years ago

It doesn't magically fix all stutters.

Actions #7

Updated by ExtremeDude2 over 12 years ago

I just compiled it to day :D

Actions #8

Updated by paavolah over 12 years ago

Sounds really good. All the work trying to tackle the stutters are really important. The random stutters / small freezes are the biggest issue with the emulator, in addition to the 4 wiimotes not working currently.

Actions #9

Updated by Sonicadvance1 over 12 years ago

Is this going to get pulled in soon, or is there still problems arising somewhere?

Actions #10

Updated by NeoBrainX over 12 years ago

Too lazy to finish it atm, it still needs to have some minor cleanups and per pixel lighting fixed.

Actions #11

Updated by NeoBrainX over 12 years ago

Alright, the branch should be good to go into master now. I'm waiting for [SS] to test some stuff then I'll merge it to master.

Actions #13

Updated by parlane over 11 years ago

  • Status changed from New to Fixed
Actions

Also available in: Atom PDF