summaryrefslogtreecommitdiffstats
path: root/src/gallium
diff options
context:
space:
mode:
authorErik Faye-Lund <[email protected]>2019-07-19 15:02:49 +0200
committerErik Faye-Lund <[email protected]>2019-10-28 08:51:47 +0000
commitf4ad93462c2628c9edf9cf3eaccbad969198fd77 (patch)
treeae3a9df8a820035fadcf75b9b74f3ce8affe7904 /src/gallium
parent103776ab9cbadaedb58bbb99890f19495a38e3e4 (diff)
zink/spirv: implement bitwise ops
Acked-by: Jordan Justen <[email protected]>
Diffstat (limited to 'src/gallium')
-rw-r--r--src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c3
1 files changed, 3 insertions, 0 deletions
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) \