diff --git a/src/dawn_native/metal/BackendMTL.mm b/src/dawn_native/metal/BackendMTL.mm index d25069885d..48bbb4b2fa 100644 --- a/src/dawn_native/metal/BackendMTL.mm +++ b/src/dawn_native/metal/BackendMTL.mm @@ -296,15 +296,16 @@ namespace dawn_native { namespace metal { if (IsGPUCounterSupported(*mDevice, MTLCommonCounterSetTimestamp, {MTLCommonCounterTimestamp})) { + bool enableTimestampQuery = true; + +#if defined(DAWN_PLATFORM_MACOS) // Disable timestamp query on macOS 10.15 on AMD GPU because WriteTimestamp // fails to call without any copy commands on MTLBlitCommandEncoder. This issue // has been fixed on macOS 11.0. See crbug.com/dawn/545 - BOOL enableTimestampQuery = !gpu_info::IsAMD(GetPCIInfo().vendorId); -#if defined(DAWN_PLATFORM_MACOS) - // TODO(crbug.com/dawn/940): Disable timestamp query on macOS 11.0+. Need to - // figure out what to do with dstOffset alignment on that system. - enableTimestampQuery &= !IsMacOSVersionAtLeast(11); + enableTimestampQuery &= + !(gpu_info::IsAMD(GetPCIInfo().vendorId) && IsMacOSVersionAtLeast(11)); #endif + if (enableTimestampQuery) { mSupportedFeatures.EnableFeature(Feature::TimestampQuery); }