mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-27 00:25:52 +01:00
[PR #2051] Normalize SPIR-V file byte order (SPIRV-WORDS-ENDIAN) #2057
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#2057
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/2051
Author: @alexandersato0830
Created: 11/25/2026
Status: 🔄 Open
Base:
main← Head:codex/spirv-word-endianness📝 Commits (1)
09014c5Normalize file byte order in the SPIR-V reader📊 Changes
2 files changed (+23 additions, -3 deletions)
View changed files
📝
runtime/src/spirv_words.h(+13 -3)📝
runtime/test/shader_library_test.cpp(+10 -0)📄 Description
Claimed in the coordination issue as: SPIRV-WORDS-ENDIAN
What and why
The shared shader reader rejected SPIR-V files in the opposite byte order, although the Python reflector accepts either order. Use the SPIR-V magic to detect the file’s byte order and return native-endian words to Vulkan. The existing byte-count and short-read checks still apply. SPIR-V binary format · Vulkan SPIR-V environment
Tested
9f9a7c5and theshader_libraryCTest target passed with the fix. The test checks the entire output, including a word beyond the header.git diff --check.GPUs tested: n/a (CPU-only reader test).
AI-assisted: yes.
main.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.