Mesa (master): spirv: Trivially handle the NonWriteable decoration
Jason Ekstrand
jekstrand at kemper.freedesktop.org
Wed Apr 20 17:33:55 UTC 2016
Module: Mesa
Branch: master
Commit: 2ef7aef3224cabf70edb409ef0d44b77eedc46ac
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=2ef7aef3224cabf70edb409ef0d44b77eedc46ac
Author: Jason Ekstrand <jason.ekstrand at intel.com>
Date: Wed Apr 20 10:32:59 2016 -0700
spirv: Trivially handle the NonWriteable decoration
Signed-off-by: Jason Ekstrand <jason at jlekstrand.net>
---
src/compiler/spirv/spirv_to_nir.c | 1 +
src/compiler/spirv/vtn_variables.c | 3 +++
2 files changed, 4 insertions(+)
diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c
index 99514b4..8d4f771 100644
--- a/src/compiler/spirv/spirv_to_nir.c
+++ b/src/compiler/spirv/spirv_to_nir.c
@@ -454,6 +454,7 @@ struct_member_decoration_cb(struct vtn_builder *b,
assert(member < ctx->num_fields);
switch (dec->decoration) {
+ case SpvDecorationNonWritable:
case SpvDecorationRelaxedPrecision:
break; /* FIXME: Do nothing with this for now. */
case SpvDecorationNoPerspective:
diff --git a/src/compiler/spirv/vtn_variables.c b/src/compiler/spirv/vtn_variables.c
index 3cbac1e..3b495b2 100644
--- a/src/compiler/spirv/vtn_variables.c
+++ b/src/compiler/spirv/vtn_variables.c
@@ -895,6 +895,9 @@ var_decoration_cb(struct vtn_builder *b, struct vtn_value *val, int member,
/* Handle decorations that apply to a vtn_variable as a whole */
switch (dec->decoration) {
+ case SpvDecorationNonWritable:
+ /* Do nothing with this for now */
+ return;
case SpvDecorationBinding:
vtn_var->binding = dec->literals[0];
return;
More information about the mesa-commit
mailing list