gfxstream: Avoid transfering VkAllocationCallbacks between guest and host
Some checks are pending
macOS-CI / macOS-CI (dri) (push) Waiting to run
macOS-CI / macOS-CI (xlib) (push) Waiting to run

Test: cvd create --gpu_mode=gfxstream_guest_angle

Reviewed-by: David Gilhooley <djgilhooley@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/42224>
This commit is contained in:
Jason Macnak 2026-06-09 14:12:08 -07:00 committed by Marge Bot
parent a8ae5b35c6
commit 4bfc03020a
3 changed files with 10 additions and 5 deletions

View file

@ -553,7 +553,7 @@ class VulkanType(object):
def getFullName(self) -> str:
if self.parent is None:
return self.paramName
return f"{self.parent.name}.{self.paramName}"
return f"{self.parent.name}.{self.paramName}"
def getProtectStreamFeature(self) -> Optional[str]:
key = self.getFullName()

View file

@ -8,6 +8,11 @@ from .common.vulkantypes import \
from .wrapperdefs import VulkanWrapperGenerator
from .wrapperdefs import STRUCT_EXTENSION_PARAM, STRUCT_EXTENSION_PARAM_FOR_WRITE, EXTENSION_SIZE_API_NAME
VULKAN_TYPES_THAT_ARE_NEVER_TRANSMITTED = [
"VkAllocationCallbacks",
]
class DeepcopyCodegen(VulkanTypeIterator):
def __init__(self, cgen, inputVars, poolVarName, rootVarName, prefix, skipValues=False):
self.cgen = cgen
@ -41,7 +46,7 @@ class DeepcopyCodegen(VulkanTypeIterator):
self.checked = False
def needSkip(self, vulkanType):
return False
return vulkanType.typeName in VULKAN_TYPES_THAT_ARE_NEVER_TRANSMITTED
def makeCastExpr(self, vulkanType):
return "(%s)" % (
@ -75,7 +80,7 @@ class DeepcopyCodegen(VulkanTypeIterator):
def onCompoundType(self, vulkanType):
if self.needSkip(vulkanType):
self.cgen.line("// TODO: Unsupported : %s" %
self.cgen.line("// Deepcopy intentionally skipped for `%s`" %
self.cgen.makeCTypeDecl(vulkanType))
return
@ -200,7 +205,7 @@ class DeepcopyCodegen(VulkanTypeIterator):
self.cgen.stmt("%s = %s(%s, %s)" % (
sizeVar, EXTENSION_SIZE_API_NAME, self.rootVarName, nextVar))
self.cgen.endWhile()
self.cgen.stmt("%s = nullptr" % rhs)
self.cgen.beginIf(sizeVar)

View file

@ -19,7 +19,7 @@ def deviceMemoryTransform(resourceTrackerVarName, structOrApiInfo, getExpr, getL
"size",
"typeIndex",
"typeBits",]
casts = {
"handle" : "VkDeviceMemory*",
"offset" : "VkDeviceSize*",