Mesa (main): pan/bi: Use should_skip in bi_builder generation
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Thu Apr 7 18:25:32 UTC 2022
Module: Mesa
Branch: main
Commit: a747708b9d59cbe0f3801cac6f39ae3159023cc1
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=a747708b9d59cbe0f3801cac6f39ae3159023cc1
Author: Alyssa Rosenzweig <alyssa at collabora.com>
Date: Sun Feb 27 15:22:03 2022 -0500
pan/bi: Use should_skip in bi_builder generation
To avoid further code duplication.
Signed-off-by: Alyssa Rosenzweig <alyssa at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15187>
---
src/panfrost/bifrost/bi_builder.h.py | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/panfrost/bifrost/bi_builder.h.py b/src/panfrost/bifrost/bi_builder.h.py
index b3ccafd26e8..81b78b7177e 100644
--- a/src/panfrost/bifrost/bi_builder.h.py
+++ b/src/panfrost/bifrost/bi_builder.h.py
@@ -99,7 +99,7 @@ bi_instr * bi_${opcode.replace('.', '_').lower()}${to_suffix(ops[opcode])}(${sig
I->src[${src}] = src${src};
% endfor
% for mod in ops[opcode]["modifiers"]:
-% if mod[0:-1] not in SKIP and mod not in SKIP:
+% if not should_skip(mod):
I->${mod} = ${mod};
% endif
% endfor
@@ -198,4 +198,6 @@ def arguments(op, temp_dest = True):
modifier_signature(op) +
op["immediates"])
-print(Template(COPYRIGHT + TEMPLATE).render(ops = ir_instructions, modifiers = modifier_lists, signature = signature, arguments = arguments, src_count = src_count, typesize = typesize, SKIP = SKIP))
+print(Template(COPYRIGHT + TEMPLATE).render(ops = ir_instructions, modifiers =
+ modifier_lists, signature = signature, arguments = arguments, src_count =
+ src_count, typesize = typesize, should_skip = should_skip))
More information about the mesa-commit
mailing list