Mesa (main): pan/bi: Align 64-bit register sources
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Thu Jun 2 17:30:01 UTC 2022
Module: Mesa
Branch: main
Commit: 0770e7a90ce2786cc716b12b1c5ba7a217f14c74
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=0770e7a90ce2786cc716b12b1c5ba7a217f14c74
Author: Alyssa Rosenzweig <alyssa at collabora.com>
Date: Sun Mar 13 19:27:32 2022 -0400
pan/bi: Align 64-bit register sources
Similar idea to aligning staging register sources.
Signed-off-by: Alyssa Rosenzweig <alyssa at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16780>
---
src/panfrost/bifrost/bi_ra.c | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/src/panfrost/bifrost/bi_ra.c b/src/panfrost/bifrost/bi_ra.c
index 1b576394450..3ad55144abd 100644
--- a/src/panfrost/bifrost/bi_ra.c
+++ b/src/panfrost/bifrost/bi_ra.c
@@ -304,12 +304,16 @@ bi_mark_interference(bi_block *block, struct lcra_state *l, uint8_t *live, uint6
}
}
- /* Valhall needs >= 64-bit staging reads to be pair-aligned */
- if (aligned_sr && bi_count_read_registers(ins, 0) >= 2) {
- unsigned node = bi_get_node(ins->src[0]);
-
- if (node < node_count)
- l->affinity[node] &= EVEN_BITS_MASK;
+ /* Valhall needs >= 64-bit reads to be pair-aligned */
+ if (aligned_sr) {
+ bi_foreach_src(ins, s) {
+ if (bi_count_read_registers(ins, s) >= 2) {
+ unsigned node = bi_get_node(ins->src[s]);
+
+ if (node < node_count)
+ l->affinity[node] &= EVEN_BITS_MASK;
+ }
+ }
}
if (!is_blend && ins->op == BI_OPCODE_BLEND) {
More information about the mesa-commit
mailing list