Add GPU detection for WARP

Adds WARP to known vendor/device Ids so
tests can detect when MBR is being used.

BUG=dawn:463
TEST=dawn_end2end_tests

Change-Id: I19f16dfeb4839c5a7c0a993bab94d2b6ca4ca36d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/24680
Reviewed-by: Rafael Cintron <rafael.cintron@microsoft.com>
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Bryan Bernhart <bryan.bernhart@intel.com>
This commit is contained in:
Bryan Bernhart
2020-07-10 22:58:48 +00:00
committed by Commit Bot service account
parent 2afea0c671
commit 8c255acbe4
5 changed files with 12 additions and 1 deletions

View File

@@ -647,6 +647,10 @@ bool DawnTestBase::IsSwiftshader() const {
mParam.adapterProperties.deviceID);
}
bool DawnTestBase::IsWARP() const {
return gpu_info::IsWARP(mParam.adapterProperties.vendorID, mParam.adapterProperties.deviceID);
}
bool DawnTestBase::IsWindows() const {
#ifdef DAWN_PLATFORM_WINDOWS
return true;

View File

@@ -239,6 +239,7 @@ class DawnTestBase {
bool IsNvidia() const;
bool IsQualcomm() const;
bool IsSwiftshader() const;
bool IsWARP() const;
bool IsWindows() const;
bool IsLinux() const;

View File

@@ -43,7 +43,7 @@ TEST_P(D3D12SmallTextureTests, AlignSmallCompressedTexture) {
DAWN_SKIP_TEST_IF(!IsBCFormatSupported());
// TODO(http://crbug.com/dawn/282): Investigate GPU/driver rejections of small alignment.
DAWN_SKIP_TEST_IF(IsIntel() || IsNvidia());
DAWN_SKIP_TEST_IF(IsIntel() || IsNvidia() || IsWARP());
wgpu::TextureDescriptor descriptor;
descriptor.dimension = wgpu::TextureDimension::e2D;