radv: Run the new ycbcr lowering pass.

Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
This commit is contained in:
Bas Nieuwenhuizen
2019-03-30 14:28:06 +01:00
parent 91702374d5
commit 5c3467e74a
3 changed files with 6 additions and 3 deletions

View File

@@ -2155,7 +2155,7 @@ void radv_create_shaders(struct radv_pipeline *pipeline,
nir[i] = radv_shader_compile_to_nir(device, modules[i],
stage ? stage->pName : "main", i,
stage ? stage->pSpecializationInfo : NULL,
flags);
flags, pipeline->layout);
/* We don't want to alter meta shaders IR directly so clone it
* first.

View File

@@ -181,7 +181,8 @@ radv_shader_compile_to_nir(struct radv_device *device,
const char *entrypoint_name,
gl_shader_stage stage,
const VkSpecializationInfo *spec_info,
const VkPipelineCreateFlags flags)
const VkPipelineCreateFlags flags,
const struct radv_pipeline_layout *layout)
{
nir_shader *nir;
nir_function *entry_point;
@@ -310,6 +311,7 @@ radv_shader_compile_to_nir(struct radv_device *device,
NIR_PASS_V(nir, nir_lower_system_values);
NIR_PASS_V(nir, nir_lower_clip_cull_distance_arrays);
NIR_PASS_V(nir, radv_nir_lower_ycbcr_textures, layout);
}
/* Vulkan uses the separate-shader linking model */

View File

@@ -347,7 +347,8 @@ radv_shader_compile_to_nir(struct radv_device *device,
const char *entrypoint_name,
gl_shader_stage stage,
const VkSpecializationInfo *spec_info,
const VkPipelineCreateFlags flags);
const VkPipelineCreateFlags flags,
const struct radv_pipeline_layout *layout);
void *
radv_alloc_shader_memory(struct radv_device *device,