From f4ad93462c2628c9edf9cf3eaccbad969198fd77 Mon Sep 17 00:00:00 2001 From: Erik Faye-Lund Date: Fri, 19 Jul 2019 15:02:49 +0200 Subject: [PATCH] zink/spirv: implement bitwise ops Acked-by: Jordan Justen --- src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c index a78a26b4bb3..0455beabfc6 100644 --- a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c +++ b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c @@ -803,6 +803,7 @@ emit_alu(struct ntv_context *ctx, nir_alu_instr *alu) UNOP(nir_op_f2u32, SpvOpConvertFToU) UNOP(nir_op_i2f32, SpvOpConvertSToF) UNOP(nir_op_u2f32, SpvOpConvertUToF) + UNOP(nir_op_inot, SpvOpNot) #undef UNOP #define BUILTIN_UNOP(nir_op, spirv_op) \ @@ -871,6 +872,8 @@ emit_alu(struct ntv_context *ctx, nir_alu_instr *alu) BINOP(nir_op_ishl, SpvOpShiftLeftLogical) BINOP(nir_op_ishr, SpvOpShiftRightArithmetic) BINOP(nir_op_ushr, SpvOpShiftRightLogical) + BINOP(nir_op_iand, SpvOpBitwiseAnd) + BINOP(nir_op_ior, SpvOpBitwiseOr) #undef BINOP #define BUILTIN_BINOP(nir_op, spirv_op) \ -- 2.30.2