diff options
| author | Yong He <yonghe@outlook.com> | 2020-12-03 08:23:05 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-12-03 08:23:05 -0800 |
| commit | 44c0a56974b664e50b2cb8cb6f10740b19c4e02f (patch) | |
| tree | d6141003be376bdb2c0037178b649b6b2aae673e /tests | |
| parent | ad5dda9261bae63e32bcb914b109fcb5c92faf25 (diff) | |
Add shader object parameter binding to renderer_test. (#1622)
* Add shader object parameter binding to renderer_test.
* remove multiple-definitions.hlsl
* Fix cuda implementation.
Co-authored-by: Tim Foley <tfoleyNV@users.noreply.github.com>
Diffstat (limited to 'tests')
36 files changed, 76 insertions, 66 deletions
diff --git a/tests/bugs/bool-init.slang b/tests/bugs/bool-init.slang index 7484d450e..1e9627024 100644 --- a/tests/bugs/bool-init.slang +++ b/tests/bugs/bool-init.slang @@ -7,7 +7,7 @@ struct Thing bool b; }; -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer; [numthreads(4, 1, 1)] diff --git a/tests/bugs/bool-op.slang b/tests/bugs/bool-op.slang index 1ce5d7c4f..c10c7e0dd 100644 --- a/tests/bugs/bool-op.slang +++ b/tests/bugs/bool-op.slang @@ -4,7 +4,7 @@ // Confirm operations that produce bools - such as comparisons, or && ||, ! work correctly -//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer; [numthreads(16, 1, 1)] diff --git a/tests/bugs/gh-357.slang b/tests/bugs/gh-357.slang index 7c2a87a41..90eba799b 100644 --- a/tests/bugs/gh-357.slang +++ b/tests/bugs/gh-357.slang @@ -1,5 +1,7 @@ //TEST(compute):COMPARE_COMPUTE: -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out + +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer + //TEST_INPUT:type AssocImpl diff --git a/tests/bugs/gh-471.slang b/tests/bugs/gh-471.slang index a68ade010..adc50e799 100644 --- a/tests/bugs/gh-471.slang +++ b/tests/bugs/gh-471.slang @@ -1,5 +1,5 @@ //TEST(compute):COMPARE_COMPUTE: -//TEST_INPUT:ubuffer(data=[0 1 2 3], stride=4):out +//TEST_INPUT:ubuffer(data=[0 1 2 3], stride=4):out,name outputBuffer // Test that "operator comma" works as expected diff --git a/tests/bugs/gh-487.slang b/tests/bugs/gh-487.slang index a86c4061f..08ae8aa06 100644 --- a/tests/bugs/gh-487.slang +++ b/tests/bugs/gh-487.slang @@ -15,7 +15,7 @@ int test(int val) return int(result); } -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name gBuffer RWStructuredBuffer<int> gBuffer; [numthreads(4, 1, 1)] diff --git a/tests/bugs/gh-518.slang b/tests/bugs/gh-518.slang index 3f316c19e..8de61a94e 100644 --- a/tests/bugs/gh-518.slang +++ b/tests/bugs/gh-518.slang @@ -8,11 +8,11 @@ // Confirm that we can handle arrays of resources // being passed to a function. -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name gBuffer RWStructuredBuffer<int> gBuffer; -//TEST_INPUT: Texture2D(size=4, content=one): -//TEST_INPUT: Texture2D(size=4, content=one): +//TEST_INPUT: Texture2D(size=4, content=one):name gTextures[0] +//TEST_INPUT: Texture2D(size=4, content=one):name gTextures[1] Texture2D gTextures[2]; float broken(Texture2D t[2]) diff --git a/tests/bugs/gh-519.slang b/tests/bugs/gh-519.slang index 733864c85..207fa6d0a 100644 --- a/tests/bugs/gh-519.slang +++ b/tests/bugs/gh-519.slang @@ -29,7 +29,7 @@ int test(int val) return tmp; } -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name gBuffer RWStructuredBuffer<int> gBuffer; [numthreads(4, 1, 1)] diff --git a/tests/bugs/gh-566.slang b/tests/bugs/gh-566.slang index 5e5803aea..4c5fa1772 100644 --- a/tests/bugs/gh-566.slang +++ b/tests/bugs/gh-566.slang @@ -1,8 +1,8 @@ // legalize-struct-init.slang //TEST(compute):COMPARE_COMPUTE: -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out -//TEST_INPUT:ubuffer(data=[4 3 2 1], stride=4): +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer +//TEST_INPUT:ubuffer(data=[4 3 2 1], stride=4):name inputBuffer RWStructuredBuffer<uint> outputBuffer; diff --git a/tests/bugs/gh-569.slang b/tests/bugs/gh-569.slang index c0a65aaa8..21fbfa514 100644 --- a/tests/bugs/gh-569.slang +++ b/tests/bugs/gh-569.slang @@ -21,7 +21,7 @@ uint test(uint inVal) return tmp + inVal; } -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name gBuffer RWStructuredBuffer<uint> gBuffer; [numthreads(4, 1, 1)] diff --git a/tests/bugs/gh-775.slang b/tests/bugs/gh-775.slang index f98765bdb..867233919 100644 --- a/tests/bugs/gh-775.slang +++ b/tests/bugs/gh-775.slang @@ -17,7 +17,7 @@ int test(int inVal) return int(dot(v, float4(1, 16, 256, 4096))); } -//TEST_INPUT:ubuffer(data=[9 9 9 9], stride=4):out +//TEST_INPUT:ubuffer(data=[9 9 9 9], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer : register(u0); [numthreads(4, 1, 1)] diff --git a/tests/bugs/gl-33.slang b/tests/bugs/gl-33.slang index b459bf409..10c9ea208 100644 --- a/tests/bugs/gl-33.slang +++ b/tests/bugs/gl-33.slang @@ -13,7 +13,7 @@ int test(int val) return b.next(); } -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name gBuffer RWStructuredBuffer<int> gBuffer; [numthreads(4, 1, 1)] diff --git a/tests/bugs/glsl-static-const-array.slang b/tests/bugs/glsl-static-const-array.slang index f4e953259..4d03d5ef8 100644 --- a/tests/bugs/glsl-static-const-array.slang +++ b/tests/bugs/glsl-static-const-array.slang @@ -7,7 +7,7 @@ static const int gData[4] = 0xA, 0xB, 0xC, 0xD, }; -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name gBuffer RWStructuredBuffer<int> gBuffer; [numthreads(4,1,1)] diff --git a/tests/bugs/nested-generics-call.slang b/tests/bugs/nested-generics-call.slang index 9a540a261..ba1566ec2 100644 --- a/tests/bugs/nested-generics-call.slang +++ b/tests/bugs/nested-generics-call.slang @@ -1,6 +1,6 @@ //TEST(compute):COMPARE_COMPUTE: -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<float> outputBuffer; interface IBase diff --git a/tests/bugs/nested-generics-method-call.slang b/tests/bugs/nested-generics-method-call.slang index a127ed0da..fa0a983b9 100644 --- a/tests/bugs/nested-generics-method-call.slang +++ b/tests/bugs/nested-generics-method-call.slang @@ -1,6 +1,6 @@ //TEST(compute):COMPARE_COMPUTE: -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<float> outputBuffer; interface IBase diff --git a/tests/bugs/paren-insertion-bug.slang b/tests/bugs/paren-insertion-bug.slang index 6c989d793..790934372 100644 --- a/tests/bugs/paren-insertion-bug.slang +++ b/tests/bugs/paren-insertion-bug.slang @@ -19,7 +19,7 @@ int test(float a) } -//TEST_INPUT: ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT: ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<uint> outputBuffer; [numthreads(4, 1, 1)] diff --git a/tests/bugs/static-method.slang b/tests/bugs/static-method.slang index c728e9053..f95d40def 100644 --- a/tests/bugs/static-method.slang +++ b/tests/bugs/static-method.slang @@ -10,7 +10,7 @@ struct S } } -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer : register(u0); int test(int t) diff --git a/tests/bugs/static-var.slang b/tests/bugs/static-var.slang index d130b6a7d..75662c7b5 100644 --- a/tests/bugs/static-var.slang +++ b/tests/bugs/static-var.slang @@ -7,7 +7,7 @@ int test(int inVal) return inVal + kVal; } -//TEST_INPUT:ubuffer(data=[9 9 9 9], stride=4):out +//TEST_INPUT:ubuffer(data=[9 9 9 9], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer : register(u0); [numthreads(4, 1, 1)] diff --git a/tests/bugs/texture2d-gather.hlsl b/tests/bugs/texture2d-gather.hlsl index 2fc9424c5..6eb8b1af7 100644 --- a/tests/bugs/texture2d-gather.hlsl +++ b/tests/bugs/texture2d-gather.hlsl @@ -1,6 +1,6 @@ //TEST(smoke):COMPARE_HLSL_RENDER: -//TEST_INPUT: Texture2D(size=16, content=chessboard, format=R_Float32): -//TEST_INPUT: Sampler : +//TEST_INPUT: Texture2D(size=16, content=chessboard, format=R_Float32):name g_texture +//TEST_INPUT: Sampler :name g_sampler Texture2D<float> g_texture : register(t0); SamplerState g_sampler : register(s0); diff --git a/tests/bugs/vec-compare.slang b/tests/bugs/vec-compare.slang index 2b233f80f..7a6d8388d 100644 --- a/tests/bugs/vec-compare.slang +++ b/tests/bugs/vec-compare.slang @@ -2,8 +2,7 @@ //TEST(compute):COMPARE_COMPUTE_EX:-slang -compute -dx12 //TEST(compute, vulkan):COMPARE_COMPUTE_EX:-vk -compute -//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out - +//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer; [numthreads(4,4,1)] diff --git a/tests/bugs/while-in-generic.slang b/tests/bugs/while-in-generic.slang index 7d2b8b255..4efa9a5d2 100644 --- a/tests/bugs/while-in-generic.slang +++ b/tests/bugs/while-in-generic.slang @@ -12,7 +12,7 @@ struct Context return i; } }; -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<int> outputBuffer; [numthreads(4, 1, 1)] diff --git a/tests/compute/cbuffer-legalize.slang b/tests/compute/cbuffer-legalize.slang index bbb08b565..416eded1e 100644 --- a/tests/compute/cbuffer-legalize.slang +++ b/tests/compute/cbuffer-legalize.slang @@ -1,8 +1,8 @@ //TEST(compute):COMPARE_COMPUTE:-cpu -//TEST(compute):COMPARE_COMPUTE: +//TEST(compute):COMPARE_COMPUTE:-shaderobj -//TEST_INPUT:cbuffer(data=[1 2 3 4]):name=C.p.c -//TEST_INPUT:Texture2D(size=4, content = one):name=C.p.t +//TEST_INPUT: Uniform(data=[1 2 3 4]):name=C.p.c +//TEST_INPUT: Texture2D(size=4, content = one):name=C.p.t //TEST_INPUT: Sampler:name=C.p.s //TEST_INPUT: ubuffer(data=[0 0 0 0], stride=4):out,name=outputBuffer diff --git a/tests/compute/compile-time-loop.slang b/tests/compute/compile-time-loop.slang index e081dfbd3..128e72895 100644 --- a/tests/compute/compile-time-loop.slang +++ b/tests/compute/compile-time-loop.slang @@ -1,8 +1,8 @@ //TEST(compute):COMPARE_RENDER_COMPUTE: -//TEST_INPUT: Texture2D(size=4, content = one): -//TEST_INPUT: Sampler: -//TEST_INPUT: ubuffer(data=[0], stride=4):out +//TEST_INPUT: Texture2D(size=4, content = one):name t +//TEST_INPUT: Sampler:name s +//TEST_INPUT: ubuffer(data=[0], stride=4):out, name outputBuffer Texture2D t; SamplerState s; diff --git a/tests/compute/constexpr.slang b/tests/compute/constexpr.slang index 247d3964d..cb14b1a9c 100644 --- a/tests/compute/constexpr.slang +++ b/tests/compute/constexpr.slang @@ -1,9 +1,10 @@ // constexpr.slang //TEST(compute):COMPARE_COMPUTE_EX:-slang -gcompute //DISABLED://TEST(compute, vulkan):COMPARE_COMPUTE_EX:-vk -gcompute -//TEST_INPUT: Texture2D(size=4, content = one): -//TEST_INPUT: Sampler: -//TEST_INPUT: ubuffer(data=[0 0], stride=4):out + +//TEST_INPUT: Texture2D(size=4, content = one):name tex +//TEST_INPUT: Sampler:name samp +//TEST_INPUT: ubuffer(data=[0 0], stride=4):out,name outputBuffer // Note: Vulkan version of this test is disabled pending adding // support for rendering tests to the harness. diff --git a/tests/compute/discard-stmt.slang b/tests/compute/discard-stmt.slang index 5a8210118..1af42c6a0 100644 --- a/tests/compute/discard-stmt.slang +++ b/tests/compute/discard-stmt.slang @@ -1,7 +1,7 @@ //TEST(compute):COMPARE_RENDER_COMPUTE: -//TEST_INPUT: Texture2D(size=4, content = one): -//TEST_INPUT: Sampler: -//TEST_INPUT: ubuffer(data=[0 0], stride=4):out +//TEST_INPUT: Texture2D(size=4, content = one):name tex +//TEST_INPUT: Sampler:name samp +//TEST_INPUT: ubuffer(data=[0 0], stride=4):out,name outputBuffer Texture2D tex; diff --git a/tests/compute/dump-repro.slang b/tests/compute/dump-repro.slang index dd07574ad..90a9578fa 100644 --- a/tests/compute/dump-repro.slang +++ b/tests/compute/dump-repro.slang @@ -13,4 +13,4 @@ void computeMain(uint3 dispatchThreadID : SV_DispatchThreadID) int index = int(dispatchThreadID.x); outputBuffer[index] = index * 2 + 1; -}
\ No newline at end of file +} diff --git a/tests/compute/global-generic-value-param.slang b/tests/compute/global-generic-value-param.slang index 6214925c6..d2299e501 100644 --- a/tests/compute/global-generic-value-param.slang +++ b/tests/compute/global-generic-value-param.slang @@ -29,7 +29,7 @@ __generic_value_param kOffset : uint = 0; // bit less trivial. // RWStructuredBuffer<uint> vals; -//TEST_INPUT: ubuffer(data=[0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15], stride=4): +//TEST_INPUT: ubuffer(data=[0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15], stride=4):name vals // The core test function will use the `kOffset` value // we declared above along with the input value (the @@ -45,7 +45,7 @@ uint test(uint value) // And finally we have the boilerplate cruft that almost // all of our compute tests use. -//TEST_INPUT: ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out +//TEST_INPUT: ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<uint> outputBuffer; [numthreads(16, 1, 1)] diff --git a/tests/compute/global-type-param-array.slang b/tests/compute/global-type-param-array.slang index ac514901f..f763f49fd 100644 --- a/tests/compute/global-type-param-array.slang +++ b/tests/compute/global-type-param-array.slang @@ -1,6 +1,7 @@ //TEST(compute):COMPARE_COMPUTE: -//TEST_INPUT: cbuffer(data=[1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0], stride=4): -//TEST_INPUT: ubuffer(data=[0], stride=4):out + +//TEST_INPUT: cbuffer(data=[1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0 1.0], stride=4):name impl +//TEST_INPUT: ubuffer(data=[0], stride=4):out,name outputBuffer //TEST_INPUT: type Pair<Arr<Base,1>, Pair<Arr<Base,2> , Base> > RWStructuredBuffer<float> outputBuffer; diff --git a/tests/compute/global-type-param-in-entrypoint.slang b/tests/compute/global-type-param-in-entrypoint.slang index 06320ba0f..b2a1146d8 100644 --- a/tests/compute/global-type-param-in-entrypoint.slang +++ b/tests/compute/global-type-param-in-entrypoint.slang @@ -1,6 +1,7 @@ //TEST(compute):COMPARE_RENDER_COMPUTE: -//TEST_INPUT: cbuffer(data=[1.0 0.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 1.0], stride=16): -//TEST_INPUT: ubuffer(data=[0 0 0 0], stride=4):out + +//TEST_INPUT: cbuffer(data=[1.0 0.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 1.0], stride=16):name Uniforms +//TEST_INPUT: ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer //TEST_INPUT: global_type VertImpl interface IVertInterpolant diff --git a/tests/compute/global-type-param1.slang b/tests/compute/global-type-param1.slang index 5362af5e0..b5560e9d9 100644 --- a/tests/compute/global-type-param1.slang +++ b/tests/compute/global-type-param1.slang @@ -1,11 +1,13 @@ //TEST(smoke,compute):COMPARE_COMPUTE: -//TEST_INPUT: cbuffer(data=[0.5 0 0 0 1.0], stride=4): -//TEST_INPUT: cbuffer(data=[1.0], stride=4): -//TEST_INPUT: Texture2D(size=4, content = zero): -//TEST_INPUT: Texture2D(size=4, content = one): -//TEST_INPUT: Sampler: -//TEST_INPUT: Sampler: -//TEST_INPUT: ubuffer(data=[0], stride=4):out + + +//TEST_INPUT: ubuffer(data=[0], stride=4):out,name outputBufer +//TEST_INPUT: cbuffer(data=[0.5 0 0 0 1.0], stride=4):name C +//TEST_INPUT: cbuffer(data=[1.0], stride=4):name impl.base +//TEST_INPUT: Texture2D(size=4, content = zero):name tex1 +//TEST_INPUT: Texture2D(size=4, content = one):name impl.tex +//TEST_INPUT: Sampler:name sampler +//TEST_INPUT: Sampler:name impl.sampler //TEST_INPUT: type Impl RWStructuredBuffer<float> outputBuffer; diff --git a/tests/compute/global-type-param2.slang b/tests/compute/global-type-param2.slang index d731e356a..39701f16f 100644 --- a/tests/compute/global-type-param2.slang +++ b/tests/compute/global-type-param2.slang @@ -1,11 +1,13 @@ //TEST(smoke,compute):COMPARE_COMPUTE: -//TEST_INPUT: cbuffer(data=[0.5 0 0 0], stride=4): -//TEST_INPUT: cbuffer(data=[1.0], stride=4): -//TEST_INPUT: Texture2D(size=4, content = zero): -//TEST_INPUT: Texture2D(size=4, content = one): -//TEST_INPUT: Sampler: -//TEST_INPUT: Sampler: -//TEST_INPUT: ubuffer(data=[0], stride=4):out + +//TEST_INPUT: ubuffer(data=[0], stride=4):out,name outputBuffer +//TEST_INPUT: cbuffer(data=[0.5 0 0 0], stride=4):name existingBuffer +//__disabled__TEST_INPUT: object(type=Impl):name impl +//TEST_INPUT: root_constants(data=[1.0], stride=4):name impl.base +//TEST_INPUT: Texture2D(size=4, content = zero):name tex1 +//TEST_INPUT: Texture2D(size=4, content = one):name impl.tex +//TEST_INPUT: Sampler:name sampler +//TEST_INPUT: Sampler:name impl.sampler //TEST_INPUT: type Impl diff --git a/tests/compute/half-calc.slang b/tests/compute/half-calc.slang index 7c94a0d4f..b9ed7c439 100644 --- a/tests/compute/half-calc.slang +++ b/tests/compute/half-calc.slang @@ -1,9 +1,10 @@ //DISABLE_TEST(compute):COMPARE_COMPUTE:-dx12 -compute -use-dxil -profile cs_6_2 -render-features half //TEST(compute):COMPARE_COMPUTE:-vk -compute -profile cs_6_2 -render-features half -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out + // Test for doing a calculation using half +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name outputBuffer RWStructuredBuffer<float> outputBuffer; [numthreads(4, 1, 1)] diff --git a/tests/compute/half-structured-buffer.slang b/tests/compute/half-structured-buffer.slang index 08323913e..abccfb32a 100644 --- a/tests/compute/half-structured-buffer.slang +++ b/tests/compute/half-structured-buffer.slang @@ -2,8 +2,6 @@ //Disable on Dx12 for now - because writing to structured buffer produces unexpected results //TEST_DISABLED(compute):COMPARE_COMPUTE:-dx12 -compute -use-dxil -profile cs_6_2 -render-features half -//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=16):out - struct Thing { uint pos; @@ -11,6 +9,7 @@ struct Thing half4 color; }; +//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0], stride=16):out,name outputBuffer RWStructuredBuffer<Thing> outputBuffer; [numthreads(4, 1, 1)] diff --git a/tests/compute/interface-shader-param.slang b/tests/compute/interface-shader-param.slang index dde7bf2a6..d4bc1d7fa 100644 --- a/tests/compute/interface-shader-param.slang +++ b/tests/compute/interface-shader-param.slang @@ -96,12 +96,14 @@ RWStructuredBuffer<int> gOutputBuffer; // Now we'll define a global shader parameter for the // random number generation strategy. // +//__disabled__TEST_INPUT:object(type=MyStrategy):name=gStrategy uniform IRandomNumberGenerationStrategy gStrategy; // The other parameter (for the modifier) will be attached // the entry point instead, so that we are testing both // cases. // +//__disabled__TEST_INPUT:object(type=MyModifier):name=modifier [numthreads(4, 1, 1)] void computeMain( //TEST_INPUT:root_constants(data=[0], stride=4): diff --git a/tests/compute/interface-shader-param4.slang b/tests/compute/interface-shader-param4.slang index da57175e9..fe8e6b374 100644 --- a/tests/compute/interface-shader-param4.slang +++ b/tests/compute/interface-shader-param4.slang @@ -44,7 +44,7 @@ int test( } -//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):out,name=gOutputBuffer RWStructuredBuffer<int> gOutputBuffer; // Note: a constant buffer register/binding is always claimed @@ -53,7 +53,7 @@ RWStructuredBuffer<int> gOutputBuffer; // that gets plugged in will involve uniform/ordinary data // or not. // -//TEST_INPUT:cbuffer(data=[0]): +//TEST_INPUT:cbuffer(data=[0]):name=gStrategy // ConstantBuffer<IRandomNumberGenerationStrategy> gStrategy; diff --git a/tests/compute/matrix-layout-structured-buffer.slang b/tests/compute/matrix-layout-structured-buffer.slang index bb7dbb381..56112f959 100644 --- a/tests/compute/matrix-layout-structured-buffer.slang +++ b/tests/compute/matrix-layout-structured-buffer.slang @@ -26,7 +26,7 @@ int test(int val) return tmp; } -//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out +//TEST_INPUT:ubuffer(data=[0 0 0 0 0 0 0 0 0 0 0 0], stride=4):out,name=buffer RWStructuredBuffer<int> buffer; [numthreads(12, 1, 1)] diff --git a/tests/compute/matrix-layout.hlsl b/tests/compute/matrix-layout.hlsl index 0993a1bb2..a7a167926 100644 --- a/tests/compute/matrix-layout.hlsl +++ b/tests/compute/matrix-layout.hlsl @@ -23,13 +23,13 @@ struct S int b; }; -//TEST_INPUT:cbuffer(data=[1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24]): +//TEST_INPUT:cbuffer(data=[1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24]):name=C0 cbuffer C0 { S s; }; -//TEST_INPUT:cbuffer(data=[1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24]): +//TEST_INPUT:cbuffer(data=[1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24]):name=C1 cbuffer C1 { |
