From 6437f2d37b08972db5e4515bd124639c2903dda1 Mon Sep 17 00:00:00 2001 From: Jay Kwak <82421531+jkwak-work@users.noreply.github.com> Date: Fri, 10 Jan 2025 11:01:32 -0800 Subject: Fix potential test failures due to SPIRV validation failure (#6047) There are a few tests that are currently passing but could fail when conditions change little bit. When slang-test runs with `test-server`, the spirv validation fails and the test gets reported as failed even though they are actually passing. To avoid the potential problem, this commit adds an empty entry point. Co-authored-by: Yong He --- tests/diagnostics/uninitialized-struct-from-constructor.slang | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'tests/diagnostics/uninitialized-struct-from-constructor.slang') diff --git a/tests/diagnostics/uninitialized-struct-from-constructor.slang b/tests/diagnostics/uninitialized-struct-from-constructor.slang index e3c44dca1..a422ac765 100644 --- a/tests/diagnostics/uninitialized-struct-from-constructor.slang +++ b/tests/diagnostics/uninitialized-struct-from-constructor.slang @@ -1,4 +1,4 @@ -//TEST:SIMPLE(filecheck=CHK): -target spirv +//TEST:SIMPLE(filecheck=CHK): -target spirv -entry computeMain struct TangentSpace { @@ -21,4 +21,11 @@ struct TangentSpace } //CHK-NOT: warning 41020 -//CHK-NOT: warning 41021 \ No newline at end of file +//CHK-NOT: warning 41021 + +[Shader("compute")] +[NumThreads(4, 1, 1)] +void computeMain(int3 dispatchThreadID : SV_DispatchThreadID) +{ +} + -- cgit v1.2.3