Mesa (staging/21.3): zink: flag renderpass change when toggling fbfetch
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Mon Nov 1 19:36:40 UTC 2021
Module: Mesa
Branch: staging/21.3
Commit: c3d96d881ae985e8e320eef66ac250e028ca7d70
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=c3d96d881ae985e8e320eef66ac250e028ca7d70
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Fri Oct 29 11:35:01 2021 -0400
zink: flag renderpass change when toggling fbfetch
ensure the input attachment gets updated
fixes running
KHR-GL46.blend_equation_advanced.blend_all.GL_MULTIPLY_KHR_all_qualifier
after
KHR-GL46.blend_equation_advanced.BlendEquationSeparate
cc: mesa-stable
Reviewed-by: Hoe Hao Cheng <haochengho12907 at gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13598>
(cherry picked from commit 6239adebbc5cabe3466477ac5f96dfdaaf2303a1)
---
.pick_status.json | 2 +-
src/gallium/drivers/zink/zink_context.c | 7 ++++++-
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/.pick_status.json b/.pick_status.json
index c2c2e2b3d49..c98bc38a723 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -139,7 +139,7 @@
"description": "zink: flag renderpass change when toggling fbfetch",
"nominated": true,
"nomination_type": 0,
- "resolution": 0,
+ "resolution": 1,
"main_sha": null,
"because_sha": null
},
diff --git a/src/gallium/drivers/zink/zink_context.c b/src/gallium/drivers/zink/zink_context.c
index 5772762fb32..49a4755d45e 100644
--- a/src/gallium/drivers/zink/zink_context.c
+++ b/src/gallium/drivers/zink/zink_context.c
@@ -1832,6 +1832,8 @@ zink_update_fbfetch(struct zink_context *ctx)
!ctx->gfx_stages[PIPE_SHADER_FRAGMENT]->nir->info.fs.uses_fbfetch_output) {
if (!had_fbfetch)
return;
+ ctx->rp_changed = true;
+ zink_batch_no_rp(ctx);
ctx->di.fbfetch.imageLayout = VK_IMAGE_LAYOUT_UNDEFINED;
ctx->di.fbfetch.imageView = zink_screen(ctx->base.screen)->info.rb2_feats.nullDescriptor ?
VK_NULL_HANDLE :
@@ -1847,8 +1849,11 @@ zink_update_fbfetch(struct zink_context *ctx)
ctx->di.fbfetch.imageView = zink_csurface(ctx->fb_state.cbufs[0])->image_view;
}
ctx->di.fbfetch.imageLayout = VK_IMAGE_LAYOUT_GENERAL;
- if (changed)
+ if (changed) {
zink_screen(ctx->base.screen)->context_invalidate_descriptor_state(ctx, PIPE_SHADER_FRAGMENT, ZINK_DESCRIPTOR_TYPE_UBO, 0, 1);
+ ctx->rp_changed = true;
+ zink_batch_no_rp(ctx);
+ }
}
static size_t
More information about the mesa-commit
mailing list