-
Notifications
You must be signed in to change notification settings - Fork 926
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Latency tracker #4623
Closed
Closed
Latency tracker #4623
+1,843
−73
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
958b610
to
7127bbd
Compare
c894370
to
8bbb6f4
Compare
Matches std::vector.
We'll need this in more places.
Implements a basic latency sleep solution that is intended to work without requiring games to support any related vendor features. This alone is not enough to expose the Reflex API to applications via dxvk-nvapi, but since that relies on NV_low_latency2 specifics anyway, we are going to add an implementation based on that extension later with an extended interface.
NV latency sleep seems to be straight-up broken at a driver level.
dbb28e1
to
8c053a0
Compare
Closing, will make follow-up PR with full Reflex support since I mostly have that working locally now. |
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This isn't Reflex integration yet, but sort of serves as groundwork for it.
NV_low_latency2
requires us to pass frame IDs to queue submissions, and some markers will need to be submitted at different times due to internal threading, so we kind of need to pass a bunch of state and internal markers around anyway, which is already 90% of the work needed to support latency sleep in many (older) games.This PR adds this on top of
NV_low_latency2
as well as a homebrew latency sleep solution that's based on our internal timings. This can be enabled by settingdxvk.latencySleep = True
in the config file.The next step would be to add another implementation that consumes markers from the application (and handles all sorts of potential bugs) and implement the
ID3DLowLatencyDevice
interface for dxvk-nvapi.Obviously not tested very well, especially D3D9 is a mess.