]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
hexagon: further improved pipeline of the core bits (L2, DMA, MM, FA) (#26049)
authorMax Krasnyansky <redacted>
Fri, 24 Jul 2026 02:13:03 +0000 (19:13 -0700)
committerGitHub <redacted>
Fri, 24 Jul 2026 02:13:03 +0000 (19:13 -0700)
commit0a50d9909a3478e82679f505bf8595d1eee4b0a8
treebaf823c95cd1fd4608152ebb8b1ee3d85c1bbde6
parentc0bc8591e8815c63cb01dd3f051a8b0df02501c9
hexagon: further improved pipeline of the core bits (L2, DMA, MM, FA) (#26049)

* hex-l2: use dirty ranges for flushing

* hex-l2: simplify range based flush logic

* hex-l2: optimize dirty range scans

* hex-hvx: support for reduce_max_i32

* hex-mm: optimize fused MUL_MAT+ADD to use vtcm for bias when it fits

* hex-mmid: optimize mmid row-mapping generation

* hex-mmid: optimize mmid row-mapping generation

* hex-mmid: optimize mmid row-mapping generation (round2)

* hmx-mm: optimize output proc by tiling (col-chunking)

* hex-fa: start the next q dmas a bit earlier

* hex-fa: prefetch Q even earlier

* hvx-fa: optimize softmax to keep things in hvx registers

* hex-fa: hoist const register init in softmax loop

* hmx-fa: kick off next-qkv DMAs before o-proc

* hmx-fa: hoist various checks out of the inner loop

* hmx-fa: adjust the cost model to better balance softmax work across hvx threads

* hmx-fa: overlap diag rescale build with last HMX task

* hmx-fa: optimize idx update in output proc

* hmx-fa: unroll the softmax loops for improved perf

* hmx-fa: overlap qk-dot with softmax, double-buffer p and s tiles

* hex-trace: double the default number of trace entries

* hex-trace: add trace events for opbatch and buffer mgmt

* hex-trace: overhaul tracing to simplify runtime event handling and support opbatch stats

* hex-trace: replace ascii timeline diagram with pipeline bubbles detector

* hex-trace: handle missing start/stop events

* hex-dma: always log stop/start trace events even for dummy dmas

* hex-scripts: fix flake warnings
17 files changed:
ggml/src/ggml-hexagon/ggml-hexagon.cpp
ggml/src/ggml-hexagon/htp/dma-queue.c
ggml/src/ggml-hexagon/htp/dma-queue.h
ggml/src/ggml-hexagon/htp/flash-attn-ops.c
ggml/src/ggml-hexagon/htp/flash-attn-ops.h
ggml/src/ggml-hexagon/htp/hmx-mm-kernels-tiled.h
ggml/src/ggml-hexagon/htp/htp-ctx.h
ggml/src/ggml-hexagon/htp/htp-ops.h
ggml/src/ggml-hexagon/htp/htp-tensor.c
ggml/src/ggml-hexagon/htp/htp-tensor.h
ggml/src/ggml-hexagon/htp/hvx-fa-kernels.h
ggml/src/ggml-hexagon/htp/hvx-reduce.h
ggml/src/ggml-hexagon/htp/main.c
ggml/src/ggml-hexagon/htp/matmul-ops.c
ggml/src/ggml-hexagon/htp/matmul-ops.h
scripts/snapdragon/ggml-hexagon-profile.py
scripts/snapdragon/ggml-hexagon-trace.py