Avoid [MTLDevice sampleTimestamps] unless the extension is enabled

This callsite was missed in a previous CL:
https://dawn-review.googlesource.com/c/dawn/+/59041

Bug: chromium:1226078
Change-Id: I3829dc16a8ec3c7b7274bc6057030bdade598ade
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/61584
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
This commit is contained in:
Austin Eng 2021-08-11 15:36:35 +00:00 committed by Dawn LUCI CQ
parent 3229c5b46c
commit e02bb36a2a
1 changed files with 1 additions and 1 deletions

View File

@ -134,7 +134,7 @@ namespace dawn_native { namespace metal {
DAWN_TRY(mCommandContext.PrepareNextCommandBuffer(*mCommandQueue));
if (GetAdapter()->GetSupportedExtensions().IsEnabled(Extension::TimestampQuery)) {
if (IsExtensionEnabled(Extension::TimestampQuery)) {
// Make a best guess of timestamp period based on device vendor info, and converge it to
// an accurate value by the following calculations.
mTimestampPeriod =