Skip to content
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

Fix CaptureManager's shared mutex #979

Merged
merged 3 commits into from
Feb 15, 2023

Conversation

davidd-lunarg
Copy link
Contributor

Unify DX12/Vulkan CaptureManager mutex use
Replace CaptureManager's util::ShareMutex with std::shared_mutex
Rename CaptureManager::state_mutex_ to api_call_mutex_

Modify D3D12CaptuerManager to acquire the excluse API call lock at the
entry point of API calls that may activate trimming. These API calls are
`IDXGISwapChain::Present` and `IDXGISwapChain1::Present1`. This brings
the DX12 lock usage in line with Vulkan's.
Switch `CaptureManager::state_mutex_` from `gfxrecon::util::SharedMutex`
to `std::shared_mutex`. `gfxrecon::util::SharedMutex` had known issues
and was removed.
Rename `CaptureManager::state_mutex_` to
`CaptureManager::api_call_mutex_`--along with the associated locking
methods--to better match intended purpose. This mutex is used to block
API calls from being executed or processed during trimmed state writing.
@ci-tester-lunarg
Copy link

CI gfxreconstruct build queued with queue ID 12719.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 2385 running.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 2385 failed.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build queued with queue ID 12838.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 2386 running.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 2386 failed.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build queued with queue ID 20979.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 2417 running.

@ci-tester-lunarg
Copy link

CI gfxreconstruct build # 2417 passed.

@davidd-lunarg davidd-lunarg merged commit 0bd854a into LunarG:dev Feb 15, 2023
@davidd-lunarg davidd-lunarg deleted the davidd-fix-shared-mutex branch February 15, 2023 21:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants