radeonsi: rename desc_list_byte_size -> vb_desc_list_alloc_size
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
This commit is contained in:
parent
2cc14bd7b8
commit
1e03b63b3b
|
@ -433,12 +433,12 @@ static void cik_prefetch_shader_async(struct si_context *sctx,
|
|||
|
||||
static void cik_prefetch_VBO_descriptors(struct si_context *sctx)
|
||||
{
|
||||
if (!sctx->vertex_elements || !sctx->vertex_elements->desc_list_byte_size)
|
||||
if (!sctx->vertex_elements || !sctx->vertex_elements->vb_desc_list_alloc_size)
|
||||
return;
|
||||
|
||||
cik_prefetch_TC_L2_async(sctx, &sctx->vb_descriptors_buffer->b.b,
|
||||
sctx->vb_descriptors_offset,
|
||||
sctx->vertex_elements->desc_list_byte_size);
|
||||
sctx->vertex_elements->vb_desc_list_alloc_size);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -868,7 +868,7 @@ static void si_dump_descriptors(struct si_context *sctx,
|
|||
desc.list = sctx->vb_descriptors_gpu_list;
|
||||
desc.gpu_list = sctx->vb_descriptors_gpu_list;
|
||||
desc.element_dw_size = 4;
|
||||
desc.num_active_slots = sctx->vertex_elements->desc_list_byte_size / 16;
|
||||
desc.num_active_slots = sctx->vertex_elements->vb_desc_list_alloc_size / 16;
|
||||
|
||||
si_dump_descriptor_list(sctx->screen, &desc, name,
|
||||
" - Vertex buffer", 4, info->num_inputs,
|
||||
|
|
|
@ -1097,8 +1097,6 @@ bool si_upload_vertex_buffer_descriptors(struct si_context *sctx)
|
|||
{
|
||||
struct si_vertex_elements *velems = sctx->vertex_elements;
|
||||
unsigned i, count;
|
||||
unsigned desc_list_byte_size;
|
||||
unsigned first_vb_use_mask;
|
||||
uint32_t *ptr;
|
||||
|
||||
if (!sctx->vertex_buffers_dirty || !velems)
|
||||
|
@ -1109,16 +1107,16 @@ bool si_upload_vertex_buffer_descriptors(struct si_context *sctx)
|
|||
if (!count)
|
||||
return true;
|
||||
|
||||
desc_list_byte_size = velems->desc_list_byte_size;
|
||||
first_vb_use_mask = velems->first_vb_use_mask;
|
||||
unsigned alloc_size = velems->vb_desc_list_alloc_size;
|
||||
unsigned first_vb_use_mask = velems->first_vb_use_mask;
|
||||
|
||||
/* Vertex buffer descriptors are the only ones which are uploaded
|
||||
* directly through a staging buffer and don't go through
|
||||
* the fine-grained upload path.
|
||||
*/
|
||||
u_upload_alloc(sctx->b.const_uploader, 0,
|
||||
desc_list_byte_size,
|
||||
si_optimal_tcc_alignment(sctx, desc_list_byte_size),
|
||||
alloc_size,
|
||||
si_optimal_tcc_alignment(sctx, alloc_size),
|
||||
&sctx->vb_descriptors_offset,
|
||||
(struct pipe_resource**)&sctx->vb_descriptors_buffer,
|
||||
(void**)&ptr);
|
||||
|
|
|
@ -4873,7 +4873,7 @@ static void *si_create_vertex_elements(struct pipe_context *ctx,
|
|||
return NULL;
|
||||
|
||||
v->count = count;
|
||||
v->desc_list_byte_size = align(count * 16, SI_CPDMA_ALIGNMENT);
|
||||
v->vb_desc_list_alloc_size = align(count * 16, SI_CPDMA_ALIGNMENT);
|
||||
|
||||
for (i = 0; i < count; ++i) {
|
||||
const struct util_format_description *desc;
|
||||
|
|
|
@ -173,7 +173,7 @@ struct si_vertex_elements
|
|||
|
||||
uint16_t first_vb_use_mask;
|
||||
/* Vertex buffer descriptor list size aligned for optimal prefetch. */
|
||||
uint16_t desc_list_byte_size;
|
||||
uint16_t vb_desc_list_alloc_size;
|
||||
uint16_t instance_divisor_is_one; /* bitmask of inputs */
|
||||
uint16_t instance_divisor_is_fetched; /* bitmask of inputs */
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue