diff options
author | Timothy Arceri <[email protected]> | 2019-10-23 11:43:59 +1100 |
---|---|---|
committer | Timothy Arceri <[email protected]> | 2019-10-24 13:24:40 +1100 |
commit | 922801b77d14bb7ebf762aa1f208997a072c9a1c (patch) | |
tree | 6d1eb8498a2177ffb5446aacbe2e29f34f11f6d8 /src/compiler/nir/nir.h | |
parent | c412ff426b5b7c86d726a07f12d44798bf055221 (diff) |
nir: improve nir_variable packing
Before:
/* size: 136, cachelines: 3, members: 10 */
After:
/* size: 128, cachelines: 2, members: 10 */
Reviewed-by: Marek Olšák <[email protected]>
Reviewed-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/compiler/nir/nir.h')
-rw-r--r-- | src/compiler/nir/nir.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/compiler/nir/nir.h b/src/compiler/nir/nir.h index 33735d4320b..6496ad92b11 100644 --- a/src/compiler/nir/nir.h +++ b/src/compiler/nir/nir.h @@ -498,6 +498,9 @@ typedef struct nir_variable { } image; } data; + /* Number of nir_variable_data members */ + unsigned num_members; + /** * Built-in state that backs this uniform * @@ -539,7 +542,6 @@ typedef struct nir_variable { * inputs each with their own layout specifier. This is only allowed on * variables with a struct or array of array of struct type. */ - unsigned num_members; struct nir_variable_data *members; } nir_variable; |