avatar
Articles
57
Tags
15
Categories
8
Stanley Zheng
Home
Archives
Tags
Categories
LogoStanley's BlogReading Notes for SGLang
Search
Stanley Zheng
Home
Archives
Tags
Categories

Reading Notes for SGLang

Created2025-05-27|Updated2025-06-11|Reading Paper
|Post Views:
Author: Stanley Zheng
Link: https://s-tanley.github.io/blogs/2025/05/27/SGLang/
Copyright Notice: All articles on this blog are licensed under CC BY-NC-SA 4.0 unless otherwise stated.
MLSys
Previous
Linux 系统硬件信息检查命令总结
本文档总结了在 Linux 系统中查看各种硬件组件信息的常用命令。这些命令通常需要在终端中执行。 CPU 信息 🧠 lscpu: 显示 CPU 架构、核心数、线程数、速度、缓存等详细信息。 lscpu cat /proc/cpuinfo: 查看更详细的 CPU 底层信息,每个逻辑核心都会有条目。 cat /proc/cpuinfo 通过 dmidecode 查看处理器详情 (通常需要 sudo): sudo dmidecode -t processor 内存 (RAM) 信息 💾 free -h: 以人类可读格式显示总内存、已用、可用内存及交换空间情况。 free -h cat /proc/meminfo: 查看详细的内存使用和内核统计信息。 cat /proc/meminfo sudo dmidecode -t memory 或 sudo dmidecode -t 17: 查看每个物理内存条的详细信息,如制造商、型号、序列号、容量、速度、类型 (DDR4)、Rank、是否支持 ECC 等。 sudo dmidecode -t...
Next
Reading Notes for vLLM
This is the reading note for the Efficient Memory Management for Large Language Model Serving with PagedAttention. vLLM is one of the most popular open-source inference serving systems nowadays. Basically, there are two mainstream inference serving systems: one is vLLM, and the other is SGLang. Summary Abstract & Introduction & Background This is a paper about the vLLM, a serving system for inference. The most important idea they propose is PagedAttention. vLLM with the...
Related Articles
2025-04-07
AllReduce & Bucketing
本文主要介绍了 AllReduce 和 Bucketing 分别是什么,和他们之间的联系。 一、AllReduce 是什么? AllReduce 是分布式训练中的一种集体通信操作, 用于在多个 GPU(worker)之间同步张量(通常是梯度)。 典型流程如下: 每个 GPU 独立计算自己的梯度张量(如 grad)。 所有 GPU 通过 AllReduce 操作,将各自的张量求和/平均,获得全局一致的梯度。 每个 GPU 使用这个同步后的梯度更新模型参数。 AllReduce 是数据并行训练中实现模型同步的关键机制。 二、为什么 AllReduce 会成为性能瓶颈? 模型中参数众多,梯度张量数量也很多。 每个张量如果单独 AllReduce,通信次数极多。 小张量通信无法充分利用带宽,且频繁启动通信带来显著延迟(latency)。 三、Bucketing 是什么? Bucketing 是一种优化 AllReduce 通信效率的策略, 将多个小张量合并成一个大 “bucket”,再一次性执行 AllReduce。 核心思想:Batch Small Reduces...
2025-03-28
Reading Notes for FasterMoE
Summary Abstract & Introduction & Background and Challenges 前面又是简单介绍MoE,基本都一样。 这个也是training方向的,说了三个challenges: dynamic load imbalance 在intro里,叫Dynamic expert selection,就也比较明显,就是每次选的experts不一样。 inefficient synchronous execution mode 在intro里,叫Inefficient synchronous operations,就是expert有dependency,就需要别的worker的data,要等。 congested all-to-all communication 在intro里,叫Mismatch of model design and network topology,感觉他的意思是现在的system只管摆放experts的computation...
2025-04-07
MoE 中 All-to-All 通信机制
本文主要介绍了 All-to-All 通信机制,以及为什么需要这个机制。 一、All-to-All 是什么? 在分布式 Mixture-of-Experts(MoE)模型中,All-to-All 是一种通信操作, 用于在多个 GPU 之间交换 token 和专家(Expert)之间的数据。 每个 GPU 上都有输入 token,而每个 Expert 分布在多个不同的 GPU 上。 Gate 网络决定每个 token 应该由哪些专家处理,因此 token 需要被动态发送到目标 Expert 所在的 GPU。 这正是 All-to-All:每个 GPU 既向其他 GPU 发送数据,也接收来自其他 GPU 的数据。 二、为什么 MoE 模型需要 All-to-All? 1. Expert 是独立的,但 Token 是全局的 每个 Expert 的参数是本地的,只存在于某个 GPU 上。 但 token 是通过数据并行划分的,分布在所有 GPU 上。 每个 token 的 gate 结果可能指向任意 GPU 上的 Expert。 因此,token 必须被跨设备发送到它所选中的...
2025-05-15
Reading Notes for Orca
This is the reading notes for the ORCA: A Distributed Serving System for Transformer-Based Generative Models. This is an OSDI conference paper from 2022. Almost all the authors come from South Korea, and actually, this is the first time I have read papers written by Koreans. Summary Abstract & Introduction & Background The paper is focused on the inference serving, they point out that the existing system is not good enough for transformer-based models. So, they propose a new method...
2025-06-10
Resource I Have for MLSys
This is like a guidance page for the resources I know for MLSys, I’ll give a brief introduction to each of them and list the link here. The resources will contain books, papers, and notes I wrote. Books AI System This book is more about the hardware. I think it’s a little bit like for ECE students. I haven’t read it all yet, but I think you can find some useful topics here, such as the introduction to Nvidia GPUs, the Tensor Core, stream multiprocessors, and how the GPU actually do to...
2025-03-27
Reading Notes for SmartMoE
Summary Abstract & Introduction & Background and Motivation Deep neural network(DNN)现在越来越大,除了dense model,就是比较传统的model之外,越来越多的人开始关注sparsely activated model。针对dense model,之前有很多auto-parallelization的方法,但是这些方法对sparsely activated model,比如说MoE架构的模型就没那么好用了。所以他们主要做的就是实现对sparsely activated model做自动并行的分布式训练的方法。 Intro就先说一下来龙去脉,就众所周知,scaling law目前对DNN一直没有失效,所以各家基本上就是一直往上堆参数。但模型变大了就练不动了,所以就要找efficient...

Comments
GiscusUtterances
avatar
Stanley Zheng
Hi, I am Stanley. I am currently a CS student in the University of Wisconsin-Madison.
Articles
57
Tags
15
Categories
8
Follow Me
Announcement
This is my Blog
Recent Posts
Notes---Operating Systems: Three Easy Piece---Concurrency(UW-Madison CS 537)2025-10-22
Notes---Operating Systems: Three Easy Piece---Persistence(UW-Madison CS 537)2025-10-22
Statistics---Why We Use the t-Distribution to Estimate the Population Mean2025-10-15
Statistics---Sufficiency2025-10-14
Statistics---克拉默-拉奥下限(Cramér-Rao Lower Bound, CRLB)2025-10-14
©2019 - 2025 By Stanley Zheng
Framework Hexo 7.3.0|Theme Butterfly 5.3.5
Search
Loading Database