[codex] Add WebGPU renderer benchmark - #163
Draft
meekmachine wants to merge 1 commit into
Draft
Conversation
This was referenced Jun 4, 2026
Owner
Author
PR backlog triage — DRAFT_KEEP (RuntimeCore benchmark) |
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.
Summary
Adds a browser-runnable WebGPU renderer benchmark for Loom3 and removes two Three.js constructor-identity assumptions that block WebGPU-build consumers.
The benchmark is a procedural scene, so it does not depend on external GLB assets. It exercises:
AnimationMixermorph clip playbackResults are printed to the browser console with
console.table()and stored onwindow.__loom3BenchmarkResult. The benchmark can be rerun withwindow.runLoom3Benchmark().How to run
Open the printed local URL and inspect the browser console.
Compatibility work included
obj instanceof Meshin hair registration with structuralobj.isMesh === true.Meshconstructor.instanceof THREE.Bonechecks with structuralisBone/type === 'Bone'checks.Validation
npm testpassed: 28 files, 179 tests.npm run buildpassed.npm run typecheckpassed.http://localhost:4173/examples/webgpu-benchmark/.Smoke result excerpt:
{ "renderer": "WebGPURenderer", "threeRevision": "170", "rendererFlags": { "isWebGPURenderer": true, "isWebGLRenderer": false, "backend": "WebGPUBackend" }, "setup": { "hairRegistrationCount": 1, "morphMeshCount": 2 }, "submitMs": { "avg": 0.368, "p95": 0.5, "p99": 0.5 }, "approximateFpsFromRaf": 72.478 }Notes
This intentionally does not switch Loom3's main package import to
three/webgpu. The fixture uses an import map sothree,three/webgpu, and Loom3's package import resolve to the same WebGPU Three.js build in the browser.