Remove the conv2d op-test case that can never be delegated, so the WebGPU op tests can run - #21697
Merged
shoumikhin merged 1 commit intoAug 10, 2026
Merged
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/21697
Note: Links to docs will display an error until the docs builds have been completed. ⏳ No Failures, 11 PendingAs of commit 033e484 with merge base 9cd0c12 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
shoumikhin
force-pushed
the
shoumikhin/webgpu-drop-undelegatable-conv2d-case
branch
from
August 10, 2026 05:51
1df8615 to
969df9d
Compare
…bGPU op tests can run
shoumikhin
force-pushed
the
shoumikhin/webgpu-drop-undelegatable-conv2d-case
branch
from
August 10, 2026 18:08
969df9d to
033e484
Compare
JakeStevens
approved these changes
Aug 10, 2026
shoumikhin
deleted the
shoumikhin/webgpu-drop-undelegatable-conv2d-case
branch
August 10, 2026 19:33
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is broken
The WebGPU op-test generator refuses to run:
Why it happens
The op-test generator exports every case in
backends/webgpu/test/op_tests/cases.pyand then checks that the exportedprogram really contains a WebGPU (Vulkan) delegate. If it does not, the case
would run on CPU and prove nothing, so the generator refuses to write it.
The
gemm_batchedcase gives conv2d an input of shape(2, 8, 16, 16), so abatch of 2.
check_conv_nodeinbackends/vulkan/op_registry.pyreturns Falsefor any 4-D convolution whose batch is not 1:
So this case can never be delegated. It has been in
cases.pysince the suitewas added and has never worked.
Why it only turns the job red now
This is an old failure that was being hidden, not a new one.
The generator has raised on this case since #21620 landed, which is the change
that added
generate_op_tests.pyto main. But the CI script wrapped the wholestage in an
if:So generation did run on every nightly, and it did fail on this exact case every
time. Run
31194597529,
from 2026-08-07, shows the whole sequence: the native tests pass, the generator
then runs for about 17 minutes, dies on
conv2d/gemm_batched produced NO VulkanBackend delegate, and theelsebranchprints the WARN and the job goes green.
The part that had genuinely never run is the second half of the stage, the C++
op-test binary, because there was no manifest for it to load.
#21646 removed the
if/elseand left a plain call. The script runs underset -e, so the same failure that had been warned about for weeks became fatal.Making it fatal is the right call. The op tests are meant to run. This change
removes the one case that stops them.
The fix
Delete the
gemm_batchedcase, and say in the suite comment why there is nobatched case, so it is clear what to add back once the partitioner accepts
batch > 1.
Why not mark the case
required=Falseinsteadrequired=Falsemakes the generator print a warning instead of raising, but itstill writes the
.pteand still adds the case to the manifest. The C++ driverwould then load a CPU-only program, compare it to the torch golden, and pass.
That is a green tick for a test that never touches the GPU, which is worse than
having no case at all.
Teaching the generator to also drop the manifest entry in that situation would
be a reasonable follow-up, but it is a separate change.
Test plan
test-webgpu-nativeis the only job that runs the op tests, and on its own thisbranch cannot reach them: the job still stops earlier on the missing RoPE fixture
that #21690 fixes. So the two changes were tested together, on a branch holding
both, and that run passes:
So the generator now gets all the way through, the op-test binary runs for the
first time, and all 391 generated tests pass,
conv2dincluded with itsremaining 6 cases.
Tested on this branch alone as well, to confirm this change does not break
anything earlier: the job reaches the native tests and 28 of them pass, with the
single failure being the RoPE fixture that #21690 fixes.
What this costs in runner time
Generating the 390 cases takes about 35 minutes. In the green run above the whole
job took 75.5 minutes, of which 17.7 was setup and 57.4 was the test script.
That fits inside the current 120 minute limit, but only because that run had a
fast setup. The same setup steps have been measured as high as 64 minutes on the
same runner label, which would put this job at about 121 minutes. #21690 raises
the limit to 150 for that reason.