tint: Replace smoothStep with smoothstep in tests
There were some tests that were still using the deprecated name, as was the SPIR-V reader. Bug: tint:1483 Change-Id: Ie919596712e05340110fbd872470a1b4c9a625c7 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/86745 Auto-Submit: James Price <jrprice@google.com> Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: Ben Clayton <bclayton@google.com> Commit-Queue: James Price <jrprice@google.com>
This commit is contained in:
parent
c2849f3fb9
commit
0384932f1a
|
@ -92,7 +92,7 @@ decorated with `NonWritable` or each member of the struct can be decorated with
|
||||||
| sign | GLSLstd450FSign | sign | sign |
|
| sign | GLSLstd450FSign | sign | sign |
|
||||||
| sin | GLSLstd450Sin | sin | sin |
|
| sin | GLSLstd450Sin | sin | sin |
|
||||||
| sinh | GLSLstd450Sinh | sinh | sinh |
|
| sinh | GLSLstd450Sinh | sinh | sinh |
|
||||||
| smoothStep | GLSLstd450SmoothStep | smoothstep | smoothstep |
|
| smoothstep | GLSLstd450SmoothStep | smoothstep | smoothstep |
|
||||||
| sqrt | GLSLstd450Sqrt | sqrt | sqrt |
|
| sqrt | GLSLstd450Sqrt | sqrt | sqrt |
|
||||||
| step | GLSLstd450Step | step | step |
|
| step | GLSLstd450Step | step | step |
|
||||||
| tan | GLSLstd450Tan | tan | tan |
|
| tan | GLSLstd450Tan | tan | tan |
|
||||||
|
|
|
@ -378,7 +378,7 @@ std::string GetGlslStd450FuncName(uint32_t ext_opcode) {
|
||||||
case GLSLstd450Sinh:
|
case GLSLstd450Sinh:
|
||||||
return "sinh";
|
return "sinh";
|
||||||
case GLSLstd450SmoothStep:
|
case GLSLstd450SmoothStep:
|
||||||
return "smoothStep";
|
return "smoothstep";
|
||||||
case GLSLstd450Sqrt:
|
case GLSLstd450Sqrt:
|
||||||
return "sqrt";
|
return "sqrt";
|
||||||
case GLSLstd450Step:
|
case GLSLstd450Step:
|
||||||
|
|
|
@ -475,7 +475,7 @@ INSTANTIATE_TEST_SUITE_P(
|
||||||
{"FClamp", "clamp"}, // WGSL FClamp promises more for NaN
|
{"FClamp", "clamp"}, // WGSL FClamp promises more for NaN
|
||||||
{"Fma", "fma"},
|
{"Fma", "fma"},
|
||||||
{"FMix", "mix"},
|
{"FMix", "mix"},
|
||||||
{"SmoothStep", "smoothStep"}}));
|
{"SmoothStep", "smoothstep"}}));
|
||||||
|
|
||||||
TEST_P(SpvParserTest_GlslStd450_Inting_Inting, Scalar) {
|
TEST_P(SpvParserTest_GlslStd450_Inting_Inting, Scalar) {
|
||||||
const auto assembly = Preamble() + R"(
|
const auto assembly = Preamble() + R"(
|
||||||
|
|
|
@ -1069,7 +1069,7 @@ INSTANTIATE_TEST_SUITE_P(ResolverBuiltinsValidationTest,
|
||||||
std::make_tuple("sign", 1),
|
std::make_tuple("sign", 1),
|
||||||
std::make_tuple("sin", 1),
|
std::make_tuple("sin", 1),
|
||||||
std::make_tuple("sinh", 1),
|
std::make_tuple("sinh", 1),
|
||||||
std::make_tuple("smoothStep", 3),
|
std::make_tuple("smoothstep", 3),
|
||||||
std::make_tuple("sqrt", 1),
|
std::make_tuple("sqrt", 1),
|
||||||
std::make_tuple("step", 2),
|
std::make_tuple("step", 2),
|
||||||
std::make_tuple("tan", 1),
|
std::make_tuple("tan", 1),
|
||||||
|
|
|
@ -212,7 +212,7 @@ INSTANTIATE_TEST_SUITE_P(GlslGeneratorImplTest_Import,
|
||||||
GlslImportData_TripleParam_ScalarTest,
|
GlslImportData_TripleParam_ScalarTest,
|
||||||
testing::Values(GlslImportData{"mix", "mix"},
|
testing::Values(GlslImportData{"mix", "mix"},
|
||||||
GlslImportData{"clamp", "clamp"},
|
GlslImportData{"clamp", "clamp"},
|
||||||
GlslImportData{"smoothStep",
|
GlslImportData{"smoothstep",
|
||||||
"smoothstep"}));
|
"smoothstep"}));
|
||||||
|
|
||||||
using GlslImportData_TripleParam_VectorTest = TestParamHelper<GlslImportData>;
|
using GlslImportData_TripleParam_VectorTest = TestParamHelper<GlslImportData>;
|
||||||
|
@ -237,7 +237,7 @@ INSTANTIATE_TEST_SUITE_P(
|
||||||
GlslImportData_TripleParam_VectorTest,
|
GlslImportData_TripleParam_VectorTest,
|
||||||
testing::Values(GlslImportData{"faceForward", "faceforward"},
|
testing::Values(GlslImportData{"faceForward", "faceforward"},
|
||||||
GlslImportData{"clamp", "clamp"},
|
GlslImportData{"clamp", "clamp"},
|
||||||
GlslImportData{"smoothStep", "smoothstep"}));
|
GlslImportData{"smoothstep", "smoothstep"}));
|
||||||
|
|
||||||
TEST_F(GlslGeneratorImplTest_Import, DISABLED_GlslImportData_FMix) {
|
TEST_F(GlslGeneratorImplTest_Import, DISABLED_GlslImportData_FMix) {
|
||||||
FAIL();
|
FAIL();
|
||||||
|
|
|
@ -213,7 +213,7 @@ INSTANTIATE_TEST_SUITE_P(HlslGeneratorImplTest_Import,
|
||||||
testing::Values(HlslImportData{"fma", "mad"},
|
testing::Values(HlslImportData{"fma", "mad"},
|
||||||
HlslImportData{"mix", "lerp"},
|
HlslImportData{"mix", "lerp"},
|
||||||
HlslImportData{"clamp", "clamp"},
|
HlslImportData{"clamp", "clamp"},
|
||||||
HlslImportData{"smoothStep",
|
HlslImportData{"smoothstep",
|
||||||
"smoothstep"}));
|
"smoothstep"}));
|
||||||
|
|
||||||
using HlslImportData_TripleParam_VectorTest = TestParamHelper<HlslImportData>;
|
using HlslImportData_TripleParam_VectorTest = TestParamHelper<HlslImportData>;
|
||||||
|
@ -239,7 +239,7 @@ INSTANTIATE_TEST_SUITE_P(
|
||||||
testing::Values(HlslImportData{"faceForward", "faceforward"},
|
testing::Values(HlslImportData{"faceForward", "faceforward"},
|
||||||
HlslImportData{"fma", "mad"},
|
HlslImportData{"fma", "mad"},
|
||||||
HlslImportData{"clamp", "clamp"},
|
HlslImportData{"clamp", "clamp"},
|
||||||
HlslImportData{"smoothStep", "smoothstep"}));
|
HlslImportData{"smoothstep", "smoothstep"}));
|
||||||
|
|
||||||
TEST_F(HlslGeneratorImplTest_Import, DISABLED_HlslImportData_FMix) {
|
TEST_F(HlslGeneratorImplTest_Import, DISABLED_HlslImportData_FMix) {
|
||||||
FAIL();
|
FAIL();
|
||||||
|
|
|
@ -190,7 +190,7 @@ INSTANTIATE_TEST_SUITE_P(MslGeneratorImplTest,
|
||||||
testing::Values(MslImportData{"fma", "fma"},
|
testing::Values(MslImportData{"fma", "fma"},
|
||||||
MslImportData{"mix", "mix"},
|
MslImportData{"mix", "mix"},
|
||||||
MslImportData{"clamp", "clamp"},
|
MslImportData{"clamp", "clamp"},
|
||||||
MslImportData{"smoothStep",
|
MslImportData{"smoothstep",
|
||||||
"smoothstep"}));
|
"smoothstep"}));
|
||||||
|
|
||||||
using MslImportData_TripleParam_VectorTest = TestParamHelper<MslImportData>;
|
using MslImportData_TripleParam_VectorTest = TestParamHelper<MslImportData>;
|
||||||
|
@ -216,7 +216,7 @@ INSTANTIATE_TEST_SUITE_P(
|
||||||
testing::Values(MslImportData{"faceForward", "faceforward"},
|
testing::Values(MslImportData{"faceForward", "faceforward"},
|
||||||
MslImportData{"fma", "fma"},
|
MslImportData{"fma", "fma"},
|
||||||
MslImportData{"clamp", "clamp"},
|
MslImportData{"clamp", "clamp"},
|
||||||
MslImportData{"smoothStep", "smoothstep"}));
|
MslImportData{"smoothstep", "smoothstep"}));
|
||||||
|
|
||||||
using MslImportData_TripleParam_Int_Test = TestParamHelper<MslImportData>;
|
using MslImportData_TripleParam_Int_Test = TestParamHelper<MslImportData>;
|
||||||
TEST_P(MslImportData_TripleParam_Int_Test, IntScalar) {
|
TEST_P(MslImportData_TripleParam_Int_Test, IntScalar) {
|
||||||
|
|
|
@ -941,7 +941,7 @@ INSTANTIATE_TEST_SUITE_P(BuiltinBuilderTest,
|
||||||
BuiltinData{"fma", "Fma"},
|
BuiltinData{"fma", "Fma"},
|
||||||
BuiltinData{"mix", "FMix"},
|
BuiltinData{"mix", "FMix"},
|
||||||
|
|
||||||
BuiltinData{"smoothStep",
|
BuiltinData{"smoothstep",
|
||||||
"SmoothStep"}));
|
"SmoothStep"}));
|
||||||
|
|
||||||
TEST_F(BuiltinBuilderTest, Call_FaceForward_Vector) {
|
TEST_F(BuiltinBuilderTest, Call_FaceForward_Vector) {
|
||||||
|
|
|
@ -91,7 +91,7 @@ fn simulate(@builtin(global_invocation_id) GlobalInvocationID : vec3<u32>) {
|
||||||
|
|
||||||
// Age each particle. Fade out before vanishing.
|
// Age each particle. Fade out before vanishing.
|
||||||
particle.lifetime = particle.lifetime - sim_params.deltaTime;
|
particle.lifetime = particle.lifetime - sim_params.deltaTime;
|
||||||
particle.color.a = smoothStep(0.0, 0.5, particle.lifetime);
|
particle.color.a = smoothstep(0.0, 0.5, particle.lifetime);
|
||||||
|
|
||||||
// If the lifetime has gone negative, then the particle is dead and should be
|
// If the lifetime has gone negative, then the particle is dead and should be
|
||||||
// respawned.
|
// respawned.
|
||||||
|
|
|
@ -37,7 +37,7 @@ fn main_1() {
|
||||||
let x_52 : vec4<f32> = v1;
|
let x_52 : vec4<f32> = v1;
|
||||||
let x_53 : vec4<f32> = v2;
|
let x_53 : vec4<f32> = v2;
|
||||||
let x_54 : vec4<f32> = v3;
|
let x_54 : vec4<f32> = v3;
|
||||||
v4 = smoothStep(x_52, x_53, x_54);
|
v4 = smoothstep(x_52, x_53, x_54);
|
||||||
let x_56 : vec4<f32> = v4;
|
let x_56 : vec4<f32> = v4;
|
||||||
x_GLF_color = vec4<f32>(x_56.x, x_56.y, x_56.w, x_56.x);
|
x_GLF_color = vec4<f32>(x_56.x, x_56.y, x_56.w, x_56.x);
|
||||||
let x_59 : f32 = v4.x;
|
let x_59 : f32 = v4.x;
|
||||||
|
|
|
@ -24,7 +24,7 @@ fn main_1() {
|
||||||
let x_32 : vec2<f32> = v1;
|
let x_32 : vec2<f32> = v1;
|
||||||
b = fract(x_32);
|
b = fract(x_32);
|
||||||
let x_34 : vec2<f32> = b;
|
let x_34 : vec2<f32> = b;
|
||||||
a = smoothStep(vec2<f32>(1.0, 1.0), vec2<f32>(1.0, 1.0), x_34).x;
|
a = smoothstep(vec2<f32>(1.0, 1.0), vec2<f32>(1.0, 1.0), x_34).x;
|
||||||
let x_38 : f32 = x_6.x_GLF_uniform_float_values[0].el;
|
let x_38 : f32 = x_6.x_GLF_uniform_float_values[0].el;
|
||||||
let x_39 : f32 = a;
|
let x_39 : f32 = a;
|
||||||
let x_40 : f32 = a;
|
let x_40 : f32 = a;
|
||||||
|
|
|
@ -67,7 +67,7 @@ fn main_1() {
|
||||||
let x_89 : f32 = x_6.x_GLF_uniform_float_values[1].el;
|
let x_89 : f32 = x_6.x_GLF_uniform_float_values[1].el;
|
||||||
let x_91 : vec4<f32> = v0;
|
let x_91 : vec4<f32> = v0;
|
||||||
let x_93 : i32 = a;
|
let x_93 : i32 = a;
|
||||||
v1[x_83] = smoothStep(vec4<f32>(x_85, x_87, x_89, 3.0), vec4<f32>(1.0, 1.0, 1.0, 1.0), x_91)[x_93];
|
v1[x_83] = smoothstep(vec4<f32>(x_85, x_87, x_89, 3.0), vec4<f32>(1.0, 1.0, 1.0, 1.0), x_91)[x_93];
|
||||||
}
|
}
|
||||||
|
|
||||||
continuing {
|
continuing {
|
||||||
|
|
|
@ -16,7 +16,7 @@ fn main_1() {
|
||||||
}
|
}
|
||||||
g = 3.0;
|
g = 3.0;
|
||||||
let x_33 : f32 = g;
|
let x_33 : f32 = g;
|
||||||
x_GLF_color = vec4<f32>(smoothStep(0.0, 1.0, x_33), 0.0, 0.0, 1.0);
|
x_GLF_color = vec4<f32>(smoothstep(0.0, 1.0, x_33), 0.0, 0.0, 1.0);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue