fix: enforce WebGPU gate, handle WASM OOM and assertion failures#5
Merged
Jesssullivan merged 1 commit intomasterfrom Feb 12, 2026
Merged
fix: enforce WebGPU gate, handle WASM OOM and assertion failures#5Jesssullivan merged 1 commit intomasterfrom
Jesssullivan merged 1 commit intomasterfrom
Conversation
Non-WebGPU browsers are now blocked by a non-dismissable onboarding modal with browser-specific instructions. WASM OOM errors null the unrecoverable Emscripten context and fall through to JS fallback. Futhark WebGPU assertion failures produce clearer error messages. - consentStorage: add webgpuAvailable field, shouldBlockDemos() - OnboardingModal: gated state disables close/escape/backdrop/finish - demo/+layout: second gate layer with inline block + spinner - ComputeDispatcher: OOM catch nulls futharkContext - futhark-webgpu: detect assertion/abort in context creation - 14 new tests (gate enforcement, OOM handling, assertion fallback)
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
Aborted(OOM)) errors null the unrecoverable Emscripten context and fall through to JS fallback$futhark_context_newassertion failures produce clearer error messages about GPU driver incompatibilityChanges
consentStorage.ts—webgpuAvailablefield,shouldBlockDemos(),updateWebGPUAvailability()OnboardingModal.svelte—gatedderived state disables close/escape/backdrop/finishdemo/+layout.svelte— inline WebGPU gate with spinner/block/pass states+layout.svelte—$effectre-shows gate modal on/demo/*navigationComputeDispatcher.ts— OOM catch nullsfutharkContextin bothcomputeEsdtFuthark()andrunFullPipeline()futhark-webgpu/index.ts— detect assertion/abort errors innewFutharkWebGPUContext()Test plan
pnpm testpasses (766 pass, 26 skipped)--disable-gpu): modal blocks, demo routes show gate overlay