radv: Enable VK_EXT_fragment_shader_interlock
ACO only currently - not available in LLVM. Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Timur Kristóf <timur.kristof@gmail.com> Signed-off-by: Vitaliy Triang3l Kuzmin <triang3l@yandex.ru> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22250>
This commit is contained in:

committed by
Marge Bot

parent
8a8f2edd50
commit
f9e6d35f65
@@ -566,7 +566,7 @@ Khronos extensions that are not part of any Vulkan version:
|
||||
VK_EXT_external_memory_dma_buf DONE (anv, pvr, radv, tu, v3dv, vn)
|
||||
VK_EXT_external_memory_host DONE (anv, lvp, radv)
|
||||
VK_EXT_filter_cubic DONE (tu/a650)
|
||||
VK_EXT_fragment_shader_interlock DONE (anv/gen9+, vn)
|
||||
VK_EXT_fragment_shader_interlock DONE (anv/gen9+, radv/gfx9+, vn)
|
||||
VK_EXT_global_priority DONE (anv, radv, tu)
|
||||
VK_EXT_global_priority_query DONE (anv, radv, tu)
|
||||
VK_EXT_graphics_pipeline_library DONE (lvp, radv, tu)
|
||||
|
@@ -7,3 +7,4 @@ OpenGL ES 3.0 on Asahi
|
||||
VK_KHR_fragment_shader_barycentric on RADV/GFX10.3+
|
||||
VK_KHR_ray_tracing_pipeline on RADV/GFX10.3+
|
||||
VK_EXT_depth_bias_control on RADV
|
||||
VK_EXT_fragment_shader_interlock on RADV/GFX9+
|
||||
|
@@ -494,6 +494,7 @@ radv_physical_device_get_supported_extensions(const struct radv_physical_device
|
||||
.EXT_extended_dynamic_state3 = true,
|
||||
.EXT_external_memory_dma_buf = true,
|
||||
.EXT_external_memory_host = device->rad_info.has_userptr,
|
||||
.EXT_fragment_shader_interlock = radv_has_pops(device),
|
||||
.EXT_global_priority = true,
|
||||
.EXT_global_priority_query = true,
|
||||
.EXT_graphics_pipeline_library = !device->use_llvm && !(device->instance->debug_flags & RADV_DEBUG_NO_GPL),
|
||||
@@ -594,6 +595,7 @@ radv_physical_device_get_features(const struct radv_physical_device *pdevice, st
|
||||
bool has_perf_query = radv_perf_query_supported(pdevice);
|
||||
bool has_shader_image_float_minmax = pdevice->rad_info.gfx_level != GFX8 && pdevice->rad_info.gfx_level != GFX9 &&
|
||||
pdevice->rad_info.gfx_level != GFX11;
|
||||
bool has_fragment_shader_interlock = radv_has_pops(pdevice);
|
||||
|
||||
*features = (struct vk_features){
|
||||
/* Vulkan 1.0 */
|
||||
@@ -1021,6 +1023,11 @@ radv_physical_device_get_features(const struct radv_physical_device *pdevice, st
|
||||
.leastRepresentableValueForceUnormRepresentation = true,
|
||||
.floatRepresentation = true,
|
||||
.depthBiasExact = true,
|
||||
|
||||
/* VK_EXT_fragment_shader_interlock */
|
||||
.fragmentShaderSampleInterlock = has_fragment_shader_interlock,
|
||||
.fragmentShaderPixelInterlock = has_fragment_shader_interlock,
|
||||
.fragmentShaderShadingRateInterlock = false,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1607,7 +1614,8 @@ radv_GetPhysicalDeviceProperties2(VkPhysicalDevice physicalDevice, VkPhysicalDev
|
||||
props->fragmentShadingRateWithSampleMask = true;
|
||||
props->fragmentShadingRateWithShaderSampleMask = false;
|
||||
props->fragmentShadingRateWithConservativeRasterization = true;
|
||||
props->fragmentShadingRateWithFragmentShaderInterlock = false;
|
||||
props->fragmentShadingRateWithFragmentShaderInterlock =
|
||||
pdevice->rad_info.gfx_level >= GFX11 && radv_has_pops(pdevice);
|
||||
props->fragmentShadingRateWithCustomSampleLocations = false;
|
||||
props->fragmentShadingRateStrictMultiplyCombiner = true;
|
||||
break;
|
||||
|
@@ -3581,6 +3581,12 @@ radv_has_shader_buffer_float_minmax(const struct radv_physical_device *pdevice,
|
||||
pdevice->rad_info.gfx_level == GFX10_3 || (pdevice->rad_info.gfx_level == GFX11 && bitsize == 32);
|
||||
}
|
||||
|
||||
static inline bool
|
||||
radv_has_pops(const struct radv_physical_device *pdevice)
|
||||
{
|
||||
return pdevice->rad_info.gfx_level >= GFX9 && !pdevice->use_llvm;
|
||||
}
|
||||
|
||||
/* radv_perfcounter.c */
|
||||
void radv_perfcounter_emit_shaders(struct radeon_cmdbuf *cs, unsigned shaders);
|
||||
void radv_perfcounter_emit_spm_reset(struct radeon_cmdbuf *cs);
|
||||
|
@@ -363,6 +363,7 @@ radv_shader_spirv_to_nir(struct radv_device *device, const struct radv_pipeline_
|
||||
.device = device,
|
||||
.object = stage->spirv.object,
|
||||
};
|
||||
const bool has_fragment_shader_interlock = radv_has_pops(device->physical_device);
|
||||
const struct spirv_to_nir_options spirv_options = {
|
||||
.caps =
|
||||
{
|
||||
@@ -388,6 +389,8 @@ radv_shader_spirv_to_nir(struct radv_device *device, const struct radv_pipeline_
|
||||
.float64_atomic_min_max = true,
|
||||
.fragment_barycentric = true,
|
||||
.fragment_fully_covered = true,
|
||||
.fragment_shader_pixel_interlock = has_fragment_shader_interlock,
|
||||
.fragment_shader_sample_interlock = has_fragment_shader_interlock,
|
||||
.geometry_streams = true,
|
||||
.groups = true,
|
||||
.image_atomic_int64 = true,
|
||||
|
Reference in New Issue
Block a user