diff options
| author | Jay Kwak <82421531+jkwak-work@users.noreply.github.com> | 2025-06-18 07:15:35 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-18 14:15:35 +0000 |
| commit | 63ca2325d7f6afdbf07e8f00975fab01ec516302 (patch) | |
| tree | bfe65a8bd608b768c3df80bc2a41be6199706109 /tests/diagnostics/syntax-error-op-line-3.slang | |
| parent | 8c100305c8e1ac29b008e7cb95c0498b6adf197c (diff) | |
Fix false negative result for CUDA with recent versions (#7409)
* Fix false negative result for CUDA with recent versions
From CUDA version 12.8 and above, nvrtc returns an exit code treated as
an error. Some of slang-test test cases had to change from TEST to
DIAGONOSTIC_TEST to handle it properly.
Diffstat (limited to 'tests/diagnostics/syntax-error-op-line-3.slang')
| -rw-r--r-- | tests/diagnostics/syntax-error-op-line-3.slang | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/tests/diagnostics/syntax-error-op-line-3.slang b/tests/diagnostics/syntax-error-op-line-3.slang index 51b2bded7..248df721d 100644 --- a/tests/diagnostics/syntax-error-op-line-3.slang +++ b/tests/diagnostics/syntax-error-op-line-3.slang @@ -1,27 +1,27 @@ // syntax-error-op-line-3.slang // NOTE! That although this is a 'diagnostic' like test, it tests using downstream compiler -// the downstream compiler being present is a requirement, so we mark as a 'TEST' so that +// the downstream compiler being present is a requirement, so we mark as a 'TEST' so that // those tests are made. -//TEST:SIMPLE_LINE:-entry computeMain -target spirv -emit-spirv-via-glsl -//TEST:SIMPLE_LINE:-entry computeMain -target dxil -profile cs_6_0 -//TEST:SIMPLE_LINE:-entry computeMain -target dxbc -//TEST:SIMPLE_LINE:-entry computeMain -target shader-dll -//TEST:SIMPLE_LINE:-entry computeMain -target ptx +//TEST:SIMPLE(filecheck=CHK):-entry computeMain -target spirv -emit-spirv-via-glsl +//TEST:SIMPLE(filecheck=CHK):-entry computeMain -target dxil -profile cs_6_0 +//TEST:SIMPLE(filecheck=CHK):-entry computeMain -target dxbc +//TEST:SIMPLE(filecheck=CHK):-entry computeMain -target shader-dll +//TEST:SIMPLE(filecheck=CHK):-entry computeMain -target ptx //TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer; -// Here the thing being checked is error reporting around return, and += +// Here the thing being checked is error reporting around return, and += [__unsafeForceInlineEarly] int doSomething(int a) { a += a; - - return a - += + + return a + += __SyntaxError(); } @@ -30,12 +30,12 @@ int doSomething(int a) void computeMain(uint3 dispatchThreadID : SV_DispatchThreadID) { int id = int(dispatchThreadID.x); - + int v = int(dispatchThreadID.y); - - - + + + //CHK:([[#@LINE+1]]): error v += doSomething(id); - + outputBuffer[id] = v; -}
\ No newline at end of file +} |
