Delete Dawn's adapter blocklist

It is the embedder's responsibility to check and block adapters
based on the adapter info.

Bug: 41479499
Change-Id: I4a74a30a85e92c633fb4f3a7ea680aea3585c933
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/170564
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
diff --git a/include/dawn/native/DawnNative.h b/include/dawn/native/DawnNative.h
index 74749b1..f0a9ffe 100644
--- a/include/dawn/native/DawnNative.h
+++ b/include/dawn/native/DawnNative.h
@@ -140,7 +140,6 @@
 
     BackendValidationLevel backendValidationLevel = BackendValidationLevel::Disabled;
     bool beginCaptureOnStartup = false;
-    bool enableAdapterBlocklist = false;
 
     WGPULoggingCallback loggingCallback = nullptr;
     void* loggingCallbackUserdata = nullptr;
@@ -180,9 +179,6 @@
     // Enable debug capture on Dawn startup
     void EnableBeginCaptureOnStartup(bool beginCaptureOnStartup);
 
-    // Enable / disable the adapter blocklist.
-    void EnableAdapterBlocklist(bool enable);
-
     uint64_t GetDeviceCountForTesting() const;
 
     // Returns the underlying WGPUInstance object.
diff --git a/src/dawn/native/DawnNative.cpp b/src/dawn/native/DawnNative.cpp
index 667ad23..7f88beb 100644
--- a/src/dawn/native/DawnNative.cpp
+++ b/src/dawn/native/DawnNative.cpp
@@ -157,10 +157,9 @@
 bool DawnInstanceDescriptor::operator==(const DawnInstanceDescriptor& rhs) const {
     return (nextInChain == rhs.nextInChain) &&
            std::tie(additionalRuntimeSearchPathsCount, additionalRuntimeSearchPaths, platform,
-                    backendValidationLevel, beginCaptureOnStartup, enableAdapterBlocklist) ==
+                    backendValidationLevel, beginCaptureOnStartup) ==
                std::tie(rhs.additionalRuntimeSearchPathsCount, rhs.additionalRuntimeSearchPaths,
-                        rhs.platform, rhs.backendValidationLevel, rhs.beginCaptureOnStartup,
-                        rhs.enableAdapterBlocklist);
+                        rhs.platform, rhs.backendValidationLevel, rhs.beginCaptureOnStartup);
 }
 
 // Instance
@@ -208,10 +207,6 @@
     mImpl->EnableBeginCaptureOnStartup(beginCaptureOnStartup);
 }
 
-void Instance::EnableAdapterBlocklist(bool enable) {
-    mImpl->EnableAdapterBlocklist(enable);
-}
-
 uint64_t Instance::GetDeviceCountForTesting() const {
     return mImpl->GetDeviceCountForTesting();
 }
diff --git a/src/dawn/native/Instance.cpp b/src/dawn/native/Instance.cpp
index 76945fa..beb67c6 100644
--- a/src/dawn/native/Instance.cpp
+++ b/src/dawn/native/Instance.cpp
@@ -229,7 +229,6 @@
 
         mBackendValidationLevel = dawnDesc->backendValidationLevel;
         mBeginCaptureOnStartup = dawnDesc->beginCaptureOnStartup;
-        mEnableAdapterBlocklist = dawnDesc->enableAdapterBlocklist;
 
         mLoggingCallback = dawnDesc->loggingCallback;
         mLoggingCallbackUserdata = dawnDesc->loggingCallbackUserdata;
@@ -525,14 +524,6 @@
     return mBeginCaptureOnStartup;
 }
 
-void InstanceBase::EnableAdapterBlocklist(bool enable) {
-    mEnableAdapterBlocklist = enable;
-}
-
-bool InstanceBase::IsAdapterBlocklistEnabled() const {
-    return mEnableAdapterBlocklist;
-}
-
 void InstanceBase::SetPlatform(dawn::platform::Platform* platform) {
     if (platform == nullptr) {
         mPlatform = mDefaultPlatform.get();
diff --git a/src/dawn/native/Instance.h b/src/dawn/native/Instance.h
index f6c7d2c..830083d 100644
--- a/src/dawn/native/Instance.h
+++ b/src/dawn/native/Instance.h
@@ -124,11 +124,6 @@
     void EnableBeginCaptureOnStartup(bool beginCaptureOnStartup);
     bool IsBeginCaptureOnStartupEnabled() const;
 
-    // TODO(crbug.com/dawn/1495): Move this to a Toggle, perhaps on RequestAdapterOptions
-    // after Toggle refactor is complete.
-    void EnableAdapterBlocklist(bool enable);
-    bool IsAdapterBlocklistEnabled() const;
-
     // Testing only API that is NOT thread-safe.
     void SetPlatformForTesting(dawn::platform::Platform* platform);
     dawn::platform::Platform* GetPlatform();
@@ -202,7 +197,6 @@
     std::vector<std::string> mRuntimeSearchPaths;
 
     bool mBeginCaptureOnStartup = false;
-    bool mEnableAdapterBlocklist = false;
     BackendValidationLevel mBackendValidationLevel = BackendValidationLevel::Disabled;
 
     wgpu::LoggingCallback mLoggingCallback = nullptr;
diff --git a/src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp b/src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp
index 36916e3..cf1fb21 100644
--- a/src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp
+++ b/src/dawn/native/d3d12/PhysicalDeviceD3D12.cpp
@@ -102,21 +102,6 @@
     if (mAdapterType == wgpu::AdapterType::DiscreteGPU && mDeviceInfo.isUMA) {
         mAdapterType = wgpu::AdapterType::IntegratedGPU;
     }
-
-    if (GetInstance()->IsAdapterBlocklistEnabled()) {
-#if DAWN_PLATFORM_IS(I386)
-        DAWN_INVALID_IF(
-            mDeviceInfo.highestSupportedShaderModel >= 60,
-            "D3D12 x86 SM6.0+ adapter is blocklisted. See https://crbug.com/tint/1753.");
-
-        DAWN_INVALID_IF(
-            gpu_info::IsNvidia(mVendorId),
-            "D3D12 NVIDIA x86 adapter is blocklisted. See https://crbug.com/dawn/1196.");
-#elif DAWN_PLATFORM_IS(ARM)
-        return DAWN_VALIDATION_ERROR(
-            "D3D12 on ARM CPU is blocklisted. See https://crbug.com/dawn/884.");
-#endif
-    }
     return {};
 }