summaryrefslogtreecommitdiff
path: root/tests/language-feature/capability/capabilitySimplification1.slang
diff options
context:
space:
mode:
Diffstat (limited to 'tests/language-feature/capability/capabilitySimplification1.slang')
-rw-r--r--tests/language-feature/capability/capabilitySimplification1.slang30
1 files changed, 12 insertions, 18 deletions
diff --git a/tests/language-feature/capability/capabilitySimplification1.slang b/tests/language-feature/capability/capabilitySimplification1.slang
index 440ac1ced..0e6303412 100644
--- a/tests/language-feature/capability/capabilitySimplification1.slang
+++ b/tests/language-feature/capability/capabilitySimplification1.slang
@@ -1,24 +1,13 @@
//TEST:SIMPLE(filecheck=CHECK): -target glsl -entry computeMain -stage compute -profile sm_5_0
//TEST:SIMPLE(filecheck=CHECK_IGNORE_CAPS): -target glsl -emit-spirv-directly -entry computeMain -stage compute -profile sm_5_0 -ignore-capabilities
-
// CHECK_IGNORE_CAPS-NOT: error 36107
-// CHECK: error 36107
-// CHECK-SAME: entrypoint 'computeMain' uses features that are not available in 'compute' stage for 'glsl' target.
-// CHECK: capabilitySimplification1.slang(21): note: see using of 'WaveMultiPrefixCountBits'
-// CHECK-NOT: see using of 'WaveMultiPrefixCountBits'
-// CHECK: {{.*}}.meta.slang({{.*}}): note: see definition of 'WaveMultiPrefixCountBits'
-// CHECK: {{.*}}.meta.slang({{.*}}): note: see declaration of 'require'
-
-void nestedSafeCall()
-{
- AllMemoryBarrier();
-}
-
-void nestedBadCall()
+[numthreads(1, 1, 1)]
+// CHECK: ([[# @LINE+1]]): error 36107: {{.*}}computeMain{{.*}}compute{{.*}}glsl
+void computeMain()
{
- WaveMultiPrefixCountBits(true, 0);
+ nestedCall();
}
void nestedCall()
@@ -27,8 +16,13 @@ void nestedCall()
nestedBadCall();
}
-[numthreads(1,1,1)]
-void computeMain()
+void nestedSafeCall()
{
- nestedCall();
+ AllMemoryBarrier();
}
+
+void nestedBadCall()
+{
+ // CHECK: ([[# @LINE+1]]): note: see using of 'WaveMultiPrefixCountBits'
+ WaveMultiPrefixCountBits(true, 0);
+} \ No newline at end of file