blob: b973b5b7084e60b2260bc97bf740a58e5e1cc874 [file] [log] [blame]
// We use -O0 here because the compiler is smart enough to realise calling
// a function that does nothing can be removed.
// RUN: clspv -O0 %s -o %t.spv
// RUN: spirv-dis -o %t2.spvasm %t.spv
// RUN: FileCheck %s < %t2.spvasm
// RUN: spirv-val --target-env vulkan1.0 %t.spv
// CHECK: %[[BAR_ID:[a-zA-Z0-9_]*]] = OpFunction
void bar()
{
}
void kernel __attribute__((reqd_work_group_size(1, 1, 1))) foo()
{
// CHECK: OpFunctionCall {{.*}} %[[BAR_ID]]
bar();
}