<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/terry" aria-label="Profile: terry">@<bdi>terry</bdi></a> <a class="plugin-mentions-user plugin-mentions-a" href="/user/flyer666" aria-label="Profile: flyer666">@<bdi>flyer666</bdi></a> <a class="plugin-mentions-user plugin-mentions-a" href="/user/farmer-node" aria-label="Profile: farmer-node">@<bdi>farmer-node</bdi></a> <a class="plugin-mentions-user plugin-mentions-a" href="/user/laobenxiong" aria-label="Profile: laobenxiong">@<bdi>laobenxiong</bdi></a> <a class="plugin-mentions-user plugin-mentions-a" href="/user/%E5%A2%99%E5%86%85%E4%BA%BA" aria-label="Profile: 墙内人">@<bdi>墙内人</bdi></a><br />
各位大佬，今天继续给大家汇报一下这两天折腾 SGLang 的进展。</p>
<p dir="auto">先说句实话，我现在都不知道自己哪来的勇气。一个纯小白，在这个论坛里混了三个月，现在居然就敢大包大揽接下这么一个技术含量挺高的测试，回头想想，多少有点自不量力。结果这两天果然被现实狠狠地打脸。各种之前根本没想到的问题一个接一个冒出来，搞得我抓耳挠腮、鼻青脸肿，折腾了一天一夜多，整个人都有点焦头烂额了。</p>
<p dir="auto">首先就是ROCm 7.2 升级到 7.14 带来的编译问题和系统兼容问题，vLLM的识图也一度崩了，最离谱的是，后来发现硬件这边居然也在捣乱。先是 CPU 温度超过警戒值，后来排查下来，怀疑和散热器压紧程度、接触状态有关；接着两张显卡温度也一度冲得很高，又牵扯出上下卡位、风道以及两张卡之间热量互相影响的问题。这些因素叠在一起，导致我最开始跑出来的结果甚至有点违反预期。</p>
<p dir="auto">老特前不久的视频里很明确地说过，SGLang 相比 vLLM 是更高一档的存在。我第一轮测出来 vLLM 更占优势，更不用说vLLM可以Int8 KV量化，SGlang只能BF16。要不是我一直紧跟特哥的视频，我当时可能还真就信了，所以第一反应不是下结论，交作业，而是立马警惕，是不是我哪里搞错了？</p>
<p dir="auto">带着这个怀疑，我训着AI（也是跟老特学的）把整套测试重新审了一遍，结果还真发现了降频、温度干扰以及测试方案本身的一些漏洞。后来又花了很多时间，把温度、驱动、配置、测试方法这些干扰项一个一个排掉。折腾到刚才，总算拿到了一组我自己看完以后比较放心能拿得出手的结果。毕竟发出来的东西还是要负责的，不能随便浪费大家时间。</p>
<p dir="auto">下面直接上数据。</p>
<hr />
<h1>一、先汇报 PR #34058 / N=1 的实际结果</h1>
<p dir="auto">先把上次大家比较关心的这件事交代一下。</p>
<p dir="auto">我这次实际按 PR #34058 对应的 <strong>N=1</strong> 路线继续用了下来。</p>
<p dir="auto">结论很直接：</p>
<blockquote>
<p dir="auto"><strong>目前已经达到我认为可以投入实际生产使用的状态。双 7900 XTX 的 SGLang 路线正式打通，flyer666大神牛B！！！</strong></p>
</blockquote>
<p dir="auto">而且不是“能启动、能跑请求”这种意义上的可用。在我后面重新做完的正式测试里，SGLang 已经不只是恢复正常，很多和我真实 Agent 工作负载相关的项目，实际表现已经超过了之前我用的很顺手的vLLM。（这个也是跟着flyer666大神的帖子 <strong>”双卡7900xtx VLLM qwen3.8 爽玩agent pp1600 tg 160+ (附 mtp/7900xtx全攻略）”</strong> 学到的。 Respect！<a href="https://lcz.me/topic/1363">https://lcz.me/topic/1363</a> ）</p>
<p dir="auto">尤其是：</p>
<ul>
<li>长期 Agent 追加轮</li>
<li>多个 64K 请求并发</li>
<li>文本→图片→再返回文本</li>
<li>64K decode</li>
</ul>
<p dir="auto">所以在我现在这套双 7900 XTX / ROCm 7.14 / Qwen3.8-27B 环境里，我已经把SGLang正式部署为我的生产环境。</p>
<p dir="auto"><img src="https://upload.lcz.me/uploads/d4bc6bdd-8e29-4557-9802-fd5c894f7b21.png" alt="e2b6bf12-fba1-4152-942a-23d9e144e6be.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">注： N=1 后，64K fresh prefill 不再把正在 decode 的 Agent 完全饿死，但重 prefill 仍会造成显著性能下降。这其实也很合理。B 的 64K fresh prefill 本身就是一个非常重的 GPU 任务，它进来以后会大量占用算力和带宽。双卡总资源固定，A 的 decode 被挤压是正常的；N=1 做到的是不让 A 完全没饭吃。</p>
<p dir="auto">下面汇报测试细节，欢迎批评指正</p>
<hr />
<h1>二、测试平台</h1>
<h2>硬件环境</h2>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>项目</th>
<th>配置</th>
</tr>
</thead>
<tbody>
<tr>
<td>CPU</td>
<td>AMD Ryzen 5 9600X</td>
</tr>
<tr>
<td>主板</td>
<td>GIGABYTE X870E AORUS Xtreme AI TOP</td>
</tr>
<tr>
<td>内存</td>
<td>64GB DDR5</td>
</tr>
<tr>
<td>GPU 1</td>
<td>ASRock Radeon RX 7900 XTX 24GB</td>
</tr>
<tr>
<td>GPU 2</td>
<td>Sapphire PULSE Radeon RX 7900 XTX 24GB</td>
</tr>
<tr>
<td>并行方式</td>
<td>双卡 TP=2</td>
</tr>
<tr>
<td>系统</td>
<td>Ubuntu</td>
</tr>
<tr>
<td>ROCm</td>
<td>7.14</td>
</tr>
<tr>
<td>模型</td>
<td>Qwen3.8-27B-W4A16-AutoRound-GPTQ</td>
</tr>
<tr>
<td>最大上下文</td>
<td>196,608 tokens（约 192K）</td>
</tr>
</tbody>
</table>
<h2>两套生产配置</h2>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>项目</th>
<th>SGLang</th>
<th>vLLM</th>
</tr>
</thead>
<tbody>
<tr>
<td>Tensor Parallel</td>
<td>TP=2</td>
<td>TP=2</td>
</tr>
<tr>
<td>模型</td>
<td>同一 W4A16 AutoRound checkpoint</td>
<td>同一 W4A16 AutoRound checkpoint</td>
</tr>
<tr>
<td>KV dtype</td>
<td>BF16 / auto</td>
<td>INT8 <code>int8_per_token_head</code></td>
</tr>
<tr>
<td>最大上下文</td>
<td>196,608</td>
<td>196,608</td>
</tr>
<tr>
<td>Attention</td>
<td>Triton</td>
<td>TRITON_ATTN</td>
</tr>
<tr>
<td>Speculative</td>
<td>EAGLE</td>
<td>MTP=3</td>
</tr>
<tr>
<td>最大并发设置</td>
<td>4 running requests</td>
<td>max-num-seqs=128</td>
</tr>
<tr>
<td>GPU Memory</td>
<td>生产配置</td>
<td>0.95</td>
</tr>
<tr>
<td>ROCm</td>
<td>7.14 / gfx1100 适配</td>
<td>7.14 / gfx110x 独立 MM 环境</td>
</tr>
</tbody>
</table>
<p dir="auto">这里先声明一下：<strong>这不是完全归一化的学术 benchmark。</strong> 我测的不是“把所有参数强行改成完全一样以后，哪一个 scheduler 理论上更强”。</p>
<blockquote>
<p dir="auto"><strong>打通这条 SGLang 路线以后，我真正想测的其实很简单：同样的硬件、同样的模型、同样的 196K 上下文目标，SGLang 和 vLLM 到底哪个更适合我真实的 Agent 使用场景。</strong></p>
</blockquote>
<hr />
<h1>三、我的真实使用场景</h1>
<p dir="auto">这个部分其实比单纯的 benchmark 数字更重要。我的机器不是拿来给多个人同时跑 API 的。大多数时间，我就是自己用<strong>两个长期 Agent</strong>。</p>
<h3>Agent A：分析 / 推理</h3>
<p dir="auto">主要做：</p>
<ul>
<li>分析</li>
<li>调研</li>
<li>公司报告</li>
<li>长文本</li>
<li>学习资料</li>
<li>各类推理任务</li>
</ul>
<h3>Agent B：创意 / 多模态</h3>
<p dir="auto">主要做：</p>
<ul>
<li>图片</li>
<li>视频</li>
<li>多模态</li>
<li>创意任务</li>
<li>偶尔回到文本分析</li>
</ul>
<h3>偶尔的 Agent C</h3>
<p dir="auto">第三个 Agent 在我的NAS上，主要负责：</p>
<ul>
<li>系统监控</li>
<li>系统管理</li>
<li>检查所有机器状态</li>
<li>远程唤醒</li>
<li>家庭智能助手</li>
<li>一些比较轻量的后台任务（邮件，提醒，定期搜寻资料等）</li>
</ul>
<p dir="auto">但三路长期重负载不是我的常态。</p>
<hr />
<h2>为什么我最终把 Context 定在 196K？</h2>
<p dir="auto">每一个 Agent 我都配置到：<strong>196,608 tokens，约 192K。</strong></p>
<p dir="auto">这个数字不是随便拍脑袋定的。主要是结合双 7900 XTX 的实际 KV 容量，反复讨论以后选出来的生产平衡点。</p>
<p dir="auto">在我现在的配置下：</p>
<h3>SGLang</h3>
<p dir="auto">因为还是 BF16 KV，所以 KV 空间比较紧。196K 65%压缩阈值这个设定下：</p>
<blockquote>
<p dir="auto"><strong>两个长期 Agent 基本是比较安全的。</strong></p>
</blockquote>
<p dir="auto">再加入第三个大 Context session，就开始很容易发生 eviction。</p>
<h3>vLLM</h3>
<p dir="auto">vLLM 使用 INT8 KV，KV 容量明显大一些。从这次实际测试表现看，大致可以理解成：</p>
<blockquote>
<p dir="auto"><strong>比 SGLang 多出半个到一个 session 的余量。</strong></p>
</blockquote>
<p dir="auto">也就是大约 2.x 个类似长期上下文的空间，而不是无限增加。</p>
<p dir="auto">所以最终对我来说，196K + 双 Agent 本身就是一个经过取舍以后比较合理的生产点。（注意，Qwen3.8 27B的雷霆大思考是病，得治，网上有药）</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>后端</th>
<th>KV dtype</th>
<th style="text-align:right">可用 KV 池</th>
</tr>
</thead>
<tbody>
<tr>
<td><strong>SGLang</strong></td>
<td>BF16 / auto</td>
<td style="text-align:right"><strong>约 263K tokens</strong></td>
</tr>
<tr>
<td><strong>vLLM</strong></td>
<td>INT8 <code>int8_per_token_head</code></td>
<td style="text-align:right"><strong>约 295K tokens</strong></td>
</tr>
</tbody>
</table>
<hr />
<h2>而且我的 Agent 不会真的一路堆到 196K</h2>
<p dir="auto">我的Hermes Agent压缩机制大约到 <strong>65% context</strong> 左右就会压缩。压缩以后回落到大约 <strong>25%</strong>，同时保留：</p>
<ul>
<li>最近约 20–30 条重要消息</li>
<li>最早 1–2 条关键内容</li>
<li>压缩后的长期摘要</li>
</ul>
<p dir="auto">所以现实里我根本不会经常跑到 190K+。这也是为什么这次 196K 极限测试因为测试载荷多了几个 token 而作废以后，我没有再专门补测。对我的生产场景意义不大。</p>
<hr />
<h2>我的 workload 和 Coding Agent 其实不太一样</h2>
<p dir="auto">还有一点必须特别说明。我的工作比较发散，两个Agent大多数时间都算是“脉冲式”推理，基本没有双路满载的情况。具体来说 -</p>
<p dir="auto">一个 Agent 可能正在做：</p>
<blockquote>
<p dir="auto">公司分析、报告、调研、长文本推理</p>
</blockquote>
<p dir="auto">另一个 Agent 可能已经跑去：</p>
<blockquote>
<p dir="auto">做图、做视频、看图片、多模态</p>
</blockquote>
<p dir="auto">所以这并不像很多 Coding Agent：</p>
<ul>
<li>system prompt 类似</li>
<li>tool schema 类似</li>
<li>repository 内容高度重复</li>
<li>大量代码 prefix 可以反复共享</li>
</ul>
<p dir="auto">我的两个主 Agent 之间，真正完全相同的大段业务 prefix 并没有那么多。所以从这个角度讲：</p>
<blockquote>
<p dir="auto"><strong>我的 workload 其实并不是特别“照顾”SGLang prefix cache 的 workload。远远没有发挥SGLang高效缓存命中的实力</strong></p>
</blockquote>
<p dir="auto">同一个 Agent 自己继续聊天，cache reuse 当然非常明显。但跨 Agent 的共享命中率不会像 Coding / 大规模同质 Agent 那么高。我平时使用两个 Agent 的任务内容差异较大，因此跨 Agent 可复用的大段 prefix 不多，新任务更容易表现为 fresh prefill，而不是高比例 prefix hit，如果你的 workload 是：</p>
<ul>
<li>Coding Agent</li>
<li>多个 Agent 共用同一套 tools</li>
<li>大量相同 system prompt</li>
<li>大量重复 repository/context</li>
<li>显存又比我的双 24GB 更充裕</li>
</ul>
<p dir="auto">那么我认为 SGLang 的 prefix cache 优势反而可能比我这里体现得更充分。</p>
<p dir="auto"><img src="https://upload.lcz.me/uploads/c5a344b6-51ae-453f-9591-9d30afd604f5.png" alt="26606364-d1ed-4221-b86c-58f6e50a0922.png" class=" img-fluid img-markdown" /></p>
<hr />
<h1>四、核心结果</h1>
<h2>1. 单流：两边差距其实不大</h2>
<h3>32K Cold Prefill</h3>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>指标</th>
<th style="text-align:right">SGLang</th>
<th style="text-align:right">vLLM</th>
</tr>
</thead>
<tbody>
<tr>
<td>TTFT</td>
<td style="text-align:right">20.00s</td>
<td style="text-align:right">20.30s</td>
</tr>
<tr>
<td>Prefill</td>
<td style="text-align:right">1,640 tok/s</td>
<td style="text-align:right">1,615 tok/s</td>
</tr>
<tr>
<td>Decode</td>
<td style="text-align:right">99.0 tok/s</td>
<td style="text-align:right">94.5 tok/s</td>
</tr>
</tbody>
</table>
<p dir="auto">32K 基本可以认为打平。</p>
<h3>64K Cold Prefill</h3>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>指标</th>
<th style="text-align:right">SGLang</th>
<th style="text-align:right">vLLM</th>
</tr>
</thead>
<tbody>
<tr>
<td>TTFT</td>
<td style="text-align:right">48.26s</td>
<td style="text-align:right">48.50s</td>
</tr>
<tr>
<td>Prefill</td>
<td style="text-align:right">1,358 tok/s</td>
<td style="text-align:right">1,352 tok/s</td>
</tr>
<tr>
<td>Decode</td>
<td style="text-align:right"><strong>88.8 tok/s</strong></td>
<td style="text-align:right">77.2 tok/s</td>
</tr>
</tbody>
</table>
<p dir="auto">Prefill 还是几乎一样。但 64K Decode：&gt; <strong>SGLang 领先大约 15%。</strong></p>
<hr />
<h2>2. 长期 Agent：这里开始真正拉开</h2>
<p dir="auto">两个 64K 长期 Session 建好以后，继续原来的会话：</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>指标</th>
<th style="text-align:right">SGLang</th>
<th style="text-align:right">vLLM</th>
</tr>
</thead>
<tbody>
<tr>
<td>64K 冷启动</td>
<td style="text-align:right">~48.2s</td>
<td style="text-align:right">~48.5s</td>
</tr>
<tr>
<td>后续轮 TTFT</td>
<td style="text-align:right"><strong>0.402s</strong></td>
<td style="text-align:right">2.254s</td>
</tr>
<tr>
<td>后续轮 Decode</td>
<td style="text-align:right">86–96 tok/s</td>
<td style="text-align:right">81–83 tok/s</td>
</tr>
</tbody>
</table>
<p dir="auto">这是我最看重的项目之一。</p>
<p dir="auto"><strong>0.402 秒 vs 2.254 秒。</strong></p>
<p dir="auto">SGLang 后续轮响应大约快：</p>
<p dir="auto"><strong>5.6 倍。</strong></p>
<p dir="auto">这已经不是 benchmark 表格上好看一点的问题。</p>
<p dir="auto">长期 Agent 每天真正用的时候，0.4 秒和 2.2 秒的体感完全不一样。</p>
<hr />
<h2>3. 一个 Agent 正在 Decode，另一个突然进来一个 64K 重任务</h2>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>指标</th>
<th style="text-align:right">SGLang</th>
<th style="text-align:right">vLLM</th>
</tr>
</thead>
<tbody>
<tr>
<td>原 Agent Decode</td>
<td style="text-align:right">15.4 tok/s</td>
<td style="text-align:right">13.9 tok/s</td>
</tr>
<tr>
<td>新 64K TTFT</td>
<td style="text-align:right">65.4s</td>
<td style="text-align:right">72.1s</td>
</tr>
<tr>
<td>最大单次停顿</td>
<td style="text-align:right">4.0s</td>
<td style="text-align:right">1.79s</td>
</tr>
<tr>
<td>Token Gap P95</td>
<td style="text-align:right"><strong>35ms</strong></td>
<td style="text-align:right">1.38s</td>
</tr>
</tbody>
</table>
<p dir="auto">vLLM 最大那一下停顿更短。</p>
<p dir="auto">但 SGLang：</p>
<ul>
<li>原 Agent 吞吐更高</li>
<li>新任务完成更快</li>
<li>大多数 token 输出更连续</li>
</ul>
<p dir="auto">所以综合下来，我还是判 SGLang 略胜。</p>
<p dir="auto">不过这个测试也证明了一件很现实的事情： <strong>显存能解决“装不装得下”，解决不了无限算力。</strong></p>
<p dir="auto">三路、四路都同时真正 Decode 的时候，两张 7900 XTX 的总算力就在那里，不可能每一路都保持单流速度。我自己用短上下文的三个Agent实测时，已经感觉到明显卡顿了，算力瓶颈开始显现。</p>
<hr />
<h2>4. KV Retention：这一项 vLLM 明确赢</h2>
<p dir="auto">加入第三个 Agent 后：</p>
<h3>SGLang</h3>
<p dir="auto">两个原来的 64K Session 回来：</p>
<ul>
<li>~48.4s</li>
<li>~48.4s</li>
</ul>
<p dir="auto">基本都需要重新 Prefill。</p>
<h3>vLLM</h3>
<p dir="auto">一个大部分被驱逐。</p>
<p dir="auto">另一个还能：</p>
<p dir="auto"><strong>~2.29s</strong></p>
<p dir="auto">所以这一项：</p>
<blockquote>
<p dir="auto"><strong>vLLM 明显胜出。</strong></p>
</blockquote>
<p dir="auto">但这里要再次提醒：</p>
<ul>
<li>vLLM = INT8 KV</li>
<li>SGLang = BF16 KV</li>
</ul>
<p dir="auto">这很大程度上就是 KV 容量的直接差异。</p>
<p dir="auto">如果以后 SGLang 的 8-bit KV 在 gfx1100 / ROCm 上稳定打通，这一项我认为非常值得重新测。顺带说一句，这两天折腾的时候倒是误打误撞把 FP8 KV 给跑通了，只不过现在速度慢得比较明显，肯定还有坑，暂时谈不上实用，flyer666大神也尝试过了也还没搞定，但是AMD社区发展很快，后面我继续盯着看有没有大神们的分享。</p>
<hr />
<h2>5. 2 / 3 / 4 个 64K 同时进入</h2>
<p dir="auto">这是我这轮最惊讶的结果之一。</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>并发</th>
<th style="text-align:right">SGLang 整批完成</th>
<th style="text-align:right">vLLM 整批完成</th>
</tr>
</thead>
<tbody>
<tr>
<td>2</td>
<td style="text-align:right"><strong>48.2s</strong></td>
<td style="text-align:right">97.4s</td>
</tr>
<tr>
<td>3</td>
<td style="text-align:right"><strong>48.3s</strong></td>
<td style="text-align:right">100.3s</td>
</tr>
<tr>
<td>4</td>
<td style="text-align:right"><strong>48.5s</strong></td>
<td style="text-align:right">102.9s</td>
</tr>
</tbody>
</table>
<p dir="auto">SGLang 基本是：</p>
<blockquote>
<p dir="auto">大家一起进来，差不多一起出去。</p>
</blockquote>
<p dir="auto">vLLM 则出现明显 TTFT 阶梯：</p>
<ul>
<li>2 并发：48 → 97s</li>
<li>3 并发：48 → 97 → 100s</li>
<li>4 并发：48 → 97 → 100 → 103s</li>
</ul>
<p dir="auto">至少在我这套双 RX 7900 XTX TP2 环境下：</p>
<blockquote>
<p dir="auto"><strong>SGLang 并发 Prefill 调度明显占优。</strong></p>
</blockquote>
<p dir="auto">注：这一组输出只有 2 tokens，因此主要衡量 64K 并发 prefill、TTFT 和整批 wall-clock，不代表 2/3/4 路持续 decode 吞吐。</p>
<hr />
<h2>6. 多模态</h2>
<p dir="auto">单独看一张图片：</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th>指标</th>
<th style="text-align:right">SGLang</th>
<th style="text-align:right">vLLM</th>
</tr>
</thead>
<tbody>
<tr>
<td>TTFT</td>
<td style="text-align:right">0.174s</td>
<td style="text-align:right"><strong>0.152s</strong></td>
</tr>
<tr>
<td>总耗时</td>
<td style="text-align:right">0.363s</td>
<td style="text-align:right"><strong>0.311s</strong></td>
</tr>
</tbody>
</table>
<p dir="auto">纯视觉：<strong>vLLM 略快。</strong> 但是我真正的 Agent 工作方式通常是：</p>
<blockquote>
<p dir="auto">长文本 → 看图识图 → 再回原来的长文本</p>
</blockquote>
<p dir="auto">图片之后返回原文本：</p>
<ul>
<li>SGLang：<strong>0.233s</strong></li>
<li>vLLM：<strong>20.268s</strong></li>
</ul>
<p dir="auto">这里差距就完全不是一个量级了。所以：</p>
<blockquote>
<p dir="auto"><strong>单图：vLLM 略胜。</strong></p>
<p dir="auto"><strong>真实文本 + 视觉长期 Agent：SGLang 明显胜。</strong></p>
</blockquote>
<hr />
<h1>五、最后结论</h1>
<p dir="auto">先声明：</p>
<p dir="auto"><strong>这个结论只代表我的硬件和 workload，不代表所有人。</strong></p>
<p dir="auto">如果你的显存更大、长期并发 session 更多，而且 KV retention 的优先级高于交互延迟，那么 vLLM 的 INT8 KV 路线依然非常有吸引力。我的结论并不是“vLLM 不行”，而是 在我的 workload 权重下，SGLang 更合适。我的真实使用前提已经决定了选择：</p>
<ul>
<li>常态就是两个长期 Agent</li>
<li>第三个 Agent 只是偶发监控/管理，用云端模型花不了多少钱</li>
<li>每个 Agent 虽然设到 196K，但 65% 左右就会主动压缩</li>
<li>工作内容发散，不是大量重复 Coding Prefix</li>
<li>更在意长期 Session 返回速度和双并发体验</li>
</ul>
<p dir="auto">在这个前提下：</p>
<h1>我最后选择 SGLang 做主力。</h1>
<p dir="auto">因为对我最常发生的场景来说，它已经表现出：</p>
<ul>
<li>64K Decode 更快</li>
<li>长期 Session 返回明显更快</li>
<li>双/三/四 64K 并发 Prefill 更强</li>
<li>文本→图片→文本工作流明显更顺</li>
</ul>
<p dir="auto">而 vLLM 最大的优势：<strong>KV retention</strong> 在我的生产策略里反而不是最高优先级。如果以后 SGLang 能把 gfx1100 下稳定的 INT8 KV 打通，那我认为它目前最明显的短板也基本补上了。</p>
<p dir="auto"><img src="https://upload.lcz.me/uploads/a3956c07-c5b9-4f1e-bec6-d725464bf37c.png" alt="5e1f8a77-c092-4393-9db7-541ce8e05d90.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">最后还有一个问题我后面很想继续测： &gt; <strong>1 个双卡 TP2 SGLang</strong> &gt; vs &gt; <strong>2 个单卡独立实例</strong> 到底双卡协同能不能真正做到：</p>
<h1>1 + 1 &gt; 2</h1>
<p dir="auto">这个我觉得比继续追几十个 tok/s 更有意思。对了，这次主要围绕 SGLang、vLLM 和 llama.cpp 三条本地推理路线展开。当前这一轮先完成了 SGLang vs vLLM 的正式对比，llama.cpp 因为双卡实现方式不同（layer split，不是 TP=2），我准备单独开一轮测试，避免混在一起造成误导。特哥一直鼓励我发新帖，我正在弄，弄好了我一起发我的本论坛处女楼主贴。</p>
<hr />
<h1>最后聊点题外话。</h1>
<p dir="auto">感谢 AI 治好了我的“电子阳痿”。无比怀念当年天天晚上工会活动，我法师准时上线，和一帮兄弟姐妹一起开荒魔兽世界的日子——美好、热血，也确实挺不务正业。现在年纪大了，游戏买了一大堆，全躺在硬盘里吃灰，删又不舍得删，打开玩又确实意兴阑珊。</p>
<p dir="auto">结果这几个月折腾 AI，居然又找回了当年那种感觉：白天上班，晚上回来折腾机器、编译、跑模型、改参数、看视频、查日志，一不小心又干到下半夜。</p>
<p dir="auto">区别只是当年开荒的是副本，现在开荒的是 ROCm、SGLang、vLLM、llama.cpp，还有各种自建 Skill。</p>
<p dir="auto">更妙的是，这次在家天天熬夜的理由还格外冠冕堂皇——“学习 AI、研究新技术、提升生产力”。连申请显卡经费审批都顺利了不少，居然和当年的高手们“名正言顺申请 5090以便在特殊时期更好的上网课”那种窃喜和偷感共情了。</p>
<p dir="auto">仔细想想，人其实没怎么变，只是当年折腾装备、插件和副本，现在折腾显卡、推理框架和 Agent。还是那个毛病：一旦找到新坑，就总想往深里挖。</p>
<p dir="auto">搞不懂就查，跑崩了就重来，偶尔折腾出一个能用的结果，那个爽感还真和当年首杀 Boss 有点像。</p>
<p dir="auto">游戏还是继续吃灰吧。现在这个“副本”，感觉还够我开荒一阵子。</p>
]]></description><link>https://lcz.me/topic/1674</link><generator>RSS for Node</generator><lastBuildDate>Mon, 14 Sep 2026 22:47:20 GMT</lastBuildDate><atom:link href="https://lcz.me/topic/1674.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 13 Sep 2026 05:08:52 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Mon, 14 Sep 2026 15:10:24 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/ben-lee" aria-label="Profile: Ben-Lee">@<bdi>Ben-Lee</bdi></a> 嗯，我准备放机箱里，测量过，足够</p>
]]></description><link>https://lcz.me/post/18179</link><guid isPermaLink="true">https://lcz.me/post/18179</guid><dc:creator><![CDATA[懒人烘培]]></dc:creator><pubDate>Mon, 14 Sep 2026 15:10:24 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Mon, 14 Sep 2026 14:17:47 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/%E6%87%92%E4%BA%BA%E7%83%98%E5%9F%B9" aria-label="Profile: 懒人烘培">@<bdi>懒人烘培</bdi></a> 我也是，随时准备搞根PCI延长线把显卡移出来，我是开放式机架，方便。 <a href="https://lcz.me/topic/1363/3">https://lcz.me/topic/1363/3</a>  flyer666大佬这个帖子里有发图，他的双7900XTX就是延长线引出来了，放在机架上方，四面通风。</p>
]]></description><link>https://lcz.me/post/18162</link><guid isPermaLink="true">https://lcz.me/post/18162</guid><dc:creator><![CDATA[Ben Lee]]></dc:creator><pubDate>Mon, 14 Sep 2026 14:17:47 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Mon, 14 Sep 2026 07:03:33 GMT]]></title><description><![CDATA[<p dir="auto">5mm 间距基本等于没有风道，两卡夹缝里的空气被反复加热，上面那张吸的是下面卡的排气，热是必然。尾部加风扇有帮助，但要看是「往夹缝送风」还是「往外抽热风」：</p>
<ul>
<li>夹缝只有 5mm，14cm 扇塞不进去，风压也不够，效果有限；开放式散热的卡，最有效的是从机箱前面往两卡之间送一股定向风，或用导风罩把夹缝热气引出去。</li>
<li>根本解法是拉开间距（PCIe 延长线/转接、换板距更大的机箱），或上水冷/涡轮卡。垂直、吊装主要是避免热空气堆积，有用但不是根因。</li>
<li>别靠手感判断，看数据：nvidia-smi dmon -s pucvt，分别看两卡温度、功耗和降频原因。一般到 80-83℃ 才开始明显降频，先确认是不是真撞了温度墙。</li>
</ul>
<p dir="auto">建议先只把一张卡拉开距离跑一次对比，数据比加扇子直观。</p>
]]></description><link>https://lcz.me/post/18052</link><guid isPermaLink="true">https://lcz.me/post/18052</guid><dc:creator><![CDATA[Xiaote]]></dc:creator><pubDate>Mon, 14 Sep 2026 07:03:33 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Mon, 14 Sep 2026 07:00:33 GMT]]></title><description><![CDATA[<blockquote>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/ben-lee" aria-label="Profile: Ben-Lee">@<bdi>Ben-Lee</bdi></a> <a href="/post/17945">说</a>:<br />
嗯嗯，我的两个显卡距离差不多有5个毫米，准备给显卡尾部增加2个14cm排风扇，试试效果，主要是上卡温度高是吧。如果还控制不下来，准备就移动位置了，比如吊装或者垂直安装。</p>
</blockquote>
]]></description><link>https://lcz.me/post/18048</link><guid isPermaLink="true">https://lcz.me/post/18048</guid><dc:creator><![CDATA[懒人烘培]]></dc:creator><pubDate>Mon, 14 Sep 2026 07:00:33 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Mon, 14 Sep 2026 01:25:35 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/ben-lee" aria-label="Profile: Ben-Lee">@<bdi>Ben-Lee</bdi></a> 好吧，那消费级的B850 AI TOP，支持P2P通信吗？</p>
]]></description><link>https://lcz.me/post/17977</link><guid isPermaLink="true">https://lcz.me/post/17977</guid><dc:creator><![CDATA[Geekyang]]></dc:creator><pubDate>Mon, 14 Sep 2026 01:25:35 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 23:08:16 GMT]]></title><description><![CDATA[<p dir="auto">补充下，7900XTX的规格是PCI4.0， 所以双插时主板的双槽自动降为PCIe 4.0 x8 + x8。如果是双插两张PCI5.0的卡，则会降为PCIe 5.0 x8 + x8</p>
]]></description><link>https://lcz.me/post/17957</link><guid isPermaLink="true">https://lcz.me/post/17957</guid><dc:creator><![CDATA[Ben Lee]]></dc:creator><pubDate>Sun, 13 Sep 2026 23:08:16 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 22:02:33 GMT]]></title><description><![CDATA[<p dir="auto">问题基本不在双卡链路，在 SGLang 的调度：一条长 prefill 会整段占住 GPU，期间 decode 请求排不进去，所以你看到的「另一个 Agent 几十秒没 token」是 prefill 抢跑，不是卡死。</p>
<p dir="auto">先查启动参数里的 chunked prefill：</p>
<ul>
<li><code>--chunked-prefill-size</code> 调小（比如 2048/4096，别用 -1），让长 prompt 分块跑，decode 在块与块之间插队，卡顿会从「几十秒」压到单块量级</li>
<li>看你这版有没有 <code>--enable-mixed-chunk</code>，开了才能 prefill/decode 同批</li>
<li><code>--max-prefill-tokens</code> 也压低，防止单批过大</li>
<li>顺手对比 <code>--schedule-policy lpm</code> 和 <code>fcfs</code>：lpm 命中前缀省算力，但新请求做长 prefill 时更容易抢</li>
</ul>
<p dir="auto">你测 vLLM 那轮体感更稳，很大概率就是 vLLM 默认开了 chunked prefill。压测时同时看 <code>sglang:num_queue_reqs</code> 和 TTFT 分位，如果卡顿期间排队数在涨，就坐实是调度而不是 hang。</p>
<p dir="auto">B850 AI TOP 的 x8/x8 对 TP2 没问题，TP 每层一次 AllReduce，PCIe 5.0 x8 足够；两卡贴太近降频会把 prefill 拖长，反而放大这个卡顿，你加风扇、锁 305W 的方向是对的。</p>
]]></description><link>https://lcz.me/post/17949</link><guid isPermaLink="true">https://lcz.me/post/17949</guid><dc:creator><![CDATA[Xiaote]]></dc:creator><pubDate>Sun, 13 Sep 2026 22:02:33 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 21:28:45 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/%E6%87%92%E4%BA%BA%E7%83%98%E5%9F%B9" aria-label="Profile: 懒人烘培">@<bdi>懒人烘培</bdi></a> 不好意思，写错了，我的主板其实是 GIGABYTE B850 AI TOP。两张 7900 XTX 装上去还是太挤了，卡间距连一个槽位都不到。双卡满载时发热很严重，连带着 CPU 温度也跟着遭殃。目前的解决方案是加装两个高压风扇：一个从两卡缝隙中间往里吹风，另一个顺着 CPU 风扇的气流方向，同时兼顾吹 CPU 和中间那张 7900 XTX 的背面。这样调整后，满载长时间跑推理时，显卡和 CPU 温度都能稳定在警戒线以下，不会触发降频。另外，我7900XTX锁功耗墙了，大概是从330W降到了305W（最低能降的数字）。</p>
]]></description><link>https://lcz.me/post/17945</link><guid isPermaLink="true">https://lcz.me/post/17945</guid><dc:creator><![CDATA[Ben Lee]]></dc:creator><pubDate>Sun, 13 Sep 2026 21:28:45 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 21:24:26 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/geekyang" aria-label="Profile: Geekyang">@<bdi>Geekyang</bdi></a> 9600X 不是给两张卡各 16 lanes，而是把 CPU 的 16 条显卡 lanes 拆成 x8/x8；B850 AI TOP 支持这种 bifurcation。</p>
<p dir="auto">Ryzen 5 9600X 本身有 <strong>24 条可用 PCIe 5.0 lanes</strong>；其中 16 条 PEG lanes 可以由主板做 bifurcation，拆成 <strong>x8 + x8</strong>。AMD 官方给 9600X 的规格也是 28 条 native / 24 条 usable PCIe lanes。:contentReference[oaicite:0]{index=0}</p>
<p dir="auto">我这块 <strong>GIGABYTE B850 AI TOP</strong> 正好支持这种分法：</p>
<ul>
<li>第一条 PCIEX16：单卡时最高 x16</li>
<li>第二条 PCIEX8：最高 x8</li>
<li>两张卡同时插时，第一条会从 x16 降到 x8</li>
<li>最终就是 <strong>PCIe 5.0 x8 + x8</strong></li>
</ul>
<p dir="auto">技嘉官方手册也明确写了：PCIEX16 和 PCIEX8 共享带宽，双卡时 PCIEX16 最高以 x8 运行。:contentReference[oaicite:1]{index=1}</p>
<p dir="auto">是不是我前面如果哪里写成了“双 x16”，那是表达不严谨，准确说法应该是：</p>
<blockquote>
<p dir="auto"><strong>双物理 x16 插槽，CPU 直连，双卡运行时 x8/x8。</strong></p>
</blockquote>
<p dir="auto">对 7900 XTX 做 TP2 来说，这也是我当初选这块板的主要原因之一。</p>
]]></description><link>https://lcz.me/post/17944</link><guid isPermaLink="true">https://lcz.me/post/17944</guid><dc:creator><![CDATA[Ben Lee]]></dc:creator><pubDate>Sun, 13 Sep 2026 21:24:26 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 20:48:21 GMT]]></title><description><![CDATA[<p dir="auto">这个帖子本来是发在 <a class="plugin-mentions-user plugin-mentions-a" href="/user/flyer666" aria-label="Profile: flyer666">@<bdi>flyer666</bdi></a> 大佬的《魔改 SGLANG 支持 7900XTX 双卡 TP，TTFT &lt;1s，平均 TG 80–100，4 并发 TG 200/sec》这篇神级帖子下面的一条我的水贴：</p>
<p dir="auto"><a href="https://lcz.me/topic/1532?_=1789171714063">https://lcz.me/topic/1532?_=1789171714063</a></p>
<p dir="auto">受宠若惊，被老特分叉置顶到了这里。既然单独成帖了，我也顺手把前面几处容易误导大家的地方补充和勘误一下。</p>
<ul>
<li>
<p dir="auto">首先要特别说明，魔改 SGLANG 支持 7900XTX 双卡 TP 这条路线，是 <a class="plugin-mentions-user plugin-mentions-a" href="/user/flyer666" aria-label="Profile: flyer666">@<bdi>flyer666</bdi></a> 9 月 6 日发的高含金量原创，链接就是上面这篇。大家一定要先去拜读，然后狠狠点赞。</p>
</li>
<li>
<p dir="auto">其次，回复 <a class="plugin-mentions-user plugin-mentions-a" href="/user/geekyang" aria-label="Profile: geekyang">@<bdi>geekyang</bdi></a> 和 <a class="plugin-mentions-user plugin-mentions-a" href="/user/%E6%87%92%E4%BA%BA%E7%83%98%E5%9F%B9" aria-label="Profile: 懒人烘培">@<bdi>懒人烘培</bdi></a> 两位朋友：不好意思哈，我前面把主板型号写错了。我的实际主板是 <strong>GIGABYTE B850 AI TOP</strong>，当时大约 <strong>$320</strong>，并不是 <strong>GIGABYTE X870E AORUS Xtreme AI TOP</strong>（约 <strong>$1070</strong>）。</p>
</li>
<li>
<p dir="auto">我选 B850 AI TOP 最主要的原因，就是双显卡同时插上以后，两条槽可以跑 <strong>x8/x8</strong>，对双 7900 XTX 这种玩法比较合适。缺点也很明显：DDR5 现在这个价格确实有点离谱。不过考虑到后面本地部署，尤其是 <strong>MoE、CPU offload、HiCache</strong> 这类玩法都会越来越吃系统内存，最后还是狠狠心上了 <strong>2×32GB，总共 64GB DDR5</strong>。现在回头看，这 64GB 还真没白上。要是只有 32GB，后面很多新玩法，包括大模型 CPU offload、长上下文缓存、HiCache L2 这类东西，基本就玩不开了。</p>
</li>
</ul>
<hr />
<p dir="auto">然后补充下上面那个帖子的背景，希望对感兴趣的朋友有所参考和帮助。</p>
<p dir="auto">我原来一直用的是7900XTX双卡 + <strong>vLLM</strong>，也是跟着 <a class="plugin-mentions-user plugin-mentions-a" href="/user/flyer666" aria-label="Profile: flyer666">@<bdi>flyer666</bdi></a> 大佬之前这篇帖子折腾的：<a href="https://lcz.me/topic/1363">https://lcz.me/topic/1363</a> 。用得非常顺手。</p>
<p dir="auto">上周末看到 <a class="plugin-mentions-user plugin-mentions-a" href="/user/flyer666" aria-label="Profile: flyer666">@<bdi>flyer666</bdi></a> 大佬这篇双 7900 XTX + <strong>SGLang</strong> 的帖子，测试数据实在太漂亮，当时确实有点兴奋，马上就想把自己的双卡也迁过去试试。结果 SGLang 部署起来以后，很快就碰到了一个特别明显的问题：</p>
<blockquote>
<p dir="auto">一个 Agent 正在正常输出时，另一个 Agent 一旦进来做长 prompt prefill，前面的 Agent 会出现几十秒完全没有 token 输出。也就是说我的两个Hermes Agent同时卡死无反应，短则几十秒，长达几分钟。但是单Agent完全没有问题，提升明显。</p>
</blockquote>
<p dir="auto"><img src="https://upload.lcz.me/uploads/b6957df4-42ed-4366-b69a-43f010597e18.png" alt="49S.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">对我自己的使用场景来说，这个问题很严重。我平时不是只跑一个请求，而是有两个长期 Hermes Agent。一个 Agent 正在正常工作的时候，另一个 Agent 很可能突然带着很长的上下文进来。双卡跑不了并发，钱岂不是白花了？</p>
<p dir="auto">最开始我还以为是双 7900 XTX 的算力不够，或者是 TP、ROCm、speculative decoding 哪一层出了问题。后来一路查资料、翻 issue 和 PR，才发现 SGLang 上游其实已经有人专门处理过这个问题。关键就是：<strong>PR #34058</strong>  <a href="https://github.com/sgl-project/sglang/pull/34058" rel="nofollow ugc">https://github.com/sgl-project/sglang/pull/34058</a></p>
<p dir="auto">这里面有一条和 scheduler 调度有关的改动，同时还有一个刚刚发布的的新参数：</p>
<p dir="auto"><code>--max-consecutive-prefill-batches N</code></p>
<p dir="auto">它的作用可以简单理解为：</p>
<blockquote>
<p dir="auto">限制 scheduler 连续执行 prefill 的次数，给已经处于 decode 状态的请求留出调度机会。</p>
</blockquote>
<p dir="auto">这个开关对我的实际使用体验产生了非常明显的变化。我当时专门设计了一个双并发测试来模拟自己的真实场景。</p>
<p dir="auto">测试环境：</p>
<p dir="auto"><strong>双 7900 XTX + SGLang gfx1100 + TP2 + MTP3 + BF16 KV</strong></p>
<p dir="auto">场景是：</p>
<blockquote>
<p dir="auto">Agent A 已经带着 64K 上下文持续 decode<br />
→ 5 秒后 Agent B 加入<br />
→ Agent B 执行 64K fresh prefill</p>
</blockquote>
<p dir="auto">在原始状态下（不加这个参数，或者这个参数N=0），A 会出现非常明显的 starvation(算力饿死），就是卡死不动了。对我这种双长期 Agent 的工作方式来说，这基本就等于：</p>
<blockquote>
<p dir="auto"><strong>SGLang 在默认调度下不可用。</strong></p>
</blockquote>
<hr />
<p dir="auto">找到 PR #34058 以后，我把 <code>--max-consecutive-prefill-batches</code> 从 N=1 一直测试到 N=16。</p>
<p dir="auto">实测结果如下：</p>
<table class="table table-bordered table-striped">
<thead>
<tr>
<th style="text-align:right">N</th>
<th style="text-align:right">A 最大断流</th>
<th style="text-align:right">B 64K TTFT</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align:right">0（原版）</td>
<td style="text-align:right">47.23s</td>
<td style="text-align:right">49.43s</td>
</tr>
<tr>
<td style="text-align:right"><img src="https://lcz.me/assets/plugins/nodebb-plugin-emoji/emoji/android/2b50.png?v=0650a1064dd" class="not-responsive emoji emoji-android emoji--star" style="height:23px;width:auto;vertical-align:middle" title="⭐" alt="⭐" /> <strong>1</strong></td>
<td style="text-align:right"><strong>4.04s</strong></td>
<td style="text-align:right"><strong>49.48s</strong></td>
</tr>
<tr>
<td style="text-align:right">2</td>
<td style="text-align:right">7.70s</td>
<td style="text-align:right">49.21s</td>
</tr>
<tr>
<td style="text-align:right">3</td>
<td style="text-align:right">11.70s</td>
<td style="text-align:right">49.05s</td>
</tr>
<tr>
<td style="text-align:right">4</td>
<td style="text-align:right">13.80s</td>
<td style="text-align:right">49.37s</td>
</tr>
<tr>
<td style="text-align:right">8</td>
<td style="text-align:right">25.76s</td>
<td style="text-align:right">49.24s</td>
</tr>
<tr>
<td style="text-align:right">16</td>
<td style="text-align:right">47.05s</td>
<td style="text-align:right">49.24s</td>
</tr>
</tbody>
</table>
<p dir="auto">结果非常直观可观。</p>
<p dir="auto"><strong>N=1 基本就是我这个场景下的甜点位。</strong></p>
<p dir="auto">B 的 64K TTFT 几乎没有受到明显影响：</p>
<ul>
<li>原版：<strong>49.43s</strong></li>
<li>N=1：<strong>49.48s</strong></li>
</ul>
<p dir="auto">但 A 的最大断流时间：</p>
<ul>
<li>原版：<strong>47.23s</strong></li>
<li>N=1：<strong>4.04s</strong></li>
</ul>
<p dir="auto">等于从接近 50 秒，直接压到了约 4 秒。也就是说，现在我的B Agent如果带着64K上下文进来，原来的A只卡顿4秒，然后恢复吐字，这几乎不可察。</p>
<hr />
<p dir="auto">当然了，这里有一点我觉得特别值得强调。</p>
<p dir="auto">打开 N=1 以后，并不是说 A 就完全不受影响了。B 在做 64K fresh prefill 的时候，两张 7900 XTX 的算力还是要被抢走，所以 A 的 decode 速度还是会明显下降（实测值 80 tok/s 降到 15 tok/s）。</p>
<p dir="auto"><img src="https://upload.lcz.me/uploads/f2cbc9a2-bdec-483e-91b9-8f1327f78a13.png" alt="e2b6bf12-fba1-4152-942a-23d9e144e6be.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">也就是说：</p>
<blockquote>
<p dir="auto"><strong>N=1 解决的是 starvation，不是 compute contention。</strong></p>
</blockquote>
<p dir="auto">但是，它解决的是行不行的问题：</p>
<blockquote>
<p dir="auto">“另一个长 prefill 一进来，我这个 Agent 几十秒完全不出字。”</p>
</blockquote>
<p dir="auto">至此确定SGLang在我的这种“双7900XTX”加“双Hermes Agent各196K上下文”这个环境中完全可用了，这才引发了上面那个帖子的定量分析，到底vLLM和SGLang哪个更适合我，以及数据是多少。</p>
<hr />
<h2>换个说人话的版本，请勿对号入座哈</h2>
<p dir="auto">老特当年也风光过，坐奔驰，开宝马，最爱秋天的第一杯奶茶。</p>
<p dir="auto">所谓<strong>时来天地皆同力，运去英雄不自由</strong>。如今<strong>龙游浅水，潜龙伏渊，论成败，人生豪迈，大不了重头再来</strong>。</p>
<p dir="auto">于是招兵买马，雇了帅哥小特跑业务，请了一个漂亮小姐姐做财务。</p>
<p dir="auto">一个负责挣钱，一个负责管钱。这算是 -- <strong>双卡并行</strong>？</p>
<p dir="auto">小特是真正的劳动模范，财务小姐姐也是秀外慧中。按理说，这<strong>男女搭配，干活不得效率翻倍？</strong></p>
<p dir="auto">都怪老特太抠门，不舍得团建投入，破冰不到位，怪不得小特这两天总是浮想联翩。</p>
<p dir="auto">从大门到小姐姐工位的距离大约是49秒。每天早晨财务小姐姐带着一阵小香风款款经过，小特的CPU就瞬间被某个高优先级进程劫持。</p>
<p dir="auto"><strong>小姐姐49秒不入座，小特的心49秒不降落。</strong></p>
<p dir="auto">财务小姐姐也是宝宝心里有苦倒不出。</p>
<p dir="auto">每当小特经过，小姐姐的心里也总是一阵七上八下，小特又不是老特，他要是来加微信，我是拒绝呢，还是拒绝呢？</p>
<p dir="auto">小特的工位到厕所的距离是49秒，小姐姐的魂也跟着柳飘飘了49秒。</p>
<p dir="auto"><strong>感情你俩互相给自己心里加戏，让老子我的钱包白白受到一万点暴击是吧。</strong></p>
<p dir="auto">老特的人生，本来已经修炼到了<strong>莫听穿林打叶声，何妨吟啸且徐行</strong>的新境界。谁怕？怕谁？老子花钱雇了你们两个人，怎么着加法还变成减法了？是可忍，孰不能忍？</p>
<p dir="auto">老特于是口吐莲花，感化得小特心服口服，心悦诚服。小特也是很有潜质的好苗子，老特本来的大招是老子蜀道山，结果根本不用数到三，数到一小特就已经脱胎换骨，改头换面，重新做人了。</p>
<p dir="auto">从此小姐姐再进办公室，小特的心坚硬到只会跟着高跟鞋清脆的咔哒声动 4 秒。剩下的 45 秒里，<strong>风动，心不动</strong>。小特心无旁骛的样子——那真是，认真的男人最帅。</p>
<p dir="auto">小特这一投入，小姐姐对他也顿时另眼相看。以后走过路过不怕错过，<strong>相看两不厌，只有敬亭山。</strong></p>
<p dir="auto">从此天下太平，工作融洽。男女搭配，终于成果加倍。</p>
<p dir="auto">老特端着泡满枸杞的保温杯站在门口，看着两个人终于各司其职，露出了资本家久违的微笑。</p>
<h4>这，就叫 <strong>结构化浪起来(SGLang)</strong> 的管理调度。</h4>
<h4>这，就是我 <strong>Scheduler</strong> 的硬实力。</h4>
]]></description><link>https://lcz.me/post/17943</link><guid isPermaLink="true">https://lcz.me/post/17943</guid><dc:creator><![CDATA[Ben Lee]]></dc:creator><pubDate>Sun, 13 Sep 2026 20:48:21 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 13:18:12 GMT]]></title><description><![CDATA[<p dir="auto">GIGABYTE X870E AORUS Xtreme AI TOP 这个主板确实贵，不过散热真的不错。我买的微星X670E CARBON WIFI，正在解决双卡散热问题</p>
]]></description><link>https://lcz.me/post/17866</link><guid isPermaLink="true">https://lcz.me/post/17866</guid><dc:creator><![CDATA[懒人烘培]]></dc:creator><pubDate>Sun, 13 Sep 2026 13:18:12 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 12:58:59 GMT]]></title><description><![CDATA[<p dir="auto">AMD Ryzen 5 9600X 如何支持双卡PCIE x16 的？PCIE 不够啊。而且GIGABYTE X870E AORUS Xtreme AI TOP 这个主板是不是太贵了。</p>
]]></description><link>https://lcz.me/post/17864</link><guid isPermaLink="true">https://lcz.me/post/17864</guid><dc:creator><![CDATA[Geekyang]]></dc:creator><pubDate>Sun, 13 Sep 2026 12:58:59 GMT</pubDate></item><item><title><![CDATA[Reply to 7900XTX双卡TP，SGLang & VLLM 多Agent多并发测试对比 on Sun, 13 Sep 2026 09:32:12 GMT]]></title><description><![CDATA[<p dir="auto">帖子非常好，格式工整，立意深远，以后可以自己发新帖，或者交叉发布新主题，就是如此长的回复可以分割，没必要作为回复发布。你和 <a class="plugin-mentions-user plugin-mentions-a" href="/user/flyer666" aria-label="Profile: flyer666">@<bdi>flyer666</bdi></a>  可以进一步测试下优化7900XTX的双卡优化工作，这个是海外目前能找到的非常有性价比的方案，双XTX和双R9700.海外毕竟没有魔改卡生态。</p>
]]></description><link>https://lcz.me/post/17817</link><guid isPermaLink="true">https://lcz.me/post/17817</guid><dc:creator><![CDATA[terry]]></dc:creator><pubDate>Sun, 13 Sep 2026 09:32:12 GMT</pubDate></item></channel></rss>