Mesa (master): ac/nir: implement nir_op_[un]pack_64_4x16

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Oct 28 10:26:39 UTC 2020


Module: Mesa
Branch: master
Commit: 121fa017e1da5dba0f70ffdc39ddb2854ecc6193
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=121fa017e1da5dba0f70ffdc39ddb2854ecc6193

Author: Daniel Schürmann <daniel at schuermann.dev>
Date:   Mon Oct 26 11:52:00 2020 +0100

ac/nir: implement nir_op_[un]pack_64_4x16

Reviewed-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6527>

---

 src/amd/llvm/ac_nir_to_llvm.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/src/amd/llvm/ac_nir_to_llvm.c b/src/amd/llvm/ac_nir_to_llvm.c
index a510e44a483..31ca89b214e 100644
--- a/src/amd/llvm/ac_nir_to_llvm.c
+++ b/src/amd/llvm/ac_nir_to_llvm.c
@@ -1072,6 +1072,15 @@ static void visit_alu(struct ac_nir_context *ctx, const nir_alu_instr *instr)
       result = emit_ddxy(ctx, instr->op, src[0]);
       break;
 
+   case nir_op_unpack_64_4x16: {
+      result = LLVMBuildBitCast(ctx->ac.builder, src[0], ctx->ac.v4i16, "");
+      break;
+   }
+   case nir_op_pack_64_4x16: {
+      result = LLVMBuildBitCast(ctx->ac.builder, src[0], ctx->ac.i64, "");
+      break;
+   }
+
    case nir_op_unpack_64_2x32: {
       result = LLVMBuildBitCast(ctx->ac.builder, src[0],
             ctx->ac.v2i32, "");



More information about the mesa-commit mailing list