[ExecuTorch][WebGPU] Adopt WebGPU layout:"auto" in make_compute_pipeline#20867
Open
JCNTH wants to merge 3 commits into
Open
[ExecuTorch][WebGPU] Adopt WebGPU layout:"auto" in make_compute_pipeline#20867JCNTH wants to merge 3 commits into
JCNTH wants to merge 3 commits into
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/20867
Note: Links to docs will display an error until the docs builds have been completed. ❌ 131 New Failures, 2 Unrelated Failures, 7 Unclassified FailuresAs of commit 2910518 with merge base c2b273e ( NEW FAILURES - The following jobs have failed:
UNCLASSIFIED FAILURES - DrCI could not classify the following jobs because the workflow did not run on the merge base. The failures may be pre-existing on trunk or introduced by this PR:
FLAKY - The following jobs failed but were likely due to flakiness present on trunk:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
This was referenced Jul 10, 2026
[ExecuTorch][WebGPU] Add relu op (shared unary handler; sigmoid adopts make_compute_pipeline)
#20863
Open
This was referenced Jul 10, 2026
This was referenced Jul 16, 2026
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.
Stack from ghstack (oldest at bottom):
Replace the hand-built bind-group layout + pipeline layout in the shared
utils::make_compute_pipelinehelper with WebGPU-nativelayout:"auto"(pipeline_desc.layout = nullptr) +wgpuComputePipelineGetBindGroupLayout(pipeline, 0). This removes the per-opWGPUBindGroupLayoutEntry[]+ pipeline-layout boilerplate across every helper-using op — the driver derives the bind-group layout from the shader's statically-used bindings. This mirrors the Vulkan delegate's codegen descriptor-derivation, achieved via the WebGPU runtime feature instead of build-time codegen.BindingSpec.typeis retained but unused, so no call sites change.Precondition: auto layout omits any binding the shader never statically references. Audited across every helper-using shader — every declared binding is statically referenced (optional bias/mask/affine bindings under a runtime-uniform guard, which counts as static use). The lone exception was
max_pool2d, whoseout_idx(binding 3) was gated by a compile-timeoverride(write_indices) — which auto layout could drop. Converted it to a runtimeparams.write_indicesuniform (reusing a padding slot;PoolParamsstays 64 bytes) soout_idxis unconditionally statically referenced regardless of Tint's override handling, matching the runtime-uniform pattern the other optional-binding ops use.@exported-using-ghexport
Differential Revision: D110836671
Differential Revision: D110836671