GS/HW: Add continuous and oneshot ROV heuristics. - #14607
Conversation
ddd4694 to
cfdb79c
Compare
51289d8 to
817043a
Compare
|
Rebased. Dumps runs appears to be clear on VK, DX12, DX11, though it's hard to verify as many dumps have small differences. |
|
Drafting as there appear to be bugs after the rebase. |
lightningterror
left a comment
There was a problem hiding this comment.
Need to bump shader cache.
Thanks for the help! I assume this would resolve the quesion about the render pass shape also? |
79b67d6 to
8adba0c
Compare
|
Rebased and changed the draw config ROV flags to be more intuitive:
Also added the flags to the draw config outside of the PS selector. |
c47ed97 to
befc239
Compare
TellowKrinkle
left a comment
There was a problem hiding this comment.
I assume this would resolve the quesion about the render pass shape also?
Yes, that's the part where I switched it to render passes.
BTW I noticed something I missed in the Metal implementation so I fixed that
befc239 to
0d93e91
Compare
|
@TellowKrinkle Apologies, I didn't see your last push and ended up force pushing over it. I applied my fixes and yours as two temporary commits at the end. |
|
Tested by @kamfretoz to be working on Metal, so I squashed the temp commits into the Metal port commits. Keeping as draft until at least one dump run is redone. |
|
Dump run on VK appears to be clear. |
Separate code from RenderHW() into a separate function.
Use same procedure of unbinding as feedback loop layout (unbind texture if it's in the wrong layout). Avoids unnecessary unbinding.
Separate parts of SendHWDraw() into separate function. Closer to how DX12 handles feedback barriers.
Need to use these functions in other CPP files.
Backported from Metal shader.
Co-authored-by: TellowKrinkle
7031f05 to
fc12db8
Compare
Description of Changes
Adds heuristics to determine ROV usage:
Put render pass starting code in DX12/VK into a separate function.
Adds utility functions for doing coarse CPU rasterization of draws to cut down on copy overhead. Currently, only used for the ROV copies in oneshot mode.
Rationale behind Changes
Performance in some system/games are negatively impacted by using ROV continuously, so this attempts to provide less aggressive heuristics for such cases.
The coarse rasterization utilies could possibly be used for other copies such as in DX11 feedback. It might also be useful for reducing barriers with more accurate overlap detection.
Suggested Testing Steps
Use DX12/DX11/VK with ROV enabled in Settings>Graphics>Rendering. The default threshold can be edited in Settings>Graphics>Advanced>ROV Options. Performance testing would be helpful.
Currently, this has been tested with dump runs and performance tested on AMD (thanks @JordanTheToaster).
Did you use AI to help find, test, or implement this issue or feature?
Yes, to brainstorm some ideas for conservative ROV heuristics and reducing copy overhead.