diff options
author | Karol Herbst <[email protected]> | 2020-06-15 02:35:20 +0200 |
---|---|---|
committer | Marge Bot <[email protected]> | 2020-06-22 11:41:31 +0000 |
commit | b78c3375904c0455f2e426f5569d713db3828583 (patch) | |
tree | 5e7ae87e340ee9c545d3ec63d25989968c1b7b4c | |
parent | aecca24d03a84fda14dc86b548304e6aaf250984 (diff) |
nv50/ir/print: add missing VIEWPORT_MASK handling
Also add an STATIC_ASSERT so we catch those issues automatically.
Signed-off-by: Karol Herbst <[email protected]>
Reviewed-by: Ilia Mirkin <[email protected]>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5512>
-rw-r--r-- | src/gallium/drivers/nouveau/codegen/nv50_ir_print.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_print.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_print.cpp index ce0d2507dc1..3381133dce4 100644 --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_print.cpp +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_print.cpp @@ -297,7 +297,7 @@ static const char *CondCodeStr[] = "o" }; -static const char *SemanticStr[SV_LAST + 1] = +static const char *SemanticStr[] = { "POSITION", "VERTEX_ID", @@ -307,6 +307,7 @@ static const char *SemanticStr[SV_LAST + 1] = "VERTEX_COUNT", "LAYER", "VIEWPORT_INDEX", + "VIEWPORT_MASK", "Y_DIR", "FACE", "POINT_SIZE", @@ -517,6 +518,8 @@ int Symbol::print(char *buf, size_t size, DataType ty) const int Symbol::print(char *buf, size_t size, Value *rel, Value *dimRel, DataType ty) const { + STATIC_ASSERT(ARRAY_SIZE(SemanticStr) == SV_LAST + 1); + size_t pos = 0; char c; |