Repository navigation
Sync upstream b11436 - #249
Conversation
…perativeMatrix API support (ggml-org#29373) (ggml-org#29409) * vulkan : fix build issue of legacy glslc version by adding GGML_VULKAN_COOPMAT_GLSLC_SUPPORT macro check for Intel FA shader compiling * vulkan : add preprocess condition to filter out unsupported FA 2 phases kernels before creation. * vulkan : move lock_guard for Intel FA shader pointer creation under CM1 compiling preprocessor
…a8_bin`, `kernel_gemm_noshuffle_q5_k_q8_1_dp4a_ila_a8_bin` (ggml-org#29401) * opencl: add A8 Q5_K non-MoE non dp4a + dp4a binary kernel * opencl: fix s transpose - s only transposed for bin kernels --------- Co-authored-by: Li He <lih@qti.qualcomm.com>
which resulted in different greedy transcripts for 4.5% of English and 6.5% of Japanese test utterances. In Japanese, some differences changed entire words. This change: * uses `log(x + 2^-24)` instead of clamping to the log floor * uses a symmetric Hann window, equivalent to `torch.hann_window(periodic=False)` * adds the normalization epsilon to the standard deviation instead of inside the square root Only the `lfm2a` preprocessor opts into these behaviors. Other audio preprocessors are unchanged. Tested on top of 84e76d8 using `llama-server` with CUDA and `temperature=0`, compared against http://github.com/Liquid4All/liquid-audio fp32. Test set: * 200 LibriSpeech `test-clean` utterances (EN) * 200 Common Voice `ja` test utterances (JP) * identical 16 kHz audio passed to both implementations | Greedy transcript identical to `liquid-audio` | Without fix | With fix | | --------------------------------------------- | ----------: | ----------: | | EN F16 | 191/200 | 200/200 | | JP F32 | 187/200 | 200/200 | | JP F16 | 187/200 | 199/200 | The remaining JP F16 difference is a comma and matches the reference implementation's own bf16 output. Mel relative L2 error versus `liquid-audio`: * EN: 3.2% -> ~2e-6 median * JP: 3.9% -> ~2e-6 median
) The original function was broken on Windows for some unicode paths Paths without a trailing separator now create the last directory too, matching the function name. All current callers already include a trailing separator, so this change does not affect them. Signed-off-by: Adrien Gallouët <angt@huggingface.co>
…l-org#29449) * hex-scripts: fix table alignment * hex-scripts: find sw div calls using binary inspection tool
* Added tiled mul_mat. For each mul_mat_one_chunk, quants are unpacked into (max) 256x256 tiles of int8, one routine per quent. Then microkernel computes 16x16 tiles before writing out 256x256 float reults to main memory. Tests/benches in tests/test-tiled-mulmat.cpp. 3-6x speed improvement for large matmul, break even at 4096x64 * 64x4096, 80% performance (net loss) for GEMV. Error rates trivial (order of 1-e04 max, 1-e05 rmse). * Fixes for ARM/windows builds * more windows fixes, ggml-cpu.h isn't visible in MSVC for some reason * unified iqp + tiled on the Q5_K, IQ4_XS set for benchmarking, updated benchmark * Fixed accidental removal of llama_build_and_test(test-backend-ops.cpp) * First integration of iqp code Co-authored-by Bartowski <3266127+bartowski1182@users.noreply.github.com> * Cleaning up declaration of iq unpacking helpers to align with the bit unpackers * Removed iqp path * Fix cross-platform warnings * Disabling benchmarks unless explicitly enabled * Fix backend_init for DLL-based builds, add self and bartowski to CODEOWNERS for tiled * Put benchmarks behind a flag * kernel fix for AVX2, iq quants * Fix for asan, leaking memory in test-tiled-mulmat and avoid stack use after return * guarding env flags with std::call_once * Simplified repacking for VNNI to a single call per macrotile * No threadlocals anymore, aligned wdata access * Doing aligned reads since we ensure alignment with padding in wdata * Eliminated per-thread gather of Q8_K rows in mul_mat_id, we now gather/repack in a single pass. Repack method now takes pointer array to support both dense/normal and mmid paths. Interface with ggml-cpu.c simplified as a result * Unified/simplified dispatch and support checks. Put details on wdata needed inside the kernel.h body, simplified interactions with ggml-cpu.c. * Cleanup includes and whitespace, update src1_repack to return false if we don't need a special repack, so the common case is handled by driver * Better detection of win32 and additional whitespace fixes * Gating fuzz tests behind a parameter and some extra prints to try and fix slow CI hosts * Optimized AVX2 kernel * Changed interleave format and added ability to interleave in-place after dequant * Repacks now happen in-place, 16x64 microtiles are independent of each other * Only repack rows in groups of 16 as they're needed. Save work in low n_rows cases and optimize L1 usage in other cases * Use long panels for memory-bound regime (M <= 16), reintroduce IQP path for benchmarks * Fix unused warnings and cleanup. Improved IQ dequantization speed. * Removed separate process benchmarks * Revert "Removed separate process benchmarks" This reverts commit 0688cf4. * AVX2 optimizations and guards for tests on windows * Removed temp perf harness * Remove perf-mulmat from build * Removed IQP path, simplified tests to not use sub processes * Cleaning up alignment of wdata * Whitespace fixes and aligning L2 workspace to clean 512kb boundaries * Update ggml/src/ggml-cpu/tiled/tiled-kernel.cpp Co-authored-by: Georgi Gerganov <ggerganov@gmail.com> * Cleanup merge-duplicated declaration of test-backend-ops target * Undo accidental line deletion in ggml.c --------- Co-authored-by: Georgi Gerganov <ggerganov@gmail.com>
Co-authored-by: plotnikov.v10 <plotnikov.v10@wb.ru>
* support noncall test statements with arg * add tests
…ml-org#27530) * llama : add discard for deferred state writes * llama : add tensor zeroing helper for backends without tensor memset * llama : clear K/V data after failed sequence restore * llama : clear recurrent state data after failed sequence restore * llama : simplify discard and restore cleanup * llama : report error when abnormal cell count is found in state_read_meta * llama : clear attention state on hybrid restore failure * tests : cover failed state restore cleanup * llama : clear MLA state on dsa restore failure * tests : update test for rebased test suite * llama : clarify comment in llama_memory_recurrent::state_read
* implement sameas test * add tests
…gml-org#28849)" (ggml-org#29437) This reverts commit b04d4e5.
Signed-off-by: Adrien Gallouët <angt@huggingface.co>
* cuda: add F16 input to the FWHT The CUDA FWHT accepts F32 input only. This makes the source type a template parameter, so the kernel reads an F16 source directly instead of requiring a converted copy. The F32 path is unchanged. supports_op accepts an F16 src1 against an F32 src0 for the Hadamard hint. Every other F16 src1 against a non-F16 src0 is still refused. ggml_cuda_op_mul_mat_use_fwht is the single predicate both supports_op and the dispatch call now share, checking contiguity and same-shape(src1, dst) in addition to the type/hint conditions above. Without a shared predicate, supports_op could admit an op that ggml_cuda_op_fwht then rejects only after the unconditional same-shape assert has already fired; that gap predates this change (it applies to the existing F32 path too) but this PR is what touches supports_op, so it closes it here. test-backend-ops on an A10 (lambdalabs): MUL_MAT 1297/1297, including all 24 Hadamard cases (18 existing F32, 6 new F16). * cuda: use ggml_cuda_cast in the FWHT load, drop the comment
* hex-topk: trying to improve/cleanup the pipeline * hex-sampling: add STEP op * hex-sampler: add SUM op * hex-sampler: update CPY to support sampling cases * hex-binary: add support for chunking to handle large logits * hex-argmax: super basic version of ARGMAX * hex-binary: support for scalars in extended buffers * hex-binary: fix wrong indexing for dim 1 broadcasts across dim 2 slices * hex-argsort: fix missing header * hex-sampler: cleanup dma usage in the sampler related ops, and binary * hex-build: disable autovectorizer, it is better to use explicit hints for critical loops * hex-binary: fix perf regression due to is_1d fallback * hex-ops: update supported ops
* hexagon: support tiled Q4_0 and Q8_0 GET_ROWS * hex-get-rows: fix macros * hex-get-rows: use tiled HVX dequantization Assisted-by: OpenCode * hex-get-rows: fix register spills and clean up checks for unsupported ops * hex-get-rows: improve dma pipeline * hex-get-rows: improve/simplify kernel selection logic * hex-build: reenable vectorizer, didnt notice the regression earlier in the sampler update --------- Co-authored-by: Max Krasnyansky <maxk@qti.qualcomm.com>
Signed-off-by: Adrien Gallouët <angt@huggingface.co>
…29514) * ci : enable GGML_SCHED_DEBUG_REALLOC=1 for ctest workflows * cont : metal paravirtual device is not compatible
* RPC: use RDMA completion queue to not spin * add TODO for apple RDMA
…rg#29516) Signed-off-by: Adrien Gallouët <angt@huggingface.co>
…zes (ggml-org#28907) * HIP: Enable fattn-mma kernel on cdna for dkq > 256 for large batch sizes * CI: hip-quality-check: ignore spills for very large mfma mma kernels
The SYCL FWHT covers 64 to 512 via the standard butterfly network, plus 384/640/768/1280 via the Kronecker/Paley construction added separately in Hadamard hint can produce (1024, 2048, 4096, 8192); those still fall through to the default case and run as a dense GEMM against the materialized rotation tensor, correct but O(n^2) instead of O(n log n). fwht_kernel_wide runs one row per work-group instead of per sub-group, so each work-item keeps N/NT values rather than N/WARP_SIZE. Butterflies below the sub-group width still shuffle; those up to the work-group width go through work-group local memory; the rest stay in registers. Same butterfly and sign convention as the existing narrow kernel. ggml's SYCL backend registration (dpct::dev_mgr) unconditionally requires a GPU-labeled platform to exist and throws before any op-level test can run, so test-backend-ops could not be exercised on this box (a GPU-less pod) even via the CPU device. Verified instead with a standalone harness: the same kernel body run through a real SYCL CPU device (Intel oneAPI DPC++ 2026.1, OpenCL CPU backend), checked against an independent recursive-doubling Hadamard reference, cross-validated by first running the existing unmodified narrow kernel through the identical harness and confirming it passes (rules out a reference-convention bug before trusting a pass on the new code). Random-input results for all four widths, single- and multi-row: N=1024 NT=256 rows=1 max_abs_err=1.7e-07 max_rel_err=4.9e-04 PASS N=2048 NT=256 rows=1 max_abs_err=1.9e-07 max_rel_err=2.0e-04 PASS N=4096 NT=256 rows=1 max_abs_err=2.0e-07 max_rel_err=1.4e-04 PASS N=8192 NT=256 rows=1 max_abs_err=2.5e-07 max_rel_err=3.8e-03 PASS N=1024 NT=256 rows=7 max_abs_err=2.4e-07 max_rel_err=1.0e-03 PASS N=2048 NT=256 rows=5 max_abs_err=3.0e-07 max_rel_err=9.4e-04 PASS N=4096 NT=256 rows=3 max_abs_err=2.7e-07 max_rel_err=1.7e-03 PASS N=8192 NT=256 rows=2 max_abs_err=2.5e-07 max_rel_err=1.9e-03 PASS This covers the kernel algorithm itself; it does not exercise the ggml dispatch/supports_op integration end to end, which needs a real GPU (or a SYCL GPU plugin) to get past backend registration. test-backend-ops build is verified: fwht.cpp recompiles with zero warnings as part of ggml-sycl.
…org#29958) * llama : fix unexpected graph reallocation in the k-pool models Both k-pool models built a graph shape that depends on state the full-context reserve cannot know: - qwen4exp branched on inp->cache_safe, which turns false as soon as llama_memory_seq_cp shares cells (e.g. batched-bench -pps): the QSA layers swapped scatter+gather for fill+concat and dropped the new_pool_rep leaf, so the decode graph had 12 fewer nodes than the reserved one - glm5-next branched on gather = n_tokens <= 16 && n_kv > n_sel, so the TG decode built the gather shape (7564 nodes) while the last reserve, the PP one, had the dense shape (7762 nodes) Either mismatch forces a decode-time re-reserve that drops the worst-case sizing and bakes in the current state, so the next state growth (n_pool, n_kv, n_new) needs more room at an unchanged graph size and aborts under GGML_SCHED_DEBUG_REALLOC=1. Reproduce with, e.g.: GGML_SCHED_DEBUG_REALLOC=1 ./bin/llama-batched-bench \ -hf ggml-org/GLM-5.3-Flash-GGUF:Q2_K -npp 2500 -ntg 32 -npl 1,2 \ -c 32768 -pps -kvu Always scatter+gather the pooled keys, and pick gather from context constants only: n_ubatch bounds every ubatch, top_k + kpool - 1 bounds n_sel. Every graph of a context then shares one shape, which the reserve covers, and the dense path measured faster than the gather path at 2.5k and 16k context. Assisted-by: pi:llama.cpp/MiMo-V2.6-Flash-MOPD * llama : drop the unused k-pool cache_safe graph API The k-pool graphs no longer branch on cache_safe, so nothing reads get_kpool_cache_safe() or the conditional new_pool_rep any more: both models always pass the scatter target, which set_input_kpool now requires instead of merely preferring. Also drop the cache_safe copy in kpool_build_sizes(), a sizes-only helper. The layout and state flag itself stays, it still decides which pools a layout with shared cells must re-pool. Assisted-by: pi:llama.cpp/MiMo-V2.6-Flash-MOPD * tests : add a shared-seq graph reserve regression test Decode a prompt into seq 0, share its cells with seq 1 via llama_memory_seq_cp (what llama-batched-bench does for -pps), then keep decoding both sequences. For the k-pool models sharing clears cache_safe, which changes the graph topology while the pools keep growing, so a scheduler that re-reserves with the current state instead of the worst-case one aborts under GGML_SCHED_DEBUG_REALLOC=1. The test registration sets that flag, and the test aborts on both k-pool models before 2220411. kimi-linear and minimax-01 are skipped: they reserve the final pp graph with n_seqs = 1 (see [TAG_RESERVE_DIAG_DECAY] in llama-context.cpp), so every multi-seq graph has a different layout and re-reserves by design. Assisted-by: pi:llama.cpp/MiMo-V2.6-Flash-MOPD * cont : add TODOs * cont : fix comment * cuda: match the moe weighted reduction on empty ubatches ggml_cuda_match_moe_weighted_reduction rejected tensors with zero rows. A ubatch without outputs shrinks the last layer to zero rows through inp_out_ids, so graph_optimize dropped its alloc dep there and the scheduler graph lost one node compared to the reserved one. The scheduler then re-reserved at the size of that ubatch, and the next ubatch with the same node count but larger tensors aborted under GGML_SCHED_DEBUG_REALLOC=1. The compute loop already skips empty nodes before trying any fusion, so the guard only made the alloc deps depend on the row count. * tests: build the rollback test only where internal symbols link The shared-seq case calls llm_arch_from_string, which libllama does not export through LLAMA_API, so linking test-recurrent-state-rollback fails on Windows with shared libraries. Its build now sits in the NOT WIN32 OR NOT BUILD_SHARED_LIBS block, next to test-llama-archs and the test registration it already lives under. * tests: skip archs by name in the shared-seq reserve test The skip of kimi-linear and minimax-01 went through llm_arch_from_string, which libllama does not export through LLAMA_API, so the test could not link on Windows with shared libraries. It now compares the general.architecture string directly, and the test builds on every platform again. --------- Co-authored-by: Pascal <admin@serveurperso.com>
* vulkan: sparse flash attention for quantized K/V Assisted-by: Claude * vulkan: single-scan sparse FA index compaction The compaction ran one workgroup per mask row and walked the row in BLOCK_SIZE chunks, with a workgroup scan per chunk. For decode that is one workgroup doing KV/1024 barrier-bound iterations, so at 128k cells it cost more than the sparse attention it feeds. Split the row into contiguous segments instead: one per subgroup with ballot counting over coalesced loads, or one per thread without subgroups. A single scan over the segment counts then gives each segment its output offset. The index list stays ascending.
* server: reject partial media truncation * server: keep only the keep_first fix Drop the mtmd test helper change, which no longer builds since clip_image_f32_batch stores its entries by value, and drop the vision test: no test fixture reaches a cut between two adjacent media chunks with a reused cache (tinygemma3 uses SWA and wraps images in text tokens, tinyopenjev and small-test are recurrent), so the test passed or failed independently of the fix. --------- Co-authored-by: Pascal <admin@serveurperso.com>
* ggml_cuda: optimize accumulation in mmq_vec_dot_fp4_fp4_mma for better performance * remove whitespace * fix: correct indentation in mma_block_scaled_fp4 loop
* server: support vision input for Clef * move input_attn_causal to private * extend old server_batch::embd * server_batch::token::pos to multi dim * nits * fix abort * fix img tokens cap * fix yield_to_queue mutate data
…tatistics (ggml-org#27990) * webui: Use toLocaleString() format consistently across chat message statistics * Add missing semicolon * ui: respect lint
Assisted-by: pi:llama.cpp/Qwen3.8-27B
* cuda: stage the lightning indexer queries in head passes for MUSA MUSA archs 21 and 22 cap static shared memory at 28 KB, and the tile kernel staged the queries of all four heads next to the key tile for 33 KB. The queries are now staged in passes of LIGHTNING_INDEXER_TILE_HEADS_PER_PASS heads: two on MUSA for 25 KB, four elsewhere where the single pass folds to the previous kernel. * cuda: use the vector lightning indexer kernel on MUSA Address review from am17an: the tile kernel stays off MUSA, whose archs 21 and 22 cap static shared memory at 28 KB, below the 33 KB the tile needs, so MUSA keeps the vector kernel it ran before. This replaces the head passes, CUDA and ROCm run the merged kernel unchanged.
…29936) * Fix Intel prefill regression on MoE models * Revert the n_per_expert change back to nei1
…gml-org#29987) Signed-off-by: Adrien Gallouët <angt@huggingface.co>
* llama.cpp : bump version to 0.6.0 * scripts : update summary prompt (#0)
* hexagon: head-parallel flash_attn partitioning for row-split multicore In row-split mode each core computes its output row shard of every MUL_MAT, but flash_attn was previously partitioning by Q tokens (flat qrow split) instead of by heads. This forced every core to read the full KV cache (all n_kv_heads), negating the memory bandwidth benefit of multicore on flash_attn. Change both HMX and HVX flash_attn kernels to partition by KV heads when n_kv_heads is divisible by n_cores: core i processes heads [i*n_kv_heads/N, (i+1)*n_kv_heads/N) exclusively, reading only its head shard of the KV cache. Falls back to the original token-block split when n_kv_heads % n_cores != 0 (e.g. Gemma-4 with 2 KV heads on 4 cores). Controlled by GGML_HEXAGON_FA_HEAD_SPLIT (default 1 = on). The flag is packed into bit 1 of the existing is_dst_fp32 kparams byte to stay within the 128-byte kernel_params blob limit. Measured gains at 4c row-split (PP t/s, ubatch=1024): Qwen3-0.6B: 6977 -> 11026 (+58%) llama-3.2-3B: 3717 -> 5522 (+49%) Qwen3.5-4B: 2739 -> 2855 (+4%) Gemma-4 MoE: no change (MoE FFN dominates, fallback path) TG is unchanged (flash_attn is a small fraction of decode time relative to the matmul+barrier cost per layer). * hex-fa: cleanup kern_params and head-split selection * hex-fa: add -fa-head-split option to run.py * hex-mdev: update matmul solver to account for reduced work in row-split scenarios * hex-mmid: better work splitting by expers in multi-dev scenarios * hex-fa: update HMX gating based on the model/n-hvx/ctx-len sweep * hex-fa: precompute softcap/scale on the host * hexagon: flatten matmul into 2d to use HMX in multi-sequence * hex-mm: cleanup kparams and use collapse to 3/4D -> 2D mapping * hex-mm: fix typo in collapse fallback * hex-mm: another pass at consistent naming for act tensors * hex-mm: add support for colapsing dims in fused matmuls * hex-build: fix WoS build errors * hex-mm: make sure to enforce dst stride in can_collapse * hex-fa: add a onliner commit for head-split check * hex-fa: remove unused local head_split var * hex-fa: tighten up can_split checks * hex-mm: update unfused paths to use act instead src1 * hex-mm: make sure to check all dsts for splitting * hexagon: fix the second weight chunk address in the batched HMX matmul prologue * hexagon: F16 activation and ragged N in the HMX matmul * hex-mm: tighten the ragged/split checks in mdev cases * hex-mm: enable MM fusion for F16 activations * hex-mm: pass tiled sizes to the solver in fused paths * hex-mmid: remove scalar divs from expert mapping loops * hex-mmid: proper cacheline safety enforcement for mdev splits * hex-mm: improve solver for mdev split scanarios and tail handling * hex-mm: remove redundant checks * hex-mm: fix fused HMX MUL_MAT_NX drops the final partial tile for quantized weights * hex-mm: better handling of ragged shapes (removes scalar memset of vtcm) --------- Co-authored-by: ebateni <ebateni@qti.qualcomm.com> Co-authored-by: Jhen-Jie Hong <iainst0409@gmail.com> Co-authored-by: Yiwei Shao <yiwei@aizip.ai>
…org#30008) Assisted-by: pi:llama.cpp/Qwen3.8-Flash-Next
* hexagon: add pool_2d support * hexagon: add pool_1d support * hex-pool: dma changes * hex-pool: Optimize HTP pooling boundaries and DMA pipelining * hex-pool: code cleanup and correctness fixes * hex-pool: re-write the DMA pipeline * hex-pool: pool chunking support * hex-pool: remove/vectorize all scalar paths * hex-pool: simplify chunk solver (no need for a loop) * hex-pool: remove redundant checks --------- Co-authored-by: Max Krasnyansky <maxk@qti.qualcomm.com>
* hexagon: ssm-conv double-buffered DMA for prefill and decode restructuring * hex-ssm-conv: remove divs from loops and fix trace events * hex-dma: improved SSM_CONV dma pipeline and streamlined dma_queue --------- Co-authored-by: Max Krasnyansky <maxk@qti.qualcomm.com>
* llama: re-pool each shared k-pool rep once With shared cells every pool is re-pooled, and since the pooled keys are always scattered, the pools a seq_cp shares between sequences wrote the same rep row from several scatter entries, a data race on the CPU backend. Mark each rep once: the sharing sequences read the same row through pool_cells. * llama: assert whole-sequence seq_cp in the hybrid idx memory The recurrent state is always copied whole whatever the range, and a k-pool cell shared by a partial copy could carry two pool groupings with a single pooled row. Every caller copies whole sequences, so reject partial ranges instead of supporting them. * llama: drop the k-pool cache_safe mode With whole-sequence seq_cp, sequences sharing cells share their pools too, so the pooled row of a shared rep is valid for all of them. Mark each rep once in every ubatch instead of re-pooling everything while cells are shared, which removes the sharing scan and the stale-all workarounds in seq_rm, state_read and state_drop. seq_cp now only stales the destination.
* ggml-openvino: skip unselected graph branches and support DUP Upstream ggml-org#29622 adds a mixed token/embd branch to every input embedding graph through ggml_build_forward_select(). Its nodes are not flagged for compute, but the backend translated them anyway, and the DUP in that branch was unsupported, so the scheduler split the graph and passed the embeddings across the split with a fixed token count. The first single-token decode then failed (test-thread-safety on CPU and GPU). Build the OV model from the compute nodes only, and translate a same-type contiguous DUP like CONT so the graph stays on one backend. * ggml-openvino: make inp_scale_rows token dim dynamic ggml-org#29622 also moves the per-token embedding scale (gemma3, gemma3n, gemma4) into a new [1, n_tokens] input. Give it a dynamic token dim and pad it per chunk on the static (NPU) path. * ggml-openvino: skip GPU MUL_MAT op tests with unbound Q4_1/Q4_K weights Op tests build Q4_1/Q4_K weights as u4 with an f16 zero point. The GPU plugin fails to compile that form for some row counts with "clFinish, error code: -5 CL_OUT_OF_RESOURCES", which aborts test-backend-ops on the MUL_MAT cases added in ggml-org#29869 (e.g. m=1000, n=2, k=1024). Model weights use a u4 zero point and are not affected. Report these cases as unsupported on GPU until the plugin is fixed. Op tests check support before allocating, so the check matches unbound weights only; model loading probes with a dummy buffer and keeps its weights on the GPU. * ggml-openvino: create FILL in the output type translate_fill always built an f32 constant, so an f16 FILL produced f32 data and the copy back overran the f16 output buffer. Use the output type for the constant. * ggml-openvino: reject CONCAT with a quantized type Quantized inputs are dequantized when translated, so the backend cannot write a quantized CONCAT output. Report it as unsupported, as for CPY to a quantized type. * ggml-openvino: handle the single recurrent state gather of build_rs ggml-org#29856 changed build_rs to gather all recurrent states with one GET_ROWS on the s_copy leaf and take the ubatch and extra states as views of it. The stateful path matched only the previous form, a GET_ROWS per view of s_copy, so Qwen3.5 failed with stateful execution on CPU and GPU ("is_axis_valid(axis, r)" in a Concat). For a single-slot cache, treat the GET_ROWS on the s_copy leaf as the active-state gather, keep the rank-4 layout of reshapes that read a view of it, and map the copy of the empty extra-state view to the single-slot remainder writeback. Do not warn about the dynamic dim of empty views. * openvino: align eltwise operand ranks to work around a GPU-plugin defect * openvino: match the MoE fusion on the rank-3 stateful graph * ggml-openvino: do not unsqueeze an RMS norm output in AlignEltwiseOperandRanks The pass unsqueezes the lower-rank operand of an Add/Multiply/Subtract whose operand ranks differ. In gemma-3 the lower-rank operand of the post-attention residual add is the norm output, and unsqueezing it makes the GPU plugin compute the layer wrongly: gemma-3 returns empty answers on GPU with stateful execution. Skip the rewrite when the lower-rank operand is an RMS norm output. * docs : update OpenVINO validated models --------- Co-authored-by: Mustafa Cavus <mustafa.cavus@intel.com>
|
You have reached your Codex usage limits for security reviews. Please try again later. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4d03201686
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| on: | ||
| workflow_dispatch: # allows manual triggering | ||
| push: |
There was a problem hiding this comment.
Remove the newly imported upstream workflows
This sync adds this workflow plus eight other non-unsloth-* workflows, despite scripts/unsloth/sync_deletes.py explicitly enforcing that the fork owns no upstream CI and removing workflows added since the merge base. These files subscribe to pushes and pull requests and will schedule upstream self-hosted jobs in this fork; additionally, release-publish.yml causes both sync lint hosts to fail because its workflow_run trigger lacks the required justification (confirmed with python3 scripts/unsloth/check_workflow_triggers.py --root .). Run the added-workflow deletion step for this sync rather than retaining these nine files.
Useful? React with 👍 / 👎.
| if (GGML_CUDA_CCCL_VERSION) | ||
| include(FetchContent) | ||
|
|
||
| FetchContent_Declare( | ||
| CCCL | ||
| GIT_REPOSITORY https://github.com/nvidia/cccl.git | ||
| GIT_TAG v3.2.0 | ||
| GIT_TAG "${GGML_CUDA_CCCL_VERSION}" |
There was a problem hiding this comment.
Update CUDA builds to use the replacement CCCL option
The sync replaces GGML_CUDA_CUB_3DOT2 with GGML_CUDA_CCCL_VERSION, but all fork CUDA setup paths (unsloth-cuda-linux-setup, unsloth-cuda-windows-setup, and the Windows ARM64 workflow) still pass the removed option. CMake therefore ignores the requested override and uses the older CCCL bundled by the fork's CUDA 12.8/13.3/13.4 component sets; top-k.cu only enables DeviceTopK for CCCL 3.4.3 or newer, so every published CUDA bundle falls back to the slower sort implementation. Pass -DGGML_CUDA_CCCL_VERSION=v3.4.3 as the synchronized upstream CI now does.
Useful? React with 👍 / 👎.
Summary
Syncs master to upstream
b11436(b9a5a00b8), the current nightly base. The last sync wasb10632on 2026-08-26.scripts/unsloth/upstream-sync.jsonis updated in the same merge commit.Please merge with a merge commit, not squash, so
b11436stays an ancestor of master.Conflicts
All 51 conflicts were modify/delete: files the fork had already deleted (upstream workflows,
AGENTS.md,CODEOWNERS) that upstream has since edited. They stay deleted, so no fork-authored file changes.verify_upstream_sync.py
scripts/unsloth/upstream-sync.jsononly, the intended metadata updatetools/ui/src/routes/settings/[[section]]/+page.svelteonly. Upstream deleted it in ggml-org#27744, so this looks like the[[section]]brackets being read as a glob by the checkOutside
.github/andscripts/unsloth/, master still differs fromb11436only inAGENTS.md,CLAUDE.mdandCODEOWNERS. Those were already deleted before this sync.