glslang-zig/Test/baseResults/spv.intrinsicsDebugBreak.frag.out
Rex Xu 3225778615 Fix an issue of getExtBuiltins()
This function is used to import SPIR-V extended instruction set. It
mistakenly treated the name of SPIR-V extended instruction set as the
name of SPIR-V extension. For example, when we have such code

  getExtBuiltins("NonSemantic.DebugBreak")

'NonSemantic.DebugBreak' is added to SPIR-V extension. Rather, the
SPIR-V extension name should be 'SPV_KHR_non_semantics_info'. Therefore,
we must avoid this since the name of SPIR-V extended instruction set is
not necessarily equal to that of relevant SPIR-V extension. Adding a
SPIR-V extension must be done by calling addExtension() explicitly
outside this function.

This change also fixes disassembly issues of debugBreak().
2024-03-22 12:35:30 -04:00

22 lines
1 KiB
Text

spv.intrinsicsDebugBreak.frag
// Module Version 10000
// Generated by (magic number): 8000b
// Id's are bound by 8
Capability Shader
Extension "SPV_KHR_non_semantic_info"
1: ExtInstImport "GLSL.std.450"
6: ExtInstImport "NonSemantic.DebugBreak"
MemoryModel Logical GLSL450
EntryPoint Fragment 4 "main"
ExecutionMode 4 OriginUpperLeft
Source GLSL 460
SourceExtension "GL_EXT_spirv_intrinsics"
Name 4 "main"
2: TypeVoid
3: TypeFunction 2
4(main): 2 Function None 3
5: Label
7: 2 ExtInst 6(NonSemantic.DebugBreak) 1(DebugBreak)
Return
FunctionEnd