Vulkan: Check for device loss in CheckAndUpdateCompletedSerials

Bug: chromium:1195645
Bug: chromium:1195693
Change-Id: I3c25a64af87a60f40030094dd73b13a035a7876c
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/46625
Auto-Submit: Corentin Wallez <cwallez@chromium.org>
Reviewed-by: Jiawei Shao <jiawei.shao@intel.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
This commit is contained in:
Corentin Wallez
2021-04-07 18:09:21 +00:00
committed by Commit Bot service account
parent 44771b3567
commit 6870e6d78d
13 changed files with 36 additions and 32 deletions

View File

@@ -245,7 +245,7 @@ TEST_P(D3D12DescriptorHeapTests, PoolHeapsInMultipleSubmits) {
EXPECT_TRUE(std::find(heaps.begin(), heaps.end(), heap) == heaps.end());
heaps.push_back(heap);
// CheckPassedSerials() will update the last internally completed serial.
mD3DDevice->CheckPassedSerials();
EXPECT_TRUE(mD3DDevice->CheckPassedSerials().IsSuccess());
// NextSerial() will increment the last internally submitted serial.
EXPECT_TRUE(mD3DDevice->NextSerial().IsSuccess());
}
@@ -258,7 +258,7 @@ TEST_P(D3D12DescriptorHeapTests, PoolHeapsInMultipleSubmits) {
ComPtr<ID3D12DescriptorHeap> heap = allocator->GetShaderVisibleHeap();
EXPECT_TRUE(heaps.front() == heap);
heaps.pop_front();
mD3DDevice->CheckPassedSerials();
EXPECT_TRUE(mD3DDevice->CheckPassedSerials().IsSuccess());
EXPECT_TRUE(mD3DDevice->NextSerial().IsSuccess());
}