Skip to content

[Qcom 805] DX11 Could not switch resolution on AD650 using the vulkan.ad0805.so qcom driver #30

@leegao

Description

@leegao

dxvk fails to create swapchain on AD 650 when using other qcom drivers, culprit seems to be a failure to allocate memory:

GetAndroidHardwareBufferPropertiesANDROID
  in: device: VkDevice (handle) = 0xb40000793b435da0
  in: buffer: AHardwareBuffer* = 5b439bf0
  out: pProperties: VkAndroidHardwareBufferPropertiesANDROID*
    .allocationSize: VkDeviceSize = 0x1e8000
    .memoryTypeBits: uint32_t = 0xa
    .pNext(VkAndroidHardwareBufferFormatPropertiesANDROID)
      .format: VkFormat = 0x2c
      .externalFormat: uint64_t = 0x57
      .formatFeatures: VkFormatFeatureFlags = 0x3fd81
      .samplerYcbcrConversionComponents: VkComponentMapping
        .r: VkComponentSwizzle = 0x0
        .g: VkComponentSwizzle = 0x0
        .b: VkComponentSwizzle = 0x0
        .a: VkComponentSwizzle = 0x0
      .suggestedYcbcrModel: VkSamplerYcbcrModelConversion = 0x0
      .suggestedYcbcrRange: VkSamplerYcbcrRange = 0x1
      .suggestedXChromaOffset: VkChromaLocation = 0x1
      .suggestedYChromaOffset: VkChromaLocation = 0x1
CreateImage
  in: device: VkDevice (handle) = 0xb40000793b435da0
  in: pCreateInfo: VkImageCreateInfo*
    .flags: VkImageCreateFlags = 0x400
    .imageType: VkImageType = 0x1
    .format: VkFormat = 0x2c
    .extent: VkExtent3D
      .width: uint32_t = 0x320
      .height: uint32_t = 0x258
      .depth: uint32_t = 0x1
    .mipLevels: uint32_t = 0x1
    .arrayLayers: uint32_t = 0x1
    .samples: VkSampleCountFlagBits = 0x1
    .tiling: VkImageTiling = 0x0
    .usage: VkImageUsageFlags = 0x12
    .sharingMode: VkSharingMode = 0x0
    .queueFamilyIndexCount: uint32_t = 0x1
    .pQueueFamilyIndices[0]: uint32_t* = 0x0
    .initialLayout: VkImageLayout = 0x0
    .pNext(VkExternalMemoryImageCreateInfo)
      .handleTypes: VkExternalMemoryHandleTypeFlags = 0x400
    .pNext(UNKNOWN Unknown VkStructureType value. / 1000001002)
  in: pAllocator: VkAllocationCallbacks*
    .pUserData: void* = 0x0
    .pfnAllocation: PFN_vkAllocationFunction = 0xf72e8bd4
    .pfnReallocation: PFN_vkReallocationFunction = 0xf72e8bdc
    .pfnFree: PFN_vkFreeFunction = 0xf72e8be8
    .pfnInternalAllocation: PFN_vkInternalAllocationNotification = 0x0
    .pfnInternalFree: PFN_vkInternalFreeNotification = 0x0
  out: *pImage: VkImage = ab4548c0
DestroyImage
  in: device: VkDevice (handle) = 0xb40000793b435da0
  in: image: VkImage = ab4b1440
  in: pAllocator: VkAllocationCallbacks*
    .pUserData: void* = 0x0
    .pfnAllocation: PFN_vkAllocationFunction = 0xf72e8bd4
    .pfnReallocation: PFN_vkReallocationFunction = 0xf72e8bdc
    .pfnFree: PFN_vkFreeFunction = 0xf72e8be8
    .pfnInternalAllocation: PFN_vkInternalAllocationNotification = 0x0
    .pfnInternalFree: PFN_vkInternalFreeNotification = 0x0
GetImageMemoryRequirements
  in: device: VkDevice (handle) = 0xb40000793b435da0
  in: image: VkImage = ab4548c0
  out: pMemoryRequirements: VkMemoryRequirements*
    .size: VkDeviceSize = 0x0
    .alignment: VkDeviceSize = 0x0
    .memoryTypeBits[...]: uint32_t = '0x3'
AllocateMemory
  in: device: VkDevice (handle) = 0xb40000793b435da0
  in: pAllocateInfo: VkMemoryAllocateInfo*
    .allocationSize: VkDeviceSize = 0x1e8000
    .memoryTypeIndex: uint32_t = 0x1
    .pNext(VkImportAndroidHardwareBufferInfoANDROID)
      .buffer: AHardwareBuffer* = 0xb40000785b439bf0
    .pNext(VkMemoryDedicatedAllocateInfo)
      .image: VkImage (handle) = 0xb4000078ab4548c0
      .buffer: VkBuffer (handle) = 0x0
  in: pAllocator: VkAllocationCallbacks*
    .pUserData: void* = 0x0
    .pfnAllocation: PFN_vkAllocationFunction = 0xf72e8bd4
    .pfnReallocation: PFN_vkReallocationFunction = 0xf72e8bdc
    .pfnFree: PFN_vkFreeFunction = 0xf72e8be8
    .pfnInternalAllocation: PFN_vkInternalAllocationNotification = 0x0
    .pfnInternalFree: PFN_vkInternalFreeNotification = 0x0
  out: *pMemory: VkDeviceMemory = 0

with the log

2025-07-08 02:49:41.583  7918-7918  VkWrapper               Cat                                  E  Call to AllocateMemory with (device: 0xb4000077bb439eb0,pAllocateInfo: 0x7fce4108f8,pAllocator: 0xb4000078cb447540,pMemory: 0xb4000078cb447920) failed with result: -1000072003
2025-07-08 02:49:41.583  7918-7918  VkWrapper               Cat                                  E  AllocateMemory(_device, pAllocateInfo, pAllocator, pMemory) failed with -1000072003
2025-07-08 02:49:41.583  7918-7918  Wrapper                 Cat                                  E  wsi->AllocateMemory: -1000072003
2025-07-08 02:49:41.583  7918-7918  Wrapper                 Cat                                  E  info->create_mem: -1000072003
2025-07-08 02:49:41.583  7918-7918  VkWrapper               Cat                                  E  wrapper_DestroyBuffer: null buffer
2025-07-08 02:49:41.583  7918-7918  Wrapper                 Cat                                  E  wsi_create_image: -1000072003
2025-07-08 02:49:41.583  7918-7918  Wrapper                 Cat                                  E  x11_image_init: result = -1000072003

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions