anv: Use 4 instead of sizeof(gl_constant_value)

We no longer have access to gl_constant_value and, really, it's 4 because
our uniform layout code works entirely in dwords.
This commit is contained in:
Jason Ekstrand 2015-12-10 18:55:14 -08:00
parent 13d1dd465c
commit 3893e11f4b
2 changed files with 2 additions and 2 deletions

View file

@ -930,7 +930,7 @@ anv_cmd_buffer_cs_push_constants(struct anv_cmd_buffer *cmd_buffer)
const unsigned local_id_dwords = cs_prog_data->local_invocation_id_regs * 8;
const unsigned push_constant_data_size =
(local_id_dwords + prog_data->nr_params) * sizeof(union gl_constant_value *);
(local_id_dwords + prog_data->nr_params) * 4;
const unsigned reg_aligned_constant_size = ALIGN(push_constant_data_size, 32);
const unsigned param_aligned_count =
reg_aligned_constant_size / sizeof(uint32_t);

View file

@ -521,7 +521,7 @@ flush_compute_descriptor_set(struct anv_cmd_buffer *cmd_buffer)
unsigned local_id_dwords = cs_prog_data->local_invocation_id_regs * 8;
unsigned push_constant_data_size =
(prog_data->nr_params + local_id_dwords) * sizeof(union gl_constant_value *);
(prog_data->nr_params + local_id_dwords) * 4;
unsigned reg_aligned_constant_size = ALIGN(push_constant_data_size, 32);
unsigned push_constant_regs = reg_aligned_constant_size / 32;