summaryrefslogtreecommitdiffstats
path: root/src/intel/common/gen_urb_config.c
diff options
context:
space:
mode:
authorCaio Marcelo de Oliveira Filho <[email protected]>2018-07-16 14:17:38 -0700
committerCaio Marcelo de Oliveira Filho <[email protected]>2018-07-18 08:29:51 -0700
commit8ec40824aefe33b014b715276dfdd6ea4edb262b (patch)
treec47e4500dc1cf9a21968678298737cdc5a726fc0 /src/intel/common/gen_urb_config.c
parentf836d799f9066adf58f3660626d7aa58c0c9b62e (diff)
intel/batch-decoder: fix uninitialized values warnings
Code assumes that all the necessary fields will exist, but compiler doesn't know about this. Provide zero as default values, like in other decoding functions. Fixes warnings ../../src/intel/common/gen_batch_decoder.c: In function ‘handle_media_interface_descriptor_load’: ../../src/intel/common/gen_batch_decoder.c:347:7: warning: ‘binding_entry_count’ may be used uninitialized in this function [-Wmaybe-uninitialized] dump_binding_table(ctx, binding_table_offset, binding_entry_count); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../../src/intel/common/gen_batch_decoder.c:347:7: warning: ‘binding_table_offset’ may be used uninitialized in this function [-Wmaybe-uninitialized] ../../src/intel/common/gen_batch_decoder.c:346:7: warning: ‘sampler_count’ may be used uninitialized in this function [-Wmaybe-uninitialized] dump_samplers(ctx, sampler_offset, sampler_count); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../../src/intel/common/gen_batch_decoder.c:346:7: warning: ‘sampler_offset’ may be used uninitialized in this function [-Wmaybe-uninitialized] ../../src/intel/common/gen_batch_decoder.c:343:7: warning: ‘ksp’ may be used uninitialized in this function [-Wmaybe-uninitialized] ctx_disassemble_program(ctx, ksp, "compute shader"); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ../../src/intel/common/gen_batch_decoder.c: In function ‘decode_dynamic_state_pointers’: ../../src/intel/common/gen_batch_decoder.c:663:54: warning: ‘state_offset’ may be used uninitialized in this function [-Wmaybe-uninitialized] const uint32_t *state_map = ctx->dynamic_base.map + state_offset; ~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~ ../../src/intel/common/gen_batch_decoder.c: In function ‘gen_print_batch’: ../../src/intel/common/gen_batch_decoder.c:856:13: warning: ‘next_batch.map’ may be used uninitialized in this function [-Wmaybe-uninitialized] if (next_batch.map == NULL) { ^ ../../src/intel/common/gen_batch_decoder.c:860:13: warning: ‘next_batch.addr’ may be used uninitialized in this function [-Wmaybe-uninitialized] gen_print_batch(ctx, next_batch.map, next_batch.size, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ next_batch.addr); ~~~~~~~~~~~~~~~~ Reviewed-by: Anuj Phogat <[email protected]>
Diffstat (limited to 'src/intel/common/gen_urb_config.c')
0 files changed, 0 insertions, 0 deletions