1cb93a386Sopenharmony_ciuniform half4 testInputs;
2cb93a386Sopenharmony_ciuniform half4 colorGreen, colorRed;
3cb93a386Sopenharmony_ci
4cb93a386Sopenharmony_cihalf4 main(float2 coords) {
5cb93a386Sopenharmony_ci    const half4 constVal   = half4(-1.25, 0, 0.75, 2.25);
6cb93a386Sopenharmony_ci    const half4 constRed   = half4(1, 0, 0, 1);
7cb93a386Sopenharmony_ci    const half4 constGreen = half4(0, 1, 0, 1);
8cb93a386Sopenharmony_ci
9cb93a386Sopenharmony_ci    half4 expectedA = half4(0.0, 0.0, 0.84375, 1.0);
10cb93a386Sopenharmony_ci    half4 expectedB = half4(1.0, 0.0, 1.0, 1.0);
11cb93a386Sopenharmony_ci
12cb93a386Sopenharmony_ci    return (smoothstep(0,             1,               constVal.x)    == expectedA.x     &&
13cb93a386Sopenharmony_ci            smoothstep(0,             1,               constVal.xy)   == expectedA.xy    &&
14cb93a386Sopenharmony_ci            smoothstep(0,             1,               constVal.xyz)  == expectedA.xyz   &&
15cb93a386Sopenharmony_ci            smoothstep(0,             1,               constVal.xyzw) == expectedA.xyzw  &&
16cb93a386Sopenharmony_ci            smoothstep(0,             1,               constVal.x)    == expectedA.x     &&
17cb93a386Sopenharmony_ci            smoothstep(0,             1,               constVal.xy)   == expectedA.xy    &&
18cb93a386Sopenharmony_ci            smoothstep(0,             1,               constVal.xyz)  == expectedA.xyz   &&
19cb93a386Sopenharmony_ci            smoothstep(0,             1,               constVal.xyzw) == expectedA.xyzw  &&
20cb93a386Sopenharmony_ci            smoothstep(colorRed.g,    colorGreen.g,    constVal.x)    == expectedA.x     &&
21cb93a386Sopenharmony_ci            smoothstep(colorRed.g,    colorGreen.g,    constVal.xy)   == expectedA.xy    &&
22cb93a386Sopenharmony_ci            smoothstep(colorRed.g,    colorGreen.g,    constVal.xyz)  == expectedA.xyz   &&
23cb93a386Sopenharmony_ci            smoothstep(colorRed.g,    colorGreen.g,    constVal.xyzw) == expectedA.xyzw  &&
24cb93a386Sopenharmony_ci            smoothstep(constRed.x,    constGreen.x,    constVal.x)    == expectedB.x     &&
25cb93a386Sopenharmony_ci            smoothstep(constRed.xy,   constGreen.xy,   constVal.xy)   == expectedB.xy    &&
26cb93a386Sopenharmony_ci            smoothstep(constRed.xyz,  constGreen.xyz,  constVal.xyz)  == expectedB.xyz   &&
27cb93a386Sopenharmony_ci            smoothstep(constRed.xyzw, constGreen.xyzw, constVal.xyzw) == expectedB.xyzw  &&
28cb93a386Sopenharmony_ci            smoothstep(colorRed.x,    colorGreen.x,    constVal.x)    == expectedB.x     &&
29cb93a386Sopenharmony_ci            smoothstep(colorRed.xy,   colorGreen.xy,   constVal.xy)   == expectedB.xy    &&
30cb93a386Sopenharmony_ci            smoothstep(colorRed.xyz,  colorGreen.xyz,  constVal.xyz)  == expectedB.xyz   &&
31cb93a386Sopenharmony_ci            smoothstep(colorRed.xyzw, colorGreen.xyzw, constVal.xyzw) == expectedB.xyzw)
32cb93a386Sopenharmony_ci                ? colorGreen : colorRed;
33cb93a386Sopenharmony_ci}
34