mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d-shader/hlsl: Only allocate the aligned size for uniforms.
This commit is contained in:
parent
7fe581203b
commit
acc9d79fbb
@ -4188,8 +4188,10 @@ static struct hlsl_reg allocate_numeric_registers_for_type(struct hlsl_ctx *ctx,
|
||||
{
|
||||
unsigned int reg_size = type->reg_size[HLSL_REGSET_NUMERIC];
|
||||
|
||||
/* FIXME: We could potentially pack structs or arrays more efficiently... */
|
||||
|
||||
if (type->class <= HLSL_CLASS_VECTOR)
|
||||
return allocate_register(ctx, allocator, first_write, last_read, reg_size, type->dimx);
|
||||
return allocate_register(ctx, allocator, first_write, last_read, type->dimx, type->dimx);
|
||||
else
|
||||
return allocate_range(ctx, allocator, first_write, last_read, reg_size);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user