Skip to content

SPIR-V validation failed: OpenCL.DebugInfo.100 DebugFunction: expected operand Declaration must be a result id of DebugFunctionDeclaration #3247

Open
@pvelesko

Description

@pvelesko

; Steps to reproduce:
; 1. llvm-spirv --spirv-max-version=1.1 --spirv-ext=+all -o reproducer.spv debug_spirv_reproducer.ll
; 2. spirv-val reproducer.spv
;
; Expected error:
; SPIR-V validation failed: OpenCL.DebugInfo.100 DebugFunction: expected operand Declaration must be a result id of DebugFunctionDeclaration
; %N = OpExtInst %void %2 DebugFunction %M %L %K 4 0 %J %O FlagIsDefinition|FlagPrototyped 4 %_Z5kernelv %P
;
; The issue: llvm-spirv generates DebugFunction with DebugInfoNone instead of DebugFunctionDeclaration

debug_spirv_reproducer.ll.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions