mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-03-05 21:00:40 +01:00
zink: don't short-circuit gfx stage finding during barrier generation
according to spec, all stages must be specified, not just the first one Acked-by: Dave Airlie <airlied@redhat.com> Reviewed-By: Tatsuyuki Ishi <ishitatsuyuki@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17111>
This commit is contained in:
parent
1fa3f03442
commit
f889bece46
1 changed files with 16 additions and 2 deletions
|
|
@ -323,15 +323,29 @@ draw(struct zink_context *ctx,
|
|||
}
|
||||
}
|
||||
|
||||
/*
|
||||
If a synchronization command includes a source stage mask, its first synchronization scope only
|
||||
includes execution of the pipeline stages specified in that mask, and its first access scope only
|
||||
includes memory accesses performed by pipeline stages specified in that mask.
|
||||
|
||||
If a synchronization command includes a destination stage mask, its second synchronization scope
|
||||
only includes execution of the pipeline stages specified in that mask, and its second access scope
|
||||
only includes memory access performed by pipeline stages specified in that mask.
|
||||
|
||||
- Chapter 7. Synchronization and Cache Control
|
||||
|
||||
* thus, all stages must be added to ensure accurate synchronization
|
||||
*/
|
||||
ALWAYS_INLINE static VkPipelineStageFlags
|
||||
find_pipeline_bits(uint32_t *mask)
|
||||
{
|
||||
VkPipelineStageFlags pipeline = 0;
|
||||
for (unsigned i = 0; i < ZINK_SHADER_COUNT; i++) {
|
||||
if (mask[i]) {
|
||||
return zink_pipeline_flags_from_pipe_stage((enum pipe_shader_type)i);
|
||||
pipeline |= zink_pipeline_flags_from_pipe_stage((enum pipe_shader_type)i);
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
return pipeline;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue