aboutsummaryrefslogtreecommitdiffstats
path: root/src/compiler/spirv/vtn_opencl.c
diff options
context:
space:
mode:
authorErik Faye-Lund <[email protected]>2020-04-29 18:31:44 +0200
committerMarge Bot <[email protected]>2020-05-04 11:31:29 +0000
commit337ff9c0889c86be398b10a2a962a40c1c2b2840 (patch)
tree81c1ee9dde591217e3d6f517703e8e0ba9a8594e /src/compiler/spirv/vtn_opencl.c
parent2ab6a58c197ca88d6c7e8a3f9fa841f0a594a96a (diff)
vtn/opencl: native rsqrt support
Reviewed-by: Alyssa Rosenzweig <[email protected]> Reviewed-By: Karol Herbst <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4811>
Diffstat (limited to 'src/compiler/spirv/vtn_opencl.c')
-rw-r--r--src/compiler/spirv/vtn_opencl.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/compiler/spirv/vtn_opencl.c b/src/compiler/spirv/vtn_opencl.c
index 2ea8f714774..0c524b61605 100644
--- a/src/compiler/spirv/vtn_opencl.c
+++ b/src/compiler/spirv/vtn_opencl.c
@@ -90,6 +90,7 @@ nir_alu_op_for_opencl_opcode(struct vtn_builder *b,
case OpenCLstd_Native_log2: return nir_op_flog2;
case OpenCLstd_Native_powr: return nir_op_fpow;
case OpenCLstd_Native_recip: return nir_op_frcp;
+ case OpenCLstd_Native_rsqrt: return nir_op_frsq;
case OpenCLstd_Native_sin: return nir_op_fsin;
case OpenCLstd_SMul_hi: return nir_op_imul_high;
case OpenCLstd_UMul_hi: return nir_op_umul_high;
@@ -363,6 +364,7 @@ vtn_handle_opencl_instruction(struct vtn_builder *b, SpvOp ext_opcode,
case OpenCLstd_Native_log2:
case OpenCLstd_Native_powr:
case OpenCLstd_Native_recip:
+ case OpenCLstd_Native_rsqrt:
case OpenCLstd_Native_sin:
case OpenCLstd_Fmod:
case OpenCLstd_SMul_hi: