Repository navigation
Commit ece6342
[FlyDSL] [Perf] pa_decode: launch gfx942 query-split CTAs split-major
The tile grid is (plan capacity, KV heads x query splits). Dispatch walks x
first, so split 1 of task 0 dispatches only after every slot of split 0,
padding slots included. On small grids, where the plan has many more slots
than tasks, the splits ran in sequential waves of mostly empty CTAs. On
large grids a task's splits ran far apart, each re-reading the task's K/V
from HBM.
On gfx942, split kernels now launch (KV heads x query splits, capacity), so a
task's splits dispatch together. They run concurrently and share the K/V
they re-read. The cache key records the choice. BF16 splits forced by the LDS
limit at large head dims only use it when tasks own at least four tiles; with
fewer, the split-major grid measured 0.93-0.97x.
Paired in-process A/B vs 8f9fe39 on MI308X (gfx942):
- 180 MTP grid cases: geomean 1.092x
- FP8 MTP4/8 batch 1: 1.04-1.45x
- FP8 sliding-window MTP4 batch 1/16: 1.28-1.63x
- BF16 D1024 MTP batch >= 16 with ctx >= 8K: 1.10-1.26x
- 111 unit-test cases: geomean 1.018x (MTP4/8 and window cases 1.16-1.20x)
gfx950 binaries are unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>1 parent 8f9fe39 commit ece6342
3 files changed
Lines changed: 34 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
69 | | - | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
70 | 72 | | |
71 | 73 | | |
72 | 74 | | |
73 | 75 | | |
74 | | - | |
75 | | - | |
76 | | - | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
77 | 79 | | |
78 | 80 | | |
79 | 81 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
451 | 451 | | |
452 | 452 | | |
453 | 453 | | |
| 454 | + | |
| 455 | + | |
| 456 | + | |
| 457 | + | |
| 458 | + | |
| 459 | + | |
| 460 | + | |
| 461 | + | |
| 462 | + | |
| 463 | + | |
| 464 | + | |
| 465 | + | |
| 466 | + | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
| 470 | + | |
| 471 | + | |
454 | 472 | | |
455 | 473 | | |
456 | 474 | | |
| |||
472 | 490 | | |
473 | 491 | | |
474 | 492 | | |
| 493 | + | |
475 | 494 | | |
476 | 495 | | |
477 | 496 | | |
| |||
532 | 551 | | |
533 | 552 | | |
534 | 553 | | |
| 554 | + | |
535 | 555 | | |
536 | 556 | | |
537 | 557 | | |
| |||
616 | 636 | | |
617 | 637 | | |
618 | 638 | | |
| 639 | + | |
619 | 640 | | |
620 | 641 | | |
621 | 642 | | |
| |||
927 | 948 | | |
928 | 949 | | |
929 | 950 | | |
| 951 | + | |
930 | 952 | | |
931 | 953 | | |
932 | 954 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
441 | 441 | | |
442 | 442 | | |
443 | 443 | | |
444 | | - | |
| 444 | + | |
445 | 445 | | |
446 | 446 | | |
447 | 447 | | |
| |||
517 | 517 | | |
518 | 518 | | |
519 | 519 | | |
520 | | - | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
521 | 525 | | |
522 | 526 | | |
523 | 527 | | |
| |||
0 commit comments