test(vulkan): honor storage buffer offset alignment - #183
Merged
Conversation
SnowCheetos
force-pushed
the
codex/pr-182-vulkan
branch
from
September 3, 2026 21:32
9190225 to
d5d9c5e
Compare
SnowCheetos
previously approved these changes
Sep 3, 2026
micro-perceptron
previously approved these changes
Sep 3, 2026
micro-perceptron
force-pushed
the
codex/pr-182-vulkan
branch
from
September 3, 2026 21:44
d5d9c5e to
61c1cce
Compare
stack merge was automatically disabled
September 3, 2026 21:47
Pull Request is not mergeable
micro-perceptron
force-pushed
the
codex/pr-182-vulkan
branch
from
September 3, 2026 21:49
61c1cce to
b706ddc
Compare
SnowCheetos
dismissed stale reviews from micro-perceptron and themself
September 3, 2026 22:08
The merge-base changed after approval.
Colin-Hayes
force-pushed
the
codex/pr-182-vulkan
branch
from
September 3, 2026 22:14
b706ddc to
ce4c8d1
Compare
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
The change is confined to test logic, aligns descriptor offsets to avoid known Vulkan driver constraints, and preserves/strengthens the existing guard-region assertions.
Pull request overview
This PR updates the Vulkan integration test suite to ensure storage-buffer descriptor bindings use a nonzero offset that is aligned to Vulkan’s minStorageBufferOffsetAlignment, preventing spurious backend rejections on stricter drivers (e.g., Qualcomm Adreno) and renaming the test to match its actual coverage.
Changes:
- Rename the test to reflect aligned offset binding coverage rather than multi-workgroup behavior.
- Bind input/output storage buffers at a nonzero, aligned byte offset and size buffers to include guard regions.
- Preserve sentinel verification before and after the bound tensor range while writing/reading with the new offset.
File summaries
| File | Description |
|---|---|
| crates/virtio-accel-vulkan/tests/vulkan.rs | Updates the offset-binding test to use aligned nonzero descriptor offsets with padded buffers and sentinel checks. |
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
SnowCheetos
approved these changes
Sep 3, 2026
micro-perceptron
force-pushed
the
codex/pr-182-vulkan
branch
from
September 3, 2026 22:23
ce4c8d1 to
91e35ee
Compare
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
Why
The Qualcomm Adreno X1-45 driver reports
minStorageBufferOffsetAlignment = 64. The previous test bound an eight-element FP32 tensor at byte offset 32, so the backend correctly rejected the submission as incompatible before dispatch. Intel ANV's less restrictive alignment did not expose the test assumption.This PR is stacked on #182 and targets its
vulkan/ffi-8branch.Validation
On Qualcomm Adreno X1-45 GPU, Vulkan 1.3.295, Windows ARM64:
The Vulkan crate suite passes: 30 tests passed, 0 failed, and the manual performance test remains ignored.