Repository navigation
Commit 50c7d5c
fix(strix): compile every kernel copy at start-up
Triton compiles a kernel once per tile config and per class of each
integer argument (1, a multiple of 16, other), and the row count picks
both. The start-up warm-up ran two lengths only, so the first request
whose length was a multiple of 16 in a tile-config range waited for new
copies: in the request matrix the first timed pass of S with 1 question
(208 tokens) and of M with 2 (720 tokens), on both machines of rkinas#14 / rkinas#21.
The warm-up now runs the projections on zero rows of every range and
class (one row: the last row chunk of qkv / o, one readout row) and six
short forwards for attention and rotary (lengths other / multiple of 16
against readout rows 1 / other / 16). Kernels are unchanged.
basal-2.0 on the 8060S, request matrix: the old code compiled 18 copies
during the matrix (empty Triton cache: S-q1 pass 1 1.82 s against
0.18 s), now none. Start-up 8.8 s against 7.9 s with a filled Triton
cache, 18.7 against 13.8 s at the first start on a machine.
test_warmup_compiles_every_kernel_copy: no row count (20-5000 rows, 1-528
readout rows) compiles a kernel after the warm-up; it fails without it.
Co-Authored-By: Claude Opus 5.5 <[email protected]>1 parent 81b37f7 commit 50c7d5c
2 files changed
Lines changed: 74 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
294 | 294 | | |
295 | 295 | | |
296 | 296 | | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
297 | 342 | | |
298 | 343 | | |
299 | 344 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
235 | 235 | | |
236 | 236 | | |
237 | 237 | | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
238 | 267 | | |
239 | 268 | | |
240 | 269 | | |
| |||
0 commit comments