[ExecuTorch][WebGPU] Request shader-f16 device feature (enablement, fail-open)#20729
[ExecuTorch][WebGPU] Request shader-f16 device feature (enablement, fail-open)#20729JCNTH wants to merge 4 commits into
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/20729
Note: Links to docs will display an error until the docs builds have been completed. ❌ 1 New Failure, 21 PendingAs of commit f6ff099 with merge base 4af91c3 ( NEW FAILURE - The following job has failed:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
|
@claude throoughly review, check for overengineering, correctness, and areaas for modularization |
|
Claude finished @JCNTH's task in 51s —— View job Code Review: shader-f16 device feature enablement
Overall this is a clean, well-scoped enablement change. The lifetime handling is correct, the fail-open semantics match the existing Correctness ✅
One semantic nuance worth flagging
|
Stack from ghstack (oldest at bottom):
Enablement for a future fp16 compute path: detect and request
WGPUFeatureName_ShaderF16at device creation when the adapter advertises it (fail-open — absence leaves the fp32 path unchanged), and exposeWebGPUContext::shader_f16_supportedfor fp16 kernels to branch on. No fp16 hot-kernel consumer yet.Key changes:
WebGPUDevice.h— addbool shader_f16_supportedtoWebGPUContext(outside the profiling#ifdef).WebGPUDevice.cpp— hoistrequired_featuresout of the profiling#ifdef; pushWGPUFeatureName_ShaderF16when the adapter has it; assignrequiredFeatures/requiredFeatureCountonly when non-empty; move#include <vector>to the unconditional include block.@exported-using-ghexport
Differential Revision: D110660013
Differential Revision: D110660013