Mesa (main): agx: Pack SR immediate
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sat Jun 5 21:05:53 UTC 2021
Module: Mesa
Branch: main
Commit: 75cafd84722abb39059f8b9e1144de67a01ebf9a
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=75cafd84722abb39059f8b9e1144de67a01ebf9a
Author: Alyssa Rosenzweig <alyssa at rosenzweig.io>
Date: Sat Jun 5 14:54:20 2021 -0400
agx: Pack SR immediate
Signed-off-by: Alyssa Rosenzweig <alyssa at rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11199>
---
src/asahi/compiler/agx_pack.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/asahi/compiler/agx_pack.c b/src/asahi/compiler/agx_pack.c
index e699fad4e02..fdafbde34bb 100644
--- a/src/asahi/compiler/agx_pack.c
+++ b/src/asahi/compiler/agx_pack.c
@@ -326,6 +326,9 @@ agx_pack_alu(struct util_dynarray *emission, agx_instr *I)
raw |= (uint64_t) (I->mask & 0x3) << 38;
raw |= (uint64_t) ((I->mask >> 2) & 0x3) << 50;
raw |= (uint64_t) ((I->mask >> 4) & 0x1) << 63;
+ } else if (info.immediates & AGX_IMMEDIATE_SR) {
+ raw |= (uint64_t) (I->sr & 0x3F) << 16;
+ raw |= (uint64_t) (I->sr >> 6) << 26;
} else if (info.immediates & AGX_IMMEDIATE_WRITEOUT)
raw |= (uint64_t) (I->imm) << 8;
else if (info.immediates & AGX_IMMEDIATE_IMM)
More information about the mesa-commit
mailing list