blob: 47dc0272a9d2fe6ea2cfa484cee30df4bc449e21 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
//TEST(compute):COMPARE_COMPUTE:-xslang -use-ir
//TEST_INPUT:ubuffer(data=[0 0 0 0], stride=4):dxbinding(0),glbinding(0),out
RWStructuredBuffer<float> outputBuffer;
__generic<T:__BuiltinFloatingPointType>
T test(T v0, T v1)
{
return T(3.0);
}
[numthreads(4, 1, 1)]
void computeMain(uint3 dispatchThreadID : SV_DispatchThreadID)
{
float outVal = test<float>(1.0, 2.0);
outputBuffer[dispatchThreadID.x] = outVal;
}
|