Correctly print backend type in DiscoverAdapters logs.
Bug: chromium:1348664 Change-Id: Id2eaf25a9f46b1f6614d80642dc7f8e8aef09b9e Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/100520 Auto-Submit: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Austin Eng <enga@chromium.org> Commit-Queue: Austin Eng <enga@chromium.org>
This commit is contained in:
parent
29d0a523f2
commit
bc93cbc2a2
|
@ -194,9 +194,9 @@ ResultOrError<Ref<AdapterBase>> InstanceBase::RequestAdapterInternal(
|
||||||
|
|
||||||
MaybeError result = DiscoverAdaptersInternal(&vulkanOptions);
|
MaybeError result = DiscoverAdaptersInternal(&vulkanOptions);
|
||||||
if (result.IsError()) {
|
if (result.IsError()) {
|
||||||
dawn::WarningLog()
|
dawn::WarningLog() << absl::StrFormat(
|
||||||
<< "Skipping Vulkan Swiftshader adapter because initialization failed: "
|
"Skipping Vulkan Swiftshader adapter because initialization failed: %s",
|
||||||
<< result.AcquireError()->GetFormattedMessage();
|
result.AcquireError()->GetFormattedMessage());
|
||||||
return Ref<AdapterBase>(nullptr);
|
return Ref<AdapterBase>(nullptr);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -297,9 +297,9 @@ bool InstanceBase::DiscoverAdapters(const AdapterDiscoveryOptionsBase* options)
|
||||||
MaybeError result = DiscoverAdaptersInternal(options);
|
MaybeError result = DiscoverAdaptersInternal(options);
|
||||||
|
|
||||||
if (result.IsError()) {
|
if (result.IsError()) {
|
||||||
dawn::WarningLog() << "Skipping " << options->backendType
|
dawn::WarningLog() << absl::StrFormat(
|
||||||
<< " adapter because initialization failed: "
|
"Skipping %s adapter because initialization failed: %s", FromAPI(options->backendType),
|
||||||
<< result.AcquireError()->GetFormattedMessage();
|
result.AcquireError()->GetFormattedMessage());
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue