Satisfy debug-layer buffer validation - #39
Merged
Conversation
Use typed char pointers for get_rows/set_rows sources so Metal reflects read-only access correctly, and bind dummy values for inactive router finalize arguments required by API validation.
Owner
|
👍 |
zensh
pushed a commit
to ldclabs/ds4
that referenced
this pull request
May 10, 2026
Satisfy debug-layer buffer validation
Entrpi
added a commit
to Entrpi/ds4
that referenced
this pull request
May 20, 2026
Entrpi
added a commit
to Entrpi/ds4
that referenced
this pull request
May 20, 2026
…tirez#39) The raw-KV sliding-window attention runs in a 'growing' regime (window base at row 0) until pos+1 exceeds raw_window, then 'slides' (raw_start advances 1,2,3...). decode_scalars (raw_start/n_raw) are live on graph replay -- verified -- but the captured attention/KV path bakes a pre-saturation assumption when captured with raw_start==0, so a growing-regime graph replayed once the window slides produced wrong output (first divergence at pos=128 == DS4_N_SWA). Add a window_sliding bit to the per-layer graph key so the two regimes get distinct captured graphs; the sliding-regime graph reads raw_start live so one capture covers all raw_start>0 positions.
Entrpi
added a commit
to Entrpi/ds4
that referenced
this pull request
May 20, 2026
…irez#31-antirez#39) The per-kernel FNV-1a hash-dump subsystem, the emit-chain / router-bias / decode-scalars / per-warp MMVQ probes, and the SKIP_LAYER0 / SKIP_EMIT / HASH_DUMP / LGRAPH_PROBE / ROUTER_ARG_PROBE env flags were all scaffolding built to bisect the captured-vs-eager output divergence; that investigation is complete so they are removed here. The three correctness fixes the investigation produced are retained: the antirez#36 token-stable decode_scalars substrate, the antirez#38 layer-graph-replay counter advance, and the antirez#39 window_sliding layer-graph key bit.
This was referenced Aug 1, 2026
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.
This PR allows you to run ds4 with
MTL_DEBUG_LAYER=1. Without this I got a failure like so: