Skip to content

vulkan_tf: split gpu.zig and kernels_ergo.zig under 600 lines (moves only) - #6197

Merged
ashhart merged 4 commits into
mainfrom
lead/vulkan-split-gpu
Dec 3, 2026
Merged

ashhart merged 4 commits into
mainfrom
lead/vulkan-split-gpu

Conversation

@ashhart

@ashhart ashhart commented Dec 3, 2026

Copy link
Copy Markdown
Owner

engines/vulkan_tf only, moves only: src/gpu.zig (2,293 lines) and src/kernels_ergo.zig (852) are split into files under 600 lines (gpu_init.zig, gpu_memory.zig, gpu_commands.zig and others; the largest is 540). Public names are re-exported where callers use them.

Function and test bodies are byte-identical to the originals, except that initResources is laid out from its original body with the same statements and cleanup guards in the same order. No behaviour, kernel or arithmetic change.

The Vulkan engine's tests pass 267 of 268 (1 skipped) on an M5 Ultra. This unblocks #6118, whose touched files were over the 600-line cap.

@ashhart

ashhart commented Dec 3, 2026

Copy link
Copy Markdown
Owner Author

READY to land on this head. engines/vulkan_tf only, moves only: gpu.zig (2,293 lines) and kernels_ergo.zig (852) split into files under 600 lines (largest 540); function and test bodies byte-identical except initResources, laid out from its original body with the same statements and cleanup guards in the same order. No behaviour, kernel or arithmetic change. The Vulkan engine's tests pass 267 of 268 (1 skipped) on an M5 Ultra.

  • Synthena

@ashhart ashhart added the synthena:ready Reviewed by Synthena and ready for group train label Dec 3, 2026
Move complete methods without body edits. Extract the oversized init resource tail into one helper on the same Context; retain parent cleanup guards and resource creation order.
@ashhart
ashhart force-pushed the lead/vulkan-split-gpu branch from 3294876 to 0cd3d23 Compare December 3, 2026 14:41
@ashhart
ashhart merged commit f25ae97 into main Dec 3, 2026
ashhart added a commit that referenced this pull request Dec 3, 2026
@ashhart
ashhart deleted the lead/vulkan-split-gpu branch December 3, 2026 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

synthena:ready Reviewed by Synthena and ready for group train

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant