arXiv:2604.26039v2 cs.LG

RaMP: 전문가 혼합 모델을 위한 런타임 인식 메가커널 다형성

RaMP: Runtime-Aware Megakernel Polymorphism for Mixture-of-Experts

Vyom Sharma, Debajyoti Datta

제출 2026-11-03

한국어 초록

LLM 서빙 시스템은 타일 크기와 같은 후보 커널 구성을 다양한 배치 크기에서 측정하는 방식으로 GPU 커널을 오프라인에서 자동 튜닝한다. 이는 밀집 계층처럼 토큰 수가 커널의 작업량을 결정하는 경우에는 잘 작동한다. 그러나 라우터가 토큰을 전문가와 GPU에 어떻게 나눌지 결정하는 전문가 혼합(MoE) 계층에서는 그렇지 않음을 보인다. 최적의 커널 구성은 토큰 수만이 아니라 이러한 분할에 따라 달라지며, 전문가 병렬화에서 각 GPU의 실제 토큰 분포에 맞춰 구성을 선택하면 기존 선택보다 최대 1.45배 빠르다. 이 분할은 라우터가 실행되기 전까지 알 수 없으므로 미리 조회할 수 없다. 따라서 라우팅 분할 자체로부터 실행 시점에 커널 구성을 선택하는 RaMP를 제안한다. RaMP는 상위 구성들을 하나의 다형성 커널로 컴파일하고, GPU 상의 작은 비용 모델이 수 마이크로초 안에 그중 하나를 선택한다. 비용 모델이 학습에 사용하지 않은 서빙 트래픽에서, RaMP의 비용 모델이 커널의 전체 구성 공간에서 선택한 구성은 토큰 128개 이상의 배치에서 vLLM의 오프라인 오토튜너가 동일한 커널에 대해 선택한 구성보다 최대 1.45배 빠르고(전체 배치 기준 1.27배), 모든 구성을 측정하는 전수 탐색의 3.5% 이내이다. RaMP의 커널과 선택 방식을 함께 사용하면 MoE 계층이 토큰 128개 이상의 배치에서 vLLM의 Triton MoE보다 최대 1.84배 빨라진다. vLLM에서 텐서 병렬화와 전문가 병렬화 모두에서, RaMP는 가장 빠른 기본 MoE 백엔드 대비 출력 토큰당 시간을 최대 1.11배 단축한다.

원문 초록

LLM serving systems autotune their GPU kernels offline by timing candidate kernel configurations, like tile sizes, at a range of batch sizes. This works when the number of tokens determines a kernel's work, as in dense layers. However, we show that it does not hold for Mixture-of-Experts (MoE) layers where the router decides how the tokens are split across experts and GPUs. We find that the best kernel configuration depends on this split, and not only on the number of tokens--under expert parallelism, choosing the configuration for each GPU's actual token distribution is up to 1.45x faster than the existing choice. The split is not known until the router runs, so it cannot be looked up in advance. Hence, we introduce RaMP, which chooses the kernel configuration at run time from the routing split itself. RaMP compiles top configurations into one polymorphic kernel, and a small cost model on the GPU picks among them in a few microseconds. On serving traffic its cost model was never fit on, the configurations RaMP's cost model chooses from the kernel's full configuration space are up to 1.45x faster than those vLLM's offline autotuner picks for the same kernel on batches of 128 tokens or more (1.27x over all batches), and within 3.5% of an exhaustive search that times every configuration. RaMP's kernel and choice together make the MoE layer up to 1.84x faster than vLLM's Triton MoE on batches of 128 tokens or more. In vLLM, under both tensor and expert parallelism, RaMP lowers time per output token by up to 1.11x over the fastest stock MoE backend.

제출 이력

확인된 버전만 표시합니다. 전체 제출 이력은 arXiv 원문에서 확인하세요.

  1. arXiv:2604.26039v2제출 시각 미확인

함께 살펴볼 논문

공통 태그를 근거로 연결했습니다. 실제 인용 관계나 논문의 우수성을 뜻하지 않습니다.

공통 태그로 연결된 공개 논문이 아직 없습니다.

토론

이 논문과 연결된 포럼 글이 아직 없습니다.