summaryrefslogtreecommitdiffstatshomepage
path: root/3rdparty/bgfx/3rdparty/spirv-cross/shaders/asm/comp/bitcast_icmp.asm.comp
diff options
context:
space:
mode:
Diffstat (limited to '3rdparty/bgfx/3rdparty/spirv-cross/shaders/asm/comp/bitcast_icmp.asm.comp')
-rw-r--r--3rdparty/bgfx/3rdparty/spirv-cross/shaders/asm/comp/bitcast_icmp.asm.comp101
1 files changed, 101 insertions, 0 deletions
diff --git a/3rdparty/bgfx/3rdparty/spirv-cross/shaders/asm/comp/bitcast_icmp.asm.comp b/3rdparty/bgfx/3rdparty/spirv-cross/shaders/asm/comp/bitcast_icmp.asm.comp
new file mode 100644
index 00000000000..b7b4e0b2e1e
--- /dev/null
+++ b/3rdparty/bgfx/3rdparty/spirv-cross/shaders/asm/comp/bitcast_icmp.asm.comp
@@ -0,0 +1,101 @@
+; SPIR-V
+; Version: 1.0
+; Generator: Khronos Glslang Reference Front End; 1
+; Bound: 30
+; Schema: 0
+ OpCapability Shader
+ %1 = OpExtInstImport "GLSL.std.450"
+ OpMemoryModel Logical GLSL450
+ OpEntryPoint GLCompute %func "main"
+ OpExecutionMode %func LocalSize 1 1 1
+ OpSource ESSL 310
+ OpSourceExtension "GL_GOOGLE_cpp_style_line_directive"
+ OpSourceExtension "GL_GOOGLE_include_directive"
+ OpMemberDecorate %input_struct 0 Offset 0
+ OpMemberDecorate %input_struct 1 Offset 16
+ OpMemberDecorate %output_struct 0 Offset 0
+ OpMemberDecorate %output_struct 1 Offset 16
+ OpDecorate %input_struct BufferBlock
+ OpDecorate %inputs DescriptorSet 0
+ OpDecorate %inputs Binding 0
+ OpDecorate %inputs Restrict
+ OpDecorate %output_struct BufferBlock
+ OpDecorate %outputs DescriptorSet 0
+ OpDecorate %outputs Binding 1
+ OpDecorate %outputs Restrict
+
+ %void = OpTypeVoid
+ %main_func = OpTypeFunction %void
+
+ %bool = OpTypeBool
+ %bvec4 = OpTypeVector %bool 4
+
+ %uint = OpTypeInt 32 0
+ %uvec4 = OpTypeVector %uint 4
+
+ %int = OpTypeInt 32 1
+ %ivec4 = OpTypeVector %int 4
+
+ %ivec4_ptr = OpTypePointer Uniform %ivec4
+ %uvec4_ptr = OpTypePointer Uniform %uvec4
+
+ %zero = OpConstant %int 0
+ %one = OpConstant %int 1
+ %uzero = OpConstant %uint 0
+ %uone = OpConstant %uint 1
+ %utrue = OpConstantComposite %uvec4 %uone %uone %uone %uone
+ %ufalse = OpConstantComposite %uvec4 %uzero %uzero %uzero %uzero
+
+ %input_struct = OpTypeStruct %ivec4 %uvec4
+ %input_struct_ptr = OpTypePointer Uniform %input_struct
+ %inputs = OpVariable %input_struct_ptr Uniform
+ %output_struct = OpTypeStruct %uvec4 %ivec4
+ %output_struct_ptr = OpTypePointer Uniform %output_struct
+ %outputs = OpVariable %output_struct_ptr Uniform
+
+ %func = OpFunction %void None %main_func
+ %block = OpLabel
+
+ %input1_ptr = OpAccessChain %ivec4_ptr %inputs %zero
+ %input0_ptr = OpAccessChain %uvec4_ptr %inputs %one
+ %input1 = OpLoad %ivec4 %input1_ptr
+ %input0 = OpLoad %uvec4 %input0_ptr
+
+ %output_ptr_uvec4 = OpAccessChain %uvec4_ptr %outputs %zero
+
+ %result_slt = OpSLessThan %bvec4 %input0 %input1
+ %result_sle = OpSLessThanEqual %bvec4 %input0 %input1
+ %result_ult = OpULessThan %bvec4 %input0 %input1
+ %result_ule = OpULessThanEqual %bvec4 %input0 %input1
+ %result_sgt = OpSGreaterThan %bvec4 %input0 %input1
+ %result_sge = OpSGreaterThanEqual %bvec4 %input0 %input1
+ %result_ugt = OpUGreaterThan %bvec4 %input0 %input1
+ %result_uge = OpUGreaterThanEqual %bvec4 %input0 %input1
+
+ %int_slt = OpSelect %uvec4 %result_slt %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_slt
+
+ %int_sle = OpSelect %uvec4 %result_sle %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_sle
+
+ %int_ult = OpSelect %uvec4 %result_ult %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_ult
+
+ %int_ule = OpSelect %uvec4 %result_ule %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_ule
+
+ %int_sgt = OpSelect %uvec4 %result_sgt %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_sgt
+
+ %int_sge = OpSelect %uvec4 %result_sge %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_sge
+
+ %int_ugt = OpSelect %uvec4 %result_ugt %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_ugt
+
+ %int_uge = OpSelect %uvec4 %result_uge %utrue %ufalse
+ OpStore %output_ptr_uvec4 %int_uge
+
+
+ OpReturn
+ OpFunctionEnd