Repository navigation
Conversation
…up in one launch At decode tf_ink2moe_up ran a warp per 32 output columns over the whole K, so a layer's projections had 288 to 576 warps, about 6 an SM, and each warp's long serial stream left 70 % of the issue slots idle; the gate and up halves of w13 were two launches of 1.5 waves each. Decode warps now own one n8 tile (8 columns, kDecodeTiles), and one launch walks w13's rows in order, storing even rows to the gate and odd rows to the up buffer. Each output's mma sequence over K and its rounding are unchanged, so the bits are unchanged; prompt chunks keep 32 columns a warp and two launches.
… a tile The bounded scale loads chose word or bytes per word. A tile whose row scales are word-aligned with no partial word, every tile at Mini's shapes, now takes the whole-word loop it took before the bound, after one test; the byte path serves only the rest.
#4729 rewrites tf_ink2moe_up again (a warp eight output columns, gate and up in one launch) and records its compiled usage at sm_121 only, leaving zeros at sm_80, sm_86, sm_89 and sm_120 for the kernel registry test. The values are nvcc 13.0's, from kernel-contract-limits over fatbins built for all five SMs from this tree; the sm_121 entry equals the one the PR recorded. No kernel changes.
A lone row already runs its slot's captured step graph, but a round of two or more rows (several streams, or a verify window) launched every layer eagerly. Such a round now replays a graph from graph_cache, captured at the first round of its shape and keyed by its rows, its streams and tree attention's key groups. forward() splits into stage() and launch(). stage() uploads the round's ids, positions, slots, plan, paths, cache offsets and page table on the stream as before. launch() reads only device memory: a tree plan's offsets depend on its rows and streams alone, and the key groups are part of the key. So a replayed round makes the same launches with the same arguments as the eager round, and every row keeps its bits. attach drops these graphs along with the step graphs. With TENSORFOLD_KOLIBRI_GRAPHS=0 every round stays eager, and TF_GRAPH_CACHE=0 runs the cache's rounds eagerly. The f64 angle-table test moves unchanged to forward_rope_test.zig, which keeps forward.zig under the 600-line cap.
Owner
Author
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.
CI for a landing train: #4729 #4884 stacked on main in that order. Nothing merges from this PR: each PR above lands on its own once this tip is green, and this PR is then closed.