Output WGSL instead of SPIR-V in transform fuzzers
Generating SPIR-V can cause validation failures when out-of-bounds
accesses are performed, since we are not running the robustness
transform.
Bug: chromium:1246061
Change-Id: Ied58d77d90079d10d5579d2d55854c3cfbc18db5
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/63640
Kokoro: Kokoro <noreply+kokoro@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
Commit-Queue: James Price <jrprice@google.com>
diff --git a/fuzzers/tint_binding_remapper_fuzzer.cc b/fuzzers/tint_binding_remapper_fuzzer.cc
index 5a8f0cd..a4d489a 100644
--- a/fuzzers/tint_binding_remapper_fuzzer.cc
+++ b/fuzzers/tint_binding_remapper_fuzzer.cc
@@ -30,7 +30,7 @@
transform_manager.Add<tint::transform::BindingRemapper>();
- fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kSpv);
+ fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kWGSL);
fuzzer.SetTransformManager(&transform_manager, std::move(transform_inputs));
fuzzer.SetDumpInput(GetCliParams().dump_input);
diff --git a/fuzzers/tint_first_index_offset_fuzzer.cc b/fuzzers/tint_first_index_offset_fuzzer.cc
index bb7f910..7cf5890 100644
--- a/fuzzers/tint_first_index_offset_fuzzer.cc
+++ b/fuzzers/tint_first_index_offset_fuzzer.cc
@@ -30,7 +30,7 @@
transform_manager.Add<tint::transform::FirstIndexOffset>();
- tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kSpv);
+ tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kWGSL);
fuzzer.SetTransformManager(&transform_manager, std::move(transform_inputs));
fuzzer.SetDumpInput(GetCliParams().dump_input);
diff --git a/fuzzers/tint_inspector_fuzzer.cc b/fuzzers/tint_inspector_fuzzer.cc
index 5812faf..9175ea2 100644
--- a/fuzzers/tint_inspector_fuzzer.cc
+++ b/fuzzers/tint_inspector_fuzzer.cc
@@ -23,7 +23,7 @@
transform::DataMap transform_inputs;
transform_manager.Add<transform::Robustness>();
- tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kSpv);
+ tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kWGSL);
fuzzer.EnableInspector();
fuzzer.SetDumpInput(GetCliParams().dump_input);
fuzzer.SetTransformManager(&transform_manager, std::move(transform_inputs));
diff --git a/fuzzers/tint_renamer_fuzzer.cc b/fuzzers/tint_renamer_fuzzer.cc
index 771487b..7528915 100644
--- a/fuzzers/tint_renamer_fuzzer.cc
+++ b/fuzzers/tint_renamer_fuzzer.cc
@@ -22,7 +22,7 @@
transform::Manager transform_manager;
transform_manager.Add<transform::Renamer>();
- fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kSpv);
+ fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kWGSL);
fuzzer.SetTransformManager(&transform_manager, {});
fuzzer.SetDumpInput(GetCliParams().dump_input);
diff --git a/fuzzers/tint_robustness_fuzzer.cc b/fuzzers/tint_robustness_fuzzer.cc
index 66cf0d5..3ae6121 100644
--- a/fuzzers/tint_robustness_fuzzer.cc
+++ b/fuzzers/tint_robustness_fuzzer.cc
@@ -22,7 +22,7 @@
tint::transform::Manager transform_manager;
transform_manager.Add<tint::transform::Robustness>();
- tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kSpv);
+ tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kWGSL);
fuzzer.SetTransformManager(&transform_manager, {});
fuzzer.SetDumpInput(GetCliParams().dump_input);
diff --git a/fuzzers/tint_single_entry_point_fuzzer.cc b/fuzzers/tint_single_entry_point_fuzzer.cc
index 13b9d33..cc5dbce 100644
--- a/fuzzers/tint_single_entry_point_fuzzer.cc
+++ b/fuzzers/tint_single_entry_point_fuzzer.cc
@@ -30,7 +30,7 @@
transform_manager.Add<tint::transform::SingleEntryPoint>();
- tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kSpv);
+ tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kWGSL);
fuzzer.SetTransformManager(&transform_manager, std::move(transform_inputs));
fuzzer.SetDumpInput(GetCliParams().dump_input);
diff --git a/fuzzers/tint_vertex_pulling_fuzzer.cc b/fuzzers/tint_vertex_pulling_fuzzer.cc
index d6c3915..a92f9b2 100644
--- a/fuzzers/tint_vertex_pulling_fuzzer.cc
+++ b/fuzzers/tint_vertex_pulling_fuzzer.cc
@@ -30,7 +30,7 @@
transform_manager.Add<tint::transform::VertexPulling>();
- tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kSpv);
+ tint::fuzzers::CommonFuzzer fuzzer(InputFormat::kWGSL, OutputFormat::kWGSL);
fuzzer.SetTransformManager(&transform_manager, std::move(transform_inputs));
fuzzer.SetDumpInput(GetCliParams().dump_input);