Add workaround to blit depth to depth in D3D12 T2T

Workaround for T2T depth copy failed with non-zero array layers for
d32s8 format on Intel D3D driver 31.0.101.4091.

Bug: dawn:1083

Change-Id: I9368f81ded765c5af4f132eb7f1032e695e16875
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/121161
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Hao Li <hao.x.li@intel.com>
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
Li Hao 2023-02-24 01:17:58 +00:00 committed by Dawn LUCI CQ
parent 8bd09f33e1
commit fa5cda877f
1 changed files with 11 additions and 0 deletions

View File

@ -536,6 +536,17 @@ void Adapter::SetupBackendDeviceToggles(TogglesState* deviceToggles) const {
}
}
// This workaround is needed on Intel Gen12LP GPUs with driver >= 30.0.101.4091.
// See http://crbug.com/dawn/1083 for more information.
if (gpu_info::IsIntelGen12LP(vendorId, deviceId)) {
const gpu_info::DriverVersion kDriverVersion = {30, 0, 101, 4091};
if (gpu_info::CompareWindowsDriverVersion(vendorId, GetDriverVersion(), kDriverVersion) !=
-1) {
deviceToggles->Default(Toggle::UseBlitForDepthTextureToTextureCopyToNonzeroSubresource,
true);
}
}
// Currently these workarounds are only needed on Intel Gen9.5 and Gen11 GPUs.
// See http://crbug.com/1237175 and http://crbug.com/dawn/1628 for more information.
if ((gpu_info::IsIntelGen9(vendorId, deviceId) && !gpu_info::IsSkylake(deviceId)) ||