Skip to content

[ExecuTorch][WebGPU] Use requiredFeatures instance API on native + emscripten Dawn#20650

Open
JulianCloudNTH wants to merge 1 commit into
gh/JulianCloudNTH/82/basefrom
gh/JulianCloudNTH/82/head
Open

[ExecuTorch][WebGPU] Use requiredFeatures instance API on native + emscripten Dawn#20650
JulianCloudNTH wants to merge 1 commit into
gh/JulianCloudNTH/82/basefrom
gh/JulianCloudNTH/82/head

Conversation

@JulianCloudNTH

Copy link
Copy Markdown
Contributor

Stack from ghstack (oldest at bottom):

  • (to be filled)

Key the timedWaitAny instance setup to the actual Dawn API instead of __EMSCRIPTEN__, so native-rig Dawn and emscripten/emdawnwebgpu use the modern requiredFeatures path and only the vendored Dawn uses the legacy capabilities.* path.

The instance-descriptor setup was guarded by #if defined(__EMSCRIPTEN__), which routed emscripten (emdawnwebgpu, emcc 4.0.19+) through the legacy capabilities.* API that no longer exists there. The guard now keys off the API actually present.

Key changes:

  • WebGPUDevice.cpp#if defined(__EMSCRIPTEN__)#if defined(WEBGPU_DAWN_INSTANCE_CAPABILITIES). The legacy instance_desc.capabilities.* path is taken only by the buck-vendored Dawn (which defines the macro); native cmake Dawn and emscripten leave it undefined and take the requiredFeatures / WGPUInstanceFeatureName_TimedWaitAny path.

Co-authored-with: Claude Code.

Differential Revision: D110149678

[ghstack-poisoned]
@pytorch-bot

pytorch-bot Bot commented Jun 30, 2026

Copy link
Copy Markdown

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/20650

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit 1cd76e3 with merge base 73c259e (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@github-actions

Copy link
Copy Markdown

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants