반응형

https://open.substack.com/pub/semianalysis/p/computation-and-data-movement-for 

2026.9.22
[Computation and Data Movement for Inference]

이 문서는 혼합 전문가(MoE) 모델의 효율적인 추론을 위해 하드웨어 구조와 데이터 이동을 어떻게 최적화해야 하는지 심도 있게 다룹니다. 저자는 추론 과정을 프리필(Prefill), 미드필(Midfill), 디코드(Decode)라는 세 가지 독특한 운영 체제로 구분하며, 각 단계가 요구하는 계산 집약도와 메모리 대역폭의 차이를 강조합니다. 특히 KV 캐시를 불변의 데이터 블록으로 취급하여 저장 장치와 연산 노드 사이를 유연하게 이동시키는 분산형 추론 서비스 구조를 핵심 해결책으로 제시합니다. 결론적으로 이 글은 모델의 계층 구조를 하드웨어의 파이프라인, 텐서, 전문가 병렬화에 정교하게 매핑함으로써, 거대 모델의 복잡한 데이터 흐름을 최적의 처리량으로 연결하는 토큰 팩토리의 설계 원리를 설명하고 있습니다.

 

MoE 추론 인프라의 병목은 총 파라미터 수가 아니라, 단계별 활성 데이터—특히 KV cache·전문가 가중치·라우팅 activation—를 언제 어디로 얼마나 빠르게 이동시키는가

Figure 1. Overview of model stages in an inference service.

 

Figure 5. KV blobs moving through storage and worker memory.
Figure 6. Prefill and midfill are separated from the closely coupled decode loop at the KV-cache boundary.
Figure 7. Projected effect of faster memory (hybrid-bonded DRAM, super-fast 3D RAM)) on midfill and decode with 500k token context cache length. Source: SemiAnalysis model simulator with projected accelerator and GPU performance.

 

Figure 8. Flow through an MoE prefill layer.

 

Figure 9. Flow through one MoE decode layer.

 

Figure 10. Midfill combines the cached-state read of decode with enough new tokens to batch model and expert work.

 

실무 적용 관점
AI 서비스/플랫폼 관점에서 보면, 인프라 검토 기준은 GPU 수나 모델 파라미터만으로는 부족합니다.

1)워크로드 분류: Prefill/Midfill/Decode를 분리 계측하는가
2)KV 관리: KV cache lifecycle, eviction, 재구성, storage tiering 정책이 있는가
3)네트워크 설계: expert routing이 scale-up domain 내부에 머무르는가
4)스케줄링: context length·SLO·worker 상태를 반영한 cache-aware routing이 있는가
5)성능 KPI: 단순 GPU utilization이 아니라 TTFT, TPOT, tokens/s/GPU, KV transfer latency, cache hit ratio, queue oscillation을 함께 관리하는가
5)용량 계획: HBM 증설보다 memory bandwidth, shared DRAM/SSD bandwidth, RDMA 및 orchestration 병목을 함께 평가하는가

 

728x90
반응형
Posted by Mr. Slumber
,