问题 / #2622
#2622 [Bug]: PLE gather reissues already-prefetched reordered and duplicate keys
open · @hotschmoe · 0 评论 · 去 GitHub 看
AMD / HIPNVIDIA / CUDAModels & quantsDocumentationLinux
说明
### What happened `PleTable::gather_batch` uses positional equality for Direct-mode prefetched keys. After prefetching A,B,C,D,E,F, gathering D,E,F,A,B,C reissues 96 requested rows even though every 16-row vector is already prefetched. Prefetching A once and gathering A,A,A reissues 48 requested rows because prefetches are deduplicated while the fast path requires at least as many slots as requested tokens. Expected: reuse existing immutable prefetched slots and decode into requested order. This is a redundant-request mechanism; no serving latency or physical disk-I/O saving is claimed. There is also a related cleanup defect in the same successful-match branch: on the first failed collect, it clears n_prefetch without draining subsequent outstanding tickets. A narrow proposed fix drains all tickets, preserves the first error, and returns without decoding after a failure. Failure handling is source-reviewed; runtime fault injection has not been performed. Reproduction: open a finite tiny IQ4_NL GGUF in Direct mode, call prefetch_rows for the vectors above, and compare the requested-row counter in io_report before/after gather_batch. [Exact executed fixture](https://github.com/hotschmoe/b70_ai_things/blob/fff2c71b0a1d806db428b8489b42fd248d50bebd/strata/flash-next/lowlevel_probe/ple_prefetch_cpu.cpp) and [evidence](https://github.com/hotschmoe/b70_ai_things/blob/fff2c71b0a1d806db428b8489b42fd248d50bebd/docs/20261015_strata_ple_prefetch_readiness.md). The fixture's local include path needs adjustment outside its original checkout. ### Strata version, GPU, OS Upstream main 296b59d2f73c8f04a805df29c2fa97655adace78 (0.1.44.1), Linux; CPU-only PleTable/PleReader/DirectFile reproduction, g++ 13.3.0, C++17/O2/pthreads. No GPU access required. Shared PleTable with the SYCL tree's host reader/file implementation was tested; full CUDA/HIP backend builds are not claimed. ### Engine log Both baseline and patched CPU harnesses exit 0, 44 cases per arm (88 total): 11 cases x cache 0/256 x worker off/on. All successful output bytes match an independently opened Mmap reference, and guards, finite references, logical byte accounting and request counts pass. Permutation: 96 -> 0 additional requested rows; duplicates: 48 -> 0; subset: 32 -> 0; extra-prefetch subset: 16 -> 0. Missing/over-limit/pending behavior retains expected counts. Runtime fault injection and out-of-range coverage are absent. Searched existing issues/PRs on 2026-10-15 for PLE prefetch, gather_batch and prefetch_keys. Related PRs #1516, #2073 and #2326 touch this area but retain positional matching; no exact duplicate was found. Search is keyword-based, not an exhaustive review of every open diff.
本站相关内容
相关页面的快捷入口。