arXiv Science⌕ Search

arXiv subjects

Jingsheng Yan

Publications and source records attributed to Jingsheng Yan.

2 recordsLinked to original sources

Different Parallelism, Same Bits: Bitwise-Consistent LLM Reinforcement Learning with Unimatch

Reinforcement learning (RL) of LLMs computes each token's probability twice, once in rollout and once in the trainer, and expects the two to be bitwise consistent. In practice they differ, and this training-inference mismatch (TIM) can make training collapse. TIM mainly comes from parallelism. An engine splits its computation across GPUs, runs the pieces in parallel, and combines their results by a reduction, mostly an addition. Floating-point addition is non-associative, so adding in different orders gives different results. Existing work takes two directions. The first forces rollout and the trainer to add in one agreed order. Each engine then gives up its own configuration (e.g., its batch size and parallel degrees), which can cost up to 91% of the training throughput. The second keeps parallelism and mitigates TIM in the algorithm, which adds up to 47% to the step time and leaves the mismatch. Both thus trade parallelism against bitwise consistency, and the two appear to conflict. Our key insight is that what really conflicts with bitwise consistency is not parallelism, but the non-associative reductions in parallelism. If these reductions are eliminated, the two can coexist. We present Unimatch, which makes these reductions associative with two techniques. Structural elimination changes how a computation is split, so that each GPU computes complete outputs and the reduction is a gather without any addition. Arithmetic elimination changes the operation of a reduction to integer addition, which is associative. With Unimatch, the two engines return bitwise-identical results under their own configurations, and Unimatch achieves the performance of the unmodified engines (0.98-1.04x their step time). In 300 RL steps on Qwen3-30B-A3B, training on the unmodified engines collapses, with and without a standard algorithmic mitigation, and training with Unimatch keeps improving.

cs.DC↗

Guidelines for Building Indexes on Partially Cache-Coherent CXL Shared Memory

The \emph{Partial Cache-Coherence (PCC)} model maintains hardware cache coherence only within subsets of cores, enabling large-scale memory sharing with emerging memory interconnect technologies like Compute Express Link (CXL). However, PCC's relaxation of global cache coherence compromises the correctness of existing single-machine software. This paper focuses on building consistent and efficient indexes on PCC platforms. We present that existing indexes designed for cache-coherent platforms can be made consistent on PCC platforms following SP guidelines, i.e., we identify \emph{sync-data} and \emph{protected-data} according to the index's concurrency control mechanisms, and synchronize them accordingly. However, conversion with SP guidelines introduces performance overhead. To mitigate the overhead, we identify several unique performance bottlenecks on PCC platforms, and propose P$^3$ guidelines (i.e., using Out-of-\underline{P}lace update, Re\underline{P}licated shared variable, S\underline{P}eculative Reading) to improve the efficiency of converted indexes on PCC platforms. With SP and P$^3$ guidelines, we convert and optimize two indexes (CLevelHash and BwTree) for PCC platforms. Evaluation shows that converted indexes' throughput improves up to 16$\times$ following P$^3$ guidelines, and the optimized indexes outperform their message-passing-based and disaggregated-memory-based counterparts by up to 16$\times$ and 19$\times$.

cs.OS↗