diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2024-01-12 11:28:10 +0100 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2024-01-12 11:28:10 +0100 |
| commit | d6bfce9a5d7f2591746679a26603a3ad550271b6 (patch) | |
| tree | b73ee1c90912a8be033bd06896ab511c17a7aae5 /src | |
| parent | 328d5c6275b69edf336eac595fe2e41ab8410a65 (diff) | |
| download | box64-d6bfce9a5d7f2591746679a26603a3ad550271b6.tar.gz box64-d6bfce9a5d7f2591746679a26603a3ad550271b6.zip | |
[VULKAN] Added some more extensions (for #424)
Diffstat (limited to 'src')
| -rw-r--r-- | src/wrapped/generated/functions_list.txt | 6 | ||||
| -rw-r--r-- | src/wrapped/generated/wrappedvulkantypes.h | 3 | ||||
| -rw-r--r-- | src/wrapped/generated/wrapper.c | 7 | ||||
| -rw-r--r-- | src/wrapped/generated/wrapper.h | 3 | ||||
| -rw-r--r-- | src/wrapped/wrappedvulkan.c | 11 | ||||
| -rw-r--r-- | src/wrapped/wrappedvulkan_private.h | 40 |
6 files changed, 69 insertions, 1 deletions
diff --git a/src/wrapped/generated/functions_list.txt b/src/wrapped/generated/functions_list.txt index 6f3a362f..cd823750 100644 --- a/src/wrapped/generated/functions_list.txt +++ b/src/wrapped/generated/functions_list.txt @@ -509,6 +509,7 @@ #() iFpwp #() iFpii #() iFpiu +#() iFpiU #() iFpil #() iFpiL #() iFpip @@ -2261,6 +2262,7 @@ #() vFpupuuup #() vFpupppui #() vFpUiUiup +#() vFpUuuUup #() vFpUUUUuu #() vFpddiidd #() vFpdddddd @@ -2333,6 +2335,7 @@ #() iFpWppppp #() iFpuiCuCp #() iFpuiuupp +#() iFpuuuuup #() iFpupiLpL #() iFpupuuui #() iFpupuupp @@ -5512,8 +5515,10 @@ wrappedvulkan: - vkDestroyQueryPool - vkDestroyRenderPass - vkDestroySampler + - vkDestroySamplerYcbcrConversion - vkDestroySamplerYcbcrConversionKHR - vkDestroySemaphore + - vkDestroyShaderEXT - vkDestroyShaderModule - vkDestroySurfaceKHR - vkDestroySwapchainKHR @@ -5581,6 +5586,7 @@ wrappedvulkan: - vFpupup: - vkUpdateDescriptorSets - iFpuppp: + - vkCreateShadersEXT - vkCreateSharedSwapchainsKHR - iFpUppp: - vkCreateDisplayModeKHR diff --git a/src/wrapped/generated/wrappedvulkantypes.h b/src/wrapped/generated/wrappedvulkantypes.h index b6809188..0e3e1c59 100644 --- a/src/wrapped/generated/wrappedvulkantypes.h +++ b/src/wrapped/generated/wrappedvulkantypes.h @@ -62,8 +62,10 @@ typedef void (*vFpiiiupupup_t)(void*, int32_t, int32_t, int32_t, uint32_t, void* GO(vkDestroyQueryPool, vFpUp_t) \ GO(vkDestroyRenderPass, vFpUp_t) \ GO(vkDestroySampler, vFpUp_t) \ + GO(vkDestroySamplerYcbcrConversion, vFpUp_t) \ GO(vkDestroySamplerYcbcrConversionKHR, vFpUp_t) \ GO(vkDestroySemaphore, vFpUp_t) \ + GO(vkDestroyShaderEXT, vFpUp_t) \ GO(vkDestroyShaderModule, vFpUp_t) \ GO(vkDestroySurfaceKHR, vFpUp_t) \ GO(vkDestroySwapchainKHR, vFpUp_t) \ @@ -124,6 +126,7 @@ typedef void (*vFpiiiupupup_t)(void*, int32_t, int32_t, int32_t, uint32_t, void* GO(vkCreateXlibSurfaceKHR, iFpppp_t) \ GO(vkRegisterDeviceEventEXT, iFpppp_t) \ GO(vkUpdateDescriptorSets, vFpupup_t) \ + GO(vkCreateShadersEXT, iFpuppp_t) \ GO(vkCreateSharedSwapchainsKHR, iFpuppp_t) \ GO(vkCreateDisplayModeKHR, iFpUppp_t) \ GO(vkRegisterDisplayEventEXT, iFpUppp_t) \ diff --git a/src/wrapped/generated/wrapper.c b/src/wrapped/generated/wrapper.c index 28b54cd8..789519ac 100644 --- a/src/wrapped/generated/wrapper.c +++ b/src/wrapped/generated/wrapper.c @@ -547,6 +547,7 @@ typedef int32_t (*iFLpp_t)(uintptr_t, void*, void*); typedef int32_t (*iFpwp_t)(void*, int16_t, void*); typedef int32_t (*iFpii_t)(void*, int32_t, int32_t); typedef int32_t (*iFpiu_t)(void*, int32_t, uint32_t); +typedef int32_t (*iFpiU_t)(void*, int32_t, uint64_t); typedef int32_t (*iFpil_t)(void*, int32_t, intptr_t); typedef int32_t (*iFpiL_t)(void*, int32_t, uintptr_t); typedef int32_t (*iFpip_t)(void*, int32_t, void*); @@ -2299,6 +2300,7 @@ typedef void (*vFpuupppp_t)(void*, uint32_t, uint32_t, void*, void*, void*, void typedef void (*vFpupuuup_t)(void*, uint32_t, void*, uint32_t, uint32_t, uint32_t, void*); typedef void (*vFpupppui_t)(void*, uint32_t, void*, void*, void*, uint32_t, int32_t); typedef void (*vFpUiUiup_t)(void*, uint64_t, int32_t, uint64_t, int32_t, uint32_t, void*); +typedef void (*vFpUuuUup_t)(void*, uint64_t, uint32_t, uint32_t, uint64_t, uint32_t, void*); typedef void (*vFpUUUUuu_t)(void*, uint64_t, uint64_t, uint64_t, uint64_t, uint32_t, uint32_t); typedef void (*vFpddiidd_t)(void*, double, double, int32_t, int32_t, double, double); typedef void (*vFpdddddd_t)(void*, double, double, double, double, double, double); @@ -2371,6 +2373,7 @@ typedef int32_t (*iFpWppppW_t)(void*, uint16_t, void*, void*, void*, void*, uint typedef int32_t (*iFpWppppp_t)(void*, uint16_t, void*, void*, void*, void*, void*); typedef int32_t (*iFpuiCuCp_t)(void*, uint32_t, int32_t, uint8_t, uint32_t, uint8_t, void*); typedef int32_t (*iFpuiuupp_t)(void*, uint32_t, int32_t, uint32_t, uint32_t, void*, void*); +typedef int32_t (*iFpuuuuup_t)(void*, uint32_t, uint32_t, uint32_t, uint32_t, uint32_t, void*); typedef int32_t (*iFpupiLpL_t)(void*, uint32_t, void*, int32_t, uintptr_t, void*, uintptr_t); typedef int32_t (*iFpupuuui_t)(void*, uint32_t, void*, uint32_t, uint32_t, uint32_t, int32_t); typedef int32_t (*iFpupuupp_t)(void*, uint32_t, void*, uint32_t, uint32_t, void*, void*); @@ -3583,6 +3586,7 @@ void iFLpp(x64emu_t *emu, uintptr_t fcn) { iFLpp_t fn = (iFLpp_t)fcn; R_RAX=(int void iFpwp(x64emu_t *emu, uintptr_t fcn) { iFpwp_t fn = (iFpwp_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (int16_t)R_RSI, (void*)R_RDX); } void iFpii(x64emu_t *emu, uintptr_t fcn) { iFpii_t fn = (iFpii_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (int32_t)R_RSI, (int32_t)R_RDX); } void iFpiu(x64emu_t *emu, uintptr_t fcn) { iFpiu_t fn = (iFpiu_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (int32_t)R_RSI, (uint32_t)R_RDX); } +void iFpiU(x64emu_t *emu, uintptr_t fcn) { iFpiU_t fn = (iFpiU_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (int32_t)R_RSI, (uint64_t)R_RDX); } void iFpil(x64emu_t *emu, uintptr_t fcn) { iFpil_t fn = (iFpil_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (int32_t)R_RSI, (intptr_t)R_RDX); } void iFpiL(x64emu_t *emu, uintptr_t fcn) { iFpiL_t fn = (iFpiL_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (int32_t)R_RSI, (uintptr_t)R_RDX); } void iFpip(x64emu_t *emu, uintptr_t fcn) { iFpip_t fn = (iFpip_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (int32_t)R_RSI, (void*)R_RDX); } @@ -5335,6 +5339,7 @@ void vFpuupppp(x64emu_t *emu, uintptr_t fcn) { vFpuupppp_t fn = (vFpuupppp_t)fcn void vFpupuuup(x64emu_t *emu, uintptr_t fcn) { vFpupuuup_t fn = (vFpupuuup_t)fcn; fn((void*)R_RDI, (uint32_t)R_RSI, (void*)R_RDX, (uint32_t)R_RCX, (uint32_t)R_R8, (uint32_t)R_R9, *(void**)(R_RSP + 8)); } void vFpupppui(x64emu_t *emu, uintptr_t fcn) { vFpupppui_t fn = (vFpupppui_t)fcn; fn((void*)R_RDI, (uint32_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (uint32_t)R_R9, *(int32_t*)(R_RSP + 8)); } void vFpUiUiup(x64emu_t *emu, uintptr_t fcn) { vFpUiUiup_t fn = (vFpUiUiup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (int32_t)R_RDX, (uint64_t)R_RCX, (int32_t)R_R8, (uint32_t)R_R9, *(void**)(R_RSP + 8)); } +void vFpUuuUup(x64emu_t *emu, uintptr_t fcn) { vFpUuuUup_t fn = (vFpUuuUup_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint32_t)R_RDX, (uint32_t)R_RCX, (uint64_t)R_R8, (uint32_t)R_R9, *(void**)(R_RSP + 8)); } void vFpUUUUuu(x64emu_t *emu, uintptr_t fcn) { vFpUUUUuu_t fn = (vFpUUUUuu_t)fcn; fn((void*)R_RDI, (uint64_t)R_RSI, (uint64_t)R_RDX, (uint64_t)R_RCX, (uint64_t)R_R8, (uint32_t)R_R9, *(uint32_t*)(R_RSP + 8)); } void vFpddiidd(x64emu_t *emu, uintptr_t fcn) { vFpddiidd_t fn = (vFpddiidd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], (int32_t)R_RSI, (int32_t)R_RDX, emu->xmm[2].d[0], emu->xmm[3].d[0]); } void vFpdddddd(x64emu_t *emu, uintptr_t fcn) { vFpdddddd_t fn = (vFpdddddd_t)fcn; fn((void*)R_RDI, emu->xmm[0].d[0], emu->xmm[1].d[0], emu->xmm[2].d[0], emu->xmm[3].d[0], emu->xmm[4].d[0], emu->xmm[5].d[0]); } @@ -5407,6 +5412,7 @@ void iFpWppppW(x64emu_t *emu, uintptr_t fcn) { iFpWppppW_t fn = (iFpWppppW_t)fcn void iFpWppppp(x64emu_t *emu, uintptr_t fcn) { iFpWppppp_t fn = (iFpWppppp_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (uint16_t)R_RSI, (void*)R_RDX, (void*)R_RCX, (void*)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); } void iFpuiCuCp(x64emu_t *emu, uintptr_t fcn) { iFpuiCuCp_t fn = (iFpuiCuCp_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (uint32_t)R_RSI, (int32_t)R_RDX, (uint8_t)R_RCX, (uint32_t)R_R8, (uint8_t)R_R9, *(void**)(R_RSP + 8)); } void iFpuiuupp(x64emu_t *emu, uintptr_t fcn) { iFpuiuupp_t fn = (iFpuiuupp_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (uint32_t)R_RSI, (int32_t)R_RDX, (uint32_t)R_RCX, (uint32_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); } +void iFpuuuuup(x64emu_t *emu, uintptr_t fcn) { iFpuuuuup_t fn = (iFpuuuuup_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (uint32_t)R_RSI, (uint32_t)R_RDX, (uint32_t)R_RCX, (uint32_t)R_R8, (uint32_t)R_R9, *(void**)(R_RSP + 8)); } void iFpupiLpL(x64emu_t *emu, uintptr_t fcn) { iFpupiLpL_t fn = (iFpupiLpL_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (uint32_t)R_RSI, (void*)R_RDX, (int32_t)R_RCX, (uintptr_t)R_R8, (void*)R_R9, *(uintptr_t*)(R_RSP + 8)); } void iFpupuuui(x64emu_t *emu, uintptr_t fcn) { iFpupuuui_t fn = (iFpupuuui_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (uint32_t)R_RSI, (void*)R_RDX, (uint32_t)R_RCX, (uint32_t)R_R8, (uint32_t)R_R9, *(int32_t*)(R_RSP + 8)); } void iFpupuupp(x64emu_t *emu, uintptr_t fcn) { iFpupuupp_t fn = (iFpupuupp_t)fcn; R_RAX=(int32_t)fn((void*)R_RDI, (uint32_t)R_RSI, (void*)R_RDX, (uint32_t)R_RCX, (uint32_t)R_R8, (void*)R_R9, *(void**)(R_RSP + 8)); } @@ -6531,6 +6537,7 @@ int isSimpleWrapper(wrapper_t fun) { if (fun == &iFpwp) return 1; if (fun == &iFpii) return 1; if (fun == &iFpiu) return 1; + if (fun == &iFpiU) return 1; if (fun == &iFpil) return 1; if (fun == &iFpiL) return 1; if (fun == &iFpip) return 1; diff --git a/src/wrapped/generated/wrapper.h b/src/wrapped/generated/wrapper.h index 1361974b..ee09c988 100644 --- a/src/wrapped/generated/wrapper.h +++ b/src/wrapped/generated/wrapper.h @@ -547,6 +547,7 @@ void iFLpp(x64emu_t *emu, uintptr_t fnc); void iFpwp(x64emu_t *emu, uintptr_t fnc); void iFpii(x64emu_t *emu, uintptr_t fnc); void iFpiu(x64emu_t *emu, uintptr_t fnc); +void iFpiU(x64emu_t *emu, uintptr_t fnc); void iFpil(x64emu_t *emu, uintptr_t fnc); void iFpiL(x64emu_t *emu, uintptr_t fnc); void iFpip(x64emu_t *emu, uintptr_t fnc); @@ -2299,6 +2300,7 @@ void vFpuupppp(x64emu_t *emu, uintptr_t fnc); void vFpupuuup(x64emu_t *emu, uintptr_t fnc); void vFpupppui(x64emu_t *emu, uintptr_t fnc); void vFpUiUiup(x64emu_t *emu, uintptr_t fnc); +void vFpUuuUup(x64emu_t *emu, uintptr_t fnc); void vFpUUUUuu(x64emu_t *emu, uintptr_t fnc); void vFpddiidd(x64emu_t *emu, uintptr_t fnc); void vFpdddddd(x64emu_t *emu, uintptr_t fnc); @@ -2371,6 +2373,7 @@ void iFpWppppW(x64emu_t *emu, uintptr_t fnc); void iFpWppppp(x64emu_t *emu, uintptr_t fnc); void iFpuiCuCp(x64emu_t *emu, uintptr_t fnc); void iFpuiuupp(x64emu_t *emu, uintptr_t fnc); +void iFpuuuuup(x64emu_t *emu, uintptr_t fnc); void iFpupiLpL(x64emu_t *emu, uintptr_t fnc); void iFpupuuui(x64emu_t *emu, uintptr_t fnc); void iFpupuupp(x64emu_t *emu, uintptr_t fnc); diff --git a/src/wrapped/wrappedvulkan.c b/src/wrapped/wrappedvulkan.c index 3c8e7b46..56cf36b1 100644 --- a/src/wrapped/wrappedvulkan.c +++ b/src/wrapped/wrappedvulkan.c @@ -25,7 +25,6 @@ const char* vulkanName = "libvulkan.so.1"; typedef void(*vFpUp_t) (void*, uint64_t, void*); #define ADDED_FUNCTIONS() \ - GO(vkDestroySamplerYcbcrConversion, vFpUp_t) \ #include "generated/wrappedvulkantypes.h" @@ -618,6 +617,16 @@ EXPORT int my_vkRegisterDisplayEventEXT(x64emu_t* emu, void* device, uint64_t di CREATE(vkCreateValidationCacheEXT) +EXPORT int my_vkCreateShadersEXT(x64emu_t* emu, void* device, uint32_t count, void** pCreateInfos, my_VkAllocationCallbacks_t* pAllocator, void* pShaders) +{ + my_VkAllocationCallbacks_t my_alloc; + int ret = my->vkCreateShadersEXT(device, count, pCreateInfos, find_VkAllocationCallbacks(&my_alloc, pAllocator), pShaders); + return ret; +} + +DESTROY64(vkDestroyShaderEXT) + + DESTROY64(vkDestroyBuffer) DESTROY64(vkDestroyBufferView) DESTROY64(vkDestroyCommandPool) diff --git a/src/wrapped/wrappedvulkan_private.h b/src/wrapped/wrappedvulkan_private.h index 3c7cd5f4..b83790c4 100644 --- a/src/wrapped/wrappedvulkan_private.h +++ b/src/wrapped/wrappedvulkan_private.h @@ -184,6 +184,7 @@ GO(vkCmdSetDeviceMask, vFpu) GOM(vkCreateDescriptorUpdateTemplate, iFEpppp) GOM(vkCreateSamplerYcbcrConversion, iFEpppp) GOM(vkDestroyDescriptorUpdateTemplate, vFEpUp) +GOM(vkDestroySamplerYcbcrConversion, vFEpUp) GO(vkEnumerateInstanceVersion, iFp) GO(vkEnumeratePhysicalDeviceGroups, iFppp) //VkPhysicalDeviceGroupProperties seems OK GO(vkGetBufferMemoryRequirements2, iFppp) @@ -886,3 +887,42 @@ GO(vkUnmapMemory2KHR, iFpp) // VK_EXT_device_fault GO(vkGetDeviceFaultInfoEXT, iFppp) + +// VK_EXT_acquire_drm_display +GO(vkAcquireDrmDisplayEXT, iFpiU) +GO(vkGetDrmDisplayEXT, iFpiup) + +// VK_EXT_shader_object +GO(vkCmdBindShadersEXT, vFpupp) +GOM(vkCreateShadersEXT, iFEpuppp) +GOM(vkDestroyShaderEXT, vFpUp) +GO(vkGetShaderBinaryDataEXT, iFpUpp) + +// VK_NV_copy_memory_indirect +GO(vkCmdCopyMemoryIndirectNV, vFpUuu) +GO(vkCmdCopyMemoryToImageIndirectNV, vFpUuuUup) + +// VK_HUAWEI_cluster_culling_shader +GO(vkCmdDrawClusterHUAWEI, vFpuuu) +GO(vkCmdDrawClusterIndirectHUAWEI, vFpUU) + +// VK_EXT_attachment_feedback_loop_dynamic_state +GO(vkCmdSetAttachmentFeedbackLoopEnableEXT, vFpu) + +// VK_NV_device_generated_commands_compute +GO(vkCmdUpdatePipelineIndirectBufferNV, vFpuU) +GO(vkGetPipelineIndirectDeviceAddressNV, UFpp) +GO(vkGetPipelineIndirectMemoryRequirementsNV, vFppp) + +// VK_QCOM_tile_properties +GO(vkGetDynamicRenderingTilePropertiesQCOM, iFppp) +GO(vkGetFramebufferTilePropertiesQCOM, iFpUpp) + +// VK_NV_external_memory_capabilities +GO(vkGetPhysicalDeviceExternalImageFormatPropertiesNV, iFpuuuuup) + +// VK_EXT_pipeline_properties +GO(vkGetPipelinePropertiesEXT, iFppp) + +// VK_EXT_direct_mode_display +GO(vkReleaseDisplayEXT, iFpU) |