Skip to content

Instantly share code, notes, and snippets.

@metora
Created August 16, 2017 11:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save metora/5f653cc6664148f0915e71e6cc78cf1e to your computer and use it in GitHub Desktop.
Save metora/5f653cc6664148f0915e71e6cc78cf1e to your computer and use it in GitHub Desktop.
vulkan_spirv_mesa_9.spv.dspv
; SPIR-V
; Version: 1.0
; Generator: Khronos Glslang Reference Front End; 1
; Bound: 40
; Schema: 0
OpCapability Shader
%1 = OpExtInstImport "GLSL.std.450"
OpMemoryModel Logical GLSL450
OpEntryPoint Fragment %11 "main" %6 %8
OpExecutionMode %11 OriginUpperLeft
OpSource GLSL 450
OpName %6 "VaryUVSet0"
OpName %8 "OutColor0"
OpName %11 "main"
OpName %14 "OutputColor"
OpName %16 "texture_retval"
OpName %21 "Base"
OpDecorate %6 Location 0
OpDecorate %8 Location 0
OpDecorate %21 DescriptorSet 0
OpDecorate %21 Binding 1
%2 = OpTypeFloat 32
%3 = OpTypeVector %2 2
%4 = OpTypeVector %2 4
%5 = OpTypePointer Input %3
%6 = OpVariable %5 Input
%7 = OpTypePointer Output %4
%8 = OpVariable %7 Output
%9 = OpTypeVoid
%10 = OpTypeFunction %9
%13 = OpTypePointer Function %4
%15 = OpTypePointer Function %4
%17 = OpTypeImage %2 2D 0 0 0 1 Unknown
%18 = OpTypeSampledImage %17
%19 = OpTypePointer UniformConstant %18
%21 = OpVariable %19 UniformConstant
%25 = OpTypeVector %2 3
%31 = OpConstant %2 0
%33 = OpConstant %2 1
%35 = OpTypePointer Function %2
%36 = OpTypeInt 32 1
%37 = OpConstant %36 3
%11 = OpFunction %9 None %10
%12 = OpLabel
%14 = OpVariable %13 Function
%16 = OpVariable %15 Function
%20 = OpLoad %18 %21
%22 = OpLoad %3 %6
%23 = OpImageSampleImplicitLod %4 %20 %22
OpStore %16 %23
%24 = OpLoad %4 %16
%26 = OpVectorShuffle %25 %24 %24 0 1 2
%27 = OpLoad %4 %14
%28 = OpVectorShuffle %4 %27 %26 4 5 6 3
OpStore %14 %28
%29 = OpLoad %4 %16
%30 = OpCompositeExtract %2 %29 3
%32 = OpExtInst %2 %1 FMax %30 %31
%34 = OpExtInst %2 %1 FMin %32 %33
%38 = OpAccessChain %35 %14 %37
OpStore %38 %34
%39 = OpLoad %4 %14
OpStore %8 %39
OpReturn
OpFunctionEnd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment