vulkan, tu, pvr: remove vk_render_pass_state::render_pass

The spec says

  A VkRenderPass or VkPipelineLayout object passed as a parameter to
  create another object is not further accessed by that object after the
  duration of the command it is passed into.

The object could have been destroyed if we get the pointer from a
pipeline library.  Since it has no user now, let's remove it.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26000>
This commit is contained in:
Chia-I Wu
2023-11-01 18:00:56 -07:00
committed by Marge Bot
parent 227300345e
commit ef724ab695
4 changed files with 1 additions and 21 deletions
+1 -9
View File
@@ -4092,10 +4092,7 @@ tu_pipeline_builder_init_graphics(
builder->create_info->pRasterizationState->rasterizerDiscardEnable &&
!rasterizer_discard_dynamic;
struct vk_render_pass_state rp_state = {
.render_pass = builder->create_info->renderPass,
.subpass = builder->create_info->subpass,
};
struct vk_render_pass_state rp_state = {};
const struct vk_render_pass_state *driver_rp = NULL;
builder->unscaled_input_fragcoord = 0;
@@ -4115,11 +4112,6 @@ tu_pipeline_builder_init_graphics(
const struct tu_subpass *subpass =
&pass->subpasses[create_info->subpass];
rp_state = (struct vk_render_pass_state) {
.render_pass = builder->create_info->renderPass,
.subpass = builder->create_info->subpass,
};
tu_fill_render_pass_state(&rp_state, pass, subpass);
rp_state.feedback_loop_input_only = true;
-2
View File
@@ -2266,8 +2266,6 @@ pvr_create_renderpass_state(const VkGraphicsPipelineCreateInfo *const info)
return (struct vk_render_pass_state){
.attachment_aspects = attachment_aspects,
.render_pass = info->renderPass,
.subpass = info->subpass,
/* TODO: This is only needed for VK_KHR_create_renderpass2 (or core 1.2),
* which is not currently supported.
-4
View File
@@ -1064,16 +1064,12 @@ vk_render_pass_state_init(struct vk_render_pass_state *rp,
}
*rp = (struct vk_render_pass_state) {
.render_pass = info->renderPass,
.subpass = info->subpass,
.pipeline_flags = pipeline_flags,
.depth_attachment_format = VK_FORMAT_UNDEFINED,
.stencil_attachment_format = VK_FORMAT_UNDEFINED,
};
if (info->renderPass != VK_NULL_HANDLE && driver_rp != NULL) {
assert(driver_rp->render_pass == info->renderPass);
assert(driver_rp->subpass == info->subpass);
*rp = *driver_rp;
return;
}
-6
View File
@@ -672,12 +672,6 @@ struct vk_render_pass_state {
*/
VkImageAspectFlags attachment_aspects;
/** VkGraphicsPipelineCreateInfo::renderPass */
VkRenderPass render_pass;
/** VkGraphicsPipelineCreateInfo::subpass */
uint32_t subpass;
/** VkPipelineRenderingCreateInfo::viewMask */
uint32_t view_mask;