From 38b295de38515b8e05ea0232c4732e4088110b16 Mon Sep 17 00:00:00 2001 From: Corentin Wallez Date: Fri, 20 Sep 2019 17:40:53 +0000 Subject: [PATCH] Fix availability check for MTLCopyAllDevices This caused failure on macOS 10.11 because Dawn decided Metal is supported but would go ahead and reach an UNREACHABLE() block. BUG=chromium:1006181 Change-Id: I20739a058adaa60a71ec489e07b36ebf48ef871a Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/11420 Reviewed-by: Ryan Harrison Commit-Queue: Corentin Wallez --- src/dawn_native/metal/BackendMTL.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dawn_native/metal/BackendMTL.mm b/src/dawn_native/metal/BackendMTL.mm index 28565dd809..a52536e890 100644 --- a/src/dawn_native/metal/BackendMTL.mm +++ b/src/dawn_native/metal/BackendMTL.mm @@ -220,7 +220,7 @@ namespace dawn_native { namespace metal { std::vector> Backend::DiscoverDefaultAdapters() { std::vector> adapters; - if (@available(macOS 10.12, *)) { + if (@available(macOS 10.11, *)) { NSArray>* devices = MTLCopyAllDevices(); for (id device in devices) {