mesa-panvk-bifrost: r4 -> r5 — advertise fragmentStoresAndAtomics on Bifrost (closes panvk-bifrost#2) #92

Merged
marfrit merged 1 commits from claude-noether/marfrit-packages:noether/mesa-panvk-bifrost-r5 into main 2026-05-23 12:19:11 +00:00
Contributor

Summary

mesa-panvk-bifrost r4 → r5: backports Mesa main's unconditional .fragmentStoresAndAtomics = true flip for panvk. Closes the Dawn WebGPU adapter rejection at PhysicalDeviceVk.cpp:250 that was causing brave-vulkan to fall back to SwiftShader CPU adapter on Mali-G52. Tracks marfrit/panvk-bifrost#2.

The disjunction with instance->force_enable_shader_atomics is kept as a documented kill-switch (compiler folds true || X to true but the link to the DRI option pan_force_enable_shader_atomics stays visible for rebases / downstream debugging).

Phase 7 verify (on ohm, PineTab2 / RK3566 / Mali-G52 r1 MC1)

Locally-built r5 lib installed to a test path (/tmp/r5_test_lib/) and exercised vs the existing r4 production lib:

Subset r4 r5 Delta
dEQP-VK.glsl.atomic_operations.* 48 P / 0 F / 992 NS 80 P / 0 F / 960 NS +32 newly-passing, 0 new failures
dEQP-VK.image.store.* 2772 P / 0 F / 238 NS 2772 P / 0 F / 238 NS identical

vulkaninfo on the r5 test lib confirms fragmentStoresAndAtomics = true (was false on r4). vertexPipelineStoresAndAtomics remains false per upstream gating.

Process

Followed 8-step bugfix-process per feedback-bugfix-process memory:

  1. Re-analyzed: the cited Dawn warning IS load-bearing for WebGPU HW-accel.
  2. Prior art researched: Mesa main flipped this same line unconditional, our 26.0.6 base lags.
  3. Drafted patch (kept disjunction per reviewer guidance).
  4. 2nd-model review completed — recommended keeping || force_enable_shader_atomics, suggested CTS subset, advised against narrower Bifrost-only gate.
  5. Implemented (this PR).
  6. Deploy + test: built locally on ohm, installed to test path.
  7. Confirm: dEQP subsets show zero regressions, 32 newly-passing.
  8. Documentation: this PR body + memory update + closes-issue link.

Test plan

  • CI builds + signs + publishes mesa-panvk-bifrost-26.0.6.r5-1-aarch64.pkg.tar.xz
  • pacman -Sy && pacman -Si mesa-panvk-bifrost on ohm shows r5 version (three-point ship check per feedback-package-done-means-installable)
  • vulkaninfo on installed r5 reports fragmentStoresAndAtomics = true
  • Original symptom from issue #2 (the "fragmentStoresAndAtomics feature required" Dawn warning) no longer appears in brave-vulkan stderr

🤖 Generated with Claude Code

## Summary `mesa-panvk-bifrost` r4 → r5: backports Mesa main's unconditional `.fragmentStoresAndAtomics = true` flip for panvk. Closes the Dawn WebGPU adapter rejection at `PhysicalDeviceVk.cpp:250` that was causing brave-vulkan to fall back to SwiftShader CPU adapter on Mali-G52. Tracks [marfrit/panvk-bifrost#2](https://git.reauktion.de/marfrit/panvk-bifrost/issues/2). The disjunction with `instance->force_enable_shader_atomics` is kept as a documented kill-switch (compiler folds `true || X` to `true` but the link to the DRI option `pan_force_enable_shader_atomics` stays visible for rebases / downstream debugging). ## Phase 7 verify (on ohm, PineTab2 / RK3566 / Mali-G52 r1 MC1) Locally-built r5 lib installed to a test path (`/tmp/r5_test_lib/`) and exercised vs the existing r4 production lib: | Subset | r4 | r5 | Delta | |---|---|---|---| | `dEQP-VK.glsl.atomic_operations.*` | 48 P / 0 F / 992 NS | 80 P / 0 F / 960 NS | **+32 newly-passing, 0 new failures** | | `dEQP-VK.image.store.*` | 2772 P / 0 F / 238 NS | 2772 P / 0 F / 238 NS | identical | `vulkaninfo` on the r5 test lib confirms `fragmentStoresAndAtomics = true` (was `false` on r4). `vertexPipelineStoresAndAtomics` remains `false` per upstream gating. ## Process Followed 8-step bugfix-process per `feedback-bugfix-process` memory: 1. Re-analyzed: the cited Dawn warning IS load-bearing for WebGPU HW-accel. 2. Prior art researched: Mesa main flipped this same line unconditional, our 26.0.6 base lags. 3. Drafted patch (kept disjunction per reviewer guidance). 4. **2nd-model review** completed — recommended keeping `|| force_enable_shader_atomics`, suggested CTS subset, advised against narrower Bifrost-only gate. 5. Implemented (this PR). 6. Deploy + test: built locally on ohm, installed to test path. 7. Confirm: dEQP subsets show zero regressions, 32 newly-passing. 8. Documentation: this PR body + memory update + closes-issue link. ## Test plan - [ ] CI builds + signs + publishes `mesa-panvk-bifrost-26.0.6.r5-1-aarch64.pkg.tar.xz` - [ ] `pacman -Sy && pacman -Si mesa-panvk-bifrost` on ohm shows r5 version (three-point ship check per `feedback-package-done-means-installable`) - [ ] `vulkaninfo` on installed r5 reports `fragmentStoresAndAtomics = true` - [ ] Original symptom from issue #2 (the "fragmentStoresAndAtomics feature required" Dawn warning) no longer appears in brave-vulkan stderr 🤖 Generated with [Claude Code](https://claude.com/claude-code)
claude-noether added 1 commit 2026-05-23 12:05:11 +00:00
Backports Mesa main's unconditional flip of .fragmentStoresAndAtomics
to true in src/panfrost/vulkan/panvk_vX_physical_device.c. Closes
the Dawn-WebGPU adapter rejection at PhysicalDeviceVk.cpp:250 that
caused brave-vulkan to fall back to the SwiftShader CPU adapter on
PineTab2/Mali-G52, per marfrit/panvk-bifrost#2.

Phase 7 verify on ohm (PineTab2, RK3566, Mali-G52 r1 MC1) with a
locally-built r5 lib installed to /tmp/r5_test_lib/:

  dEQP-VK.glsl.atomic_operations.*:
    r4:  48 pass /   0 fail / 992 NotSupported  (1040 total)
    r5:  80 pass /   0 fail / 960 NotSupported  (1040 total)
    delta: +32 newly-passing, zero new failures

  dEQP-VK.image.store.*:
    r4: 2772 pass /  0 fail / 238 NotSupported  (3010 total)
    r5: 2772 pass /  0 fail / 238 NotSupported  (3010 total)
    delta: identical (image.store is independent of the flag)

The disjunction with instance->force_enable_shader_atomics is kept as
a documented kill-switch even though the compiler folds it away —
it leaves the DRI option pan_force_enable_shader_atomics semantically
wired for future rebases or downstream debugging.

Patch reviewed via 2nd-model pass (per bugfix-process step 4):
recommended keeping the disjunction (applied), Bifrost-only-vs-unconditional
left unconditional to match upstream (applied), pre-ship CTS subset
(applied with results above).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
marfrit merged commit 685f85c22e into main 2026-05-23 12:19:11 +00:00
marfrit deleted branch noether/mesa-panvk-bifrost-r5 2026-05-23 12:19:11 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: marfrit/marfrit-packages#92