Mesa (master): nir: improve nir_variable packing
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Thu Oct 24 02:52:46 UTC 2019
Module: Mesa
Branch: master
Commit: 922801b77d14bb7ebf762aa1f208997a072c9a1c
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=922801b77d14bb7ebf762aa1f208997a072c9a1c
Author: Timothy Arceri <tarceri at itsqueeze.com>
Date: Wed Oct 23 11:43:59 2019 +1100
nir: improve nir_variable packing
Before:
/* size: 136, cachelines: 3, members: 10 */
After:
/* size: 128, cachelines: 2, members: 10 */
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Reviewed-by: Rob Clark <robdclark at chromium.org>
---
src/compiler/nir/nir.h | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
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;
More information about the mesa-commit
mailing list