mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 08:40:11 +01:00
pan/bi: initialize variable to fix warning
../src/compiler/nir/nir.h:1152:11: attention: « buf_index » pourrait être utilisé sans être initialisé [-Wmaybe-uninitialized]
1152 | return src;
| ^~~
../src/panfrost/compiler/bifrost_compile.c: Dans la fonction « lower_texel_buffer_fetch »:
../src/panfrost/compiler/bifrost_compile.c:6234:13: note: « buf_index » a été déclaré ici
6234 | nir_def *buf_index;
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig@intel.com>
Reviewed-by: Boris Brezillon <boris.brezillon@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38313>
This commit is contained in:
parent
24a7d53329
commit
11e5f0b60d
1 changed files with 1 additions and 1 deletions
|
|
@ -6231,7 +6231,7 @@ lower_texel_buffer_fetch(nir_builder *b, nir_tex_instr *tex, void *data)
|
|||
b->cursor = nir_before_instr(&tex->instr);
|
||||
|
||||
nir_def *res_handle = nir_imm_int(b, tex->texture_index);
|
||||
nir_def *buf_index;
|
||||
nir_def *buf_index = NULL;
|
||||
for (unsigned i = 0; i < tex->num_srcs; ++i) {
|
||||
switch (tex->src[i].src_type) {
|
||||
case nir_tex_src_coord:
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue