mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 15:58:05 +02:00
nir/xfb: Properly align 64-bit values
Fixes:19064b8c"nir: Add a pass for gathering transform feedback info" Reviewed-by: Alejandro Piñeiro <apinheiro@igalia.com> (cherry picked from commit8f0fe71cc5)
This commit is contained in:
parent
5fcd81c5ed
commit
fdc25b9b1b
1 changed files with 4 additions and 0 deletions
|
|
@ -33,6 +33,10 @@ add_var_xfb_outputs(nir_xfb_info *xfb,
|
|||
unsigned *offset,
|
||||
const struct glsl_type *type)
|
||||
{
|
||||
/* If this type contains a 64-bit value, align to 8 bytes */
|
||||
if (glsl_type_contains_64bit(type))
|
||||
*offset = ALIGN_POT(*offset, 8);
|
||||
|
||||
if (glsl_type_is_array(type) || glsl_type_is_matrix(type)) {
|
||||
unsigned length = glsl_get_length(type);
|
||||
const struct glsl_type *child_type = glsl_get_array_element(type);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue