mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-04 17:50:11 +01:00
st/glsl_to_nir: fix next_stage gathering
ffs() just returns the bit that is set, we need to know what
stage that bit represents so use u_bit_scan() instead.
Fixes: 2ca5d9548f ("st/glsl_to_nir: gather next_stage in shader_info")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
This commit is contained in:
parent
9ec4a5ef29
commit
31596836fc
1 changed files with 1 additions and 1 deletions
|
|
@ -373,7 +373,7 @@ st_glsl_to_nir(struct st_context *st, struct gl_program *prog,
|
|||
~prev_stages & shader_program->data->linked_stages;
|
||||
|
||||
nir->info.next_stage = stages_mask ?
|
||||
(gl_shader_stage) ffs(stages_mask) : MESA_SHADER_FRAGMENT;
|
||||
(gl_shader_stage) u_bit_scan(&stages_mask) : MESA_SHADER_FRAGMENT;
|
||||
} else {
|
||||
nir->info.next_stage = MESA_SHADER_FRAGMENT;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue