Show missing extension's name in the abort message

Extensions known in the vulkan header will be displayed with their
names to make debugging easier and the missing feature more visible.

Reviewed-by: Aaron Ruby <aruby@blackberry.com>
Acked-by: Yonggang Luo <luoyonggang@gmail.com>
Acked-by: Adam Jackson <ajax@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27246>
This commit is contained in:
Serdar Kocdemir
2024-07-04 00:02:15 +01:00
committed by Marge Bot
parent bd30892775
commit 6e3a5a2334
2 changed files with 2 additions and 1 deletions

View File

@@ -110,7 +110,7 @@ class VulkanExtensionStructs(VulkanWrapperGenerator):
# emitForEachStructExtension and not accessible here. Consequently, # emitForEachStructExtension and not accessible here. Consequently,
# this is a copy-paste from there and must be updated accordingly. # this is a copy-paste from there and must be updated accordingly.
# NOTE: No need for %% if no substitution is made. # NOTE: No need for %% if no substitution is made.
cgen.stmt("fprintf(stderr, \"Unhandled Vulkan structure type %d, aborting.\\n\", structType)") cgen.stmt("fprintf(stderr, \"Unhandled Vulkan structure type %s [%d], aborting.\\n\", string_VkStructureType(VkStructureType(structType)), structType)")
cgen.stmt("GFXSTREAM_ABORT(::emugl::FatalError(::emugl::ABORT_REASON_OTHER))") cgen.stmt("GFXSTREAM_ABORT(::emugl::FatalError(::emugl::ABORT_REASON_OTHER))")
cgen.stmt("return (%s)0" % self.extensionStructSizeRetType.typeName) cgen.stmt("return (%s)0" % self.extensionStructSizeRetType.typeName)

View File

@@ -447,6 +447,7 @@ using DlSymFunc = void* (void*, const char*);
{self.hostCommonExtraVulkanHeaders} {self.hostCommonExtraVulkanHeaders}
#include "goldfish_vk_private_defs.h" #include "goldfish_vk_private_defs.h"
#include "host-common/GfxstreamFatalError.h" #include "host-common/GfxstreamFatalError.h"
#include "vulkan/vk_enum_string_helper.h"
""" """
extensionStructsIncludeGuest = """ extensionStructsIncludeGuest = """