Core: Refactor a lot of timer work and fix a couple of bugs #11220
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of Changes
Refactor timers a bit to be a little less gross and more readable, also fix a couple of bugs.
Rationale behind Changes
There was a bunch of repeated code and legacy naming which wasn't obvious to what it was, which I wanted to sort out.
Also fixed the slight inaccuracy of counting time for framerates which weren't whole numbers.
Correct start cycles so they are on clock tick boundaries.
Disable sending V/H sync interrupts etc when SINT (this is the PCRTC initialization mode) is enabled, nothing happens during this sequence on a PS2.
Suggested Testing Steps
Test a whole bunch of things, make sure everything is fine.
Unfortunately I don't think anything is fixed :(
Double unfortunate this required a savestate bump.