返回全部动态
llama.cpp b10545 修复 Metal 矩阵乘法越界问题
原标题:b10545
AI 摘要
llama.cpp 发布 b10545 版本,修复了 Metal 后端 Tensor API 中矩阵乘法在 K 维度不是 32 的倍数时可能读取越界内存导致结果错误或 NaN 的问题。修复通过动态 K 范围钳制确保每次迭代只读取有效数据,并新增了相关测试用例。该版本同时提供了多个平台的二进制下载。
以上摘要由 AI 生成,可能存在误差。事实请以原文为准。
正文节选
<details open> metal : clamp K extent in tensor API mat-mat kernel for K not a multiple of 32 (#27450) The Tensor API mat-mat path of kernel_mul_mm (GGML_METAL_HAS_TENSOR) fed a static K=32 tile to the matmul2d op on every iteration. On the last, partial K tile (ne00 % 32 != 0) the src1 slice extends past the K extent of the tensor, and the op reads those out-of-bounds elements (undefined behavior per the MSL specification, section 2.22.2). Depending on stale memory contents, this corrupted th
发布时间:2026-08-21 11:49
抓取时间:2026-08-21 12:47
来源机构:ggml-org