TensorRT Edge-LLM Completes the MLPerf Edge Agentic Benchmark 6.4x Faster on Jetson AGX Thor
https://developer.nvidia.com/blog/tensorrt-edge-llm-completes-the-mlperf-edge-agentic-benchmark-6-4x-faster-on-jetson-agx-thor/📌 【NVIDIA 實測】Jetson AGX Thor 跑 Agentic 推理,TensorRT Edge-LLM 快 6.4 倍
TL;DR:NVIDIA 用 NVFP4 量化、KV cache 重用與樹狀多 token 預測,把邊緣裝置上的 agentic 推理耗時砍到六分之一以下。
當 AI agent 從雲端資料中心走進車輛、機器人與其他邊緣裝置時,一個現實問題隨之浮現:agent 不像 chatbot 只回答單一提示,而是要在有限的記憶體與功耗預算內,一邊選工具、一邊評估結果,一邊在愈來愈長的對話歷史中持續推理。在 MLPerf Inference v6.1 的 Edge Agentic 測試中,NVIDIA 交出的成績是:同一顆 Qwen3.6-27B 模型,在單臺 Jetson AGX Thor Developer Kit 上,把完成時間從 2 小時 37 分壓到 24 分 36 秒。
🤔 邊緣裝置的 Agentic 推理,難在哪裡
MLPerf Edge Agentic 測的是一個 OpenAI 相容的模型端點,分成效能與準確度兩個階段。效能階段會重播真實記錄下來的軟體工程 agent 對話軌跡:模型接收使用者請求、產生工具呼叫、觀察工具結果,再接續同一段對話。整個工作負載包含 20 段對話、共 1,007 個生成回合,輸入長度會隨對話推進持續增長,最終逼近約 23.5K tokens,因此長上下文(long-context)處理能力是這項測試的核心考驗之一。過程中還會用 IoU(Intersection of Union)指標檢查 agent 是否真的按照劇本正確執行。準確度階段則採用 Berkeley Function Calling Leaderboard(BFCL)v4 的單輪提示,關閉推理模式,用來衡量模型是否選對函式、產生合法參數,以及在不需要工具時不亂呼叫工具。
🧩 三個工程手段:量化、快取重用、樹狀預測
NVIDIA 的 TensorRT Edge-LLM 提交版本,讓 Qwen3.6-27B 以 SingleStream 模式在配備 128GB 統一記憶體、MAXN 功耗模式的 Jetson AGX Thor 上運行,用了三項優化:
第一是 NVFP4 量化。邊緣裝置上低批次的 LLM 解碼通常受限於 DRAM 頻寬,縮小權重與激活值的體積能直接降低解碼延遲。這次提交的模型對權重、激活值(含語言模型頭)採用 Jetson AGX Thor 內建 NVIDIA Blackwell GPU 支援的 4-bit 浮點格式 NVFP4,KV cache 則用 FP8。模型體積縮小後,也讓 128GB 統一記憶體能留更多空間給長上下文與推測解碼所需的狀態。
第二是 KV cache 跨回合重用。Agent 對話的每個新請求,幾乎都包含前面全部歷史加上一小段新內容;若不重用快取,每一輪都要重新 prefill 整段歷史,成本隨對話拉長而累積。TensorRT Edge-LLM 會辨識可重用的提示前綴,還原對應的 attention KV 分頁;由於 Qwen3.6 採混合模型架構,runtime 也需一併還原循環狀態,才能正確接續執行,之後只需 prefill 對話新增的部分。
第三是樹狀多 token 預測(tree-based MTP)。一般自迴歸解碼每次只生成一個 token,MTP 則用一個草稿模型一次預測多個未來 token,再由目標模型一次驗證。TensorRT Edge-LLM 沒有只保留單一預測分支,而是把高機率候選組織成一棵樹,目標模型一次前向傳遞驗證多條分支,只要有分支命中就能一次推進多個 token。這次的伺服器設定用了 8 個草稿步驟、每層取前 2 名候選、共 16 節點的驗證樹;這種設計特別適合 function calling,因為工具名稱、JSON 語法等結構高度可預測,樹狀分支則能同時保留參數值的多種可能。
📊 實測數據:52.33 tokens/秒、6.4 倍加速
| 指標 | 結果 |
|---|---|
| 輸出吞吐量 | 52.33 tokens/秒 |
| 首個 token 中位延遲 | 247.12 ms |
| 每輸出 token 中位延遲 | 14.68 ms |
| BFCL 整體準確率 | 87.94% |
作為對照,MLCommons 公布的 llama.cpp 參考版本,同樣在 Jetson AGX Thor 上用 Q4_K_M 量化跑 Qwen3.6-27B,完成整個工作負載耗時 2 小時 37 分;TensorRT Edge-LLM 僅用 24 分 36 秒,快了 6.4 倍。素材也指出,這次負載中約 96% 的提示 token 是靠熱快取served,13.6M 總提示 token 裡只有約 0.5M 需要重新 prefill;相較於 3 步的線性 MTP,樹狀 MTP 額外帶來約 40% 的解碼效能提升。
💡 快取重用與 MTP 是互補關係
值得注意的是,這三項優化解決的是流程中不同階段的瓶頸:KV cache 重用降低的是「生成開始前」的重複計算成本,樹狀 MTP 降低的則是「生成過程中」目標模型的呼叫次數。兩者疊加,才讓整個 agent 軌跡(而非單次請求)的端到端時間大幅縮短,這也呼應了 agentic workload 與單輪 chatbot 推理在效能瓶頸上的本質差異。
🎯 實務啟示
對於要在邊緣裝置部署 agent 的團隊,這份結果指出一條可複製的路徑:先取得官方或社群提供的 NVFP4 校準檢查點(或自行做一次訓練後量化),再確認 runtime 是否支援跨回合 KV cache 重用與樹狀 MTP,而不是只把力氣花在換更大的模型上。NVIDIA 已將此次提交所用的實作開源在 TensorRT Edge-LLM 的 release/0.9.1-mlpinf 分支,包含模型匯出設定、TensorRT 引擎建置指令與 MLPerf client 設定,有興趣的開發者可依文中步驟複現。
🔗 來源
- 標題:TensorRT Edge-LLM Completes the MLPerf Edge Agentic Benchmark 6.4x Faster on Jetson AGX Thor
- 作者/機構:Elizabeth Goodman, NVIDIA Developer
- 連結:https://developer.nvidia.com/blog/tensorrt-edge-llm-completes-the-mlperf-edge-agentic-benchmark-6-4x-faster-on-jetson-agx-thor/
#NVIDIA #EdgeAI #TensorRT #JetsonAGXThor #MLPerf #LLMInference #AgenticAI #Quantization #KVCache #SpeculativeDecoding
原始資料 NVIDIA Developer · 收集於 2026-09-17
摘要原文
AI agents are moving from cloud data centers to vehicles, robots, and other edge devices. Unlike a chatbot that answers a single prompt, an agent works through a sequence of steps. It selects tools, evaluates their results, and continues reasoning within an increasingly long conversation. This workflow places new demands on edge inference. The model must generate tokens quickly, process long shared histories efficiently, and produce valid tool calls within a limited power and memory envelope. In the MLPerf Inference v6.1 Edge Agentic benchmark, NVIDIA TensorRT Edge-LLM ran Qwen3.6-27B on a single NVIDIA Jetson AGX Thor Developer Kit. The system achieved 52.33 tokens per second and completed all 1,007 turns of the performance workload in 24 minutes and 36 seconds, 6.4x faster than the llama.cpp reference submission of 2 hours and 37 minutes. The result uses NVFP4 quantization, tree-based multi-token prediction (MTP), and KV cache reuse. How MLPerf measures end-to-end agentic AI performance MLPerf Edge Agentic measures an OpenAI-compatible model endpoint in two phases: performance and accuracy. The performance phase replays recorded software-engineering agent trajectories. The model receives a user request, generates a tool call, observes the tool result, and continues the same conversation. The workload contains 20 conversations and 1,007 generated turns. Input length grows across turns and reaches approximately 23.5K tokens, making long-context processing an important part of the measurement. Intersection of Union (IoU) based inline accuracy is also measured to ensure the performance phase is running the agent correctly. The accuracy phase uses Berkeley Function Calling Leaderboard (BFCL) v4 prompts with single-turn only and reasoning off to balance accuracy and evaluation time on edge devices. It evaluates whether the model selects the correct function, generates valid arguments, and avoids calling a tool when no tool is required. Figure 1. The MLPerf Edge Agentic workload measures a multi-turn loop in which tool results are added to the conversation before the next model request MLPerf Edge Agentic benchmark results on Jetson AGX Thor The TensorRT Edge-LLM submission used Qwen3.6-27B in SingleStream mode on one Jetson AGX Thor Developer Kit with 128 GB of unified memory at the MAXN power mode.. Metric Result Output throughput 52.33 tokens per second Median time to first token 247.12 ms Median time per output token 14.68 ms BFCL overall accuracy 87.94% Table 1. MLPerf v6.1 NVIDIA Edge Agentic submission result summary The MLCommons Edge Agentic example also publishes a llama.cpp reference run on Jetson AGX Thor, which uses Qwen3.6-27B with Q4_K_M quantization and completes in 2 hours and 37 minutes. The TensorRT Edge-LLM submission completes the workload in 24 minutes and 36 seconds, or 6.4x less time. Figure 2. End-to-end completion time for the MLPerf Edge Agentic performance workload on Jetson AGX Thor Using NVFP4 quantization to accelerate Qwen3.6-27B inference Low-batch LLM decoding on edge platforms is known to be heavily bounded by DRAM bandwidth. Reducing the size of both weights and activations reduces the memory footprint of the kernels and therefore boosts decoding performance. The submitted Qwen3.6-27B model uses NVFP4 for weights and activations, including the language-model head, and FP8 for the KV cache. NVFP4 is a 4-bit floating-point format supported by the NVIDIA Blackwell GPU in Jetson AGX Thor. TensorRT Edge-LLM uses optimized kernels to accelerate the quantized model while maintaining the accuracy required by MLPerf. The smaller model representation also leaves more of the 128 GB unified memory available for the long context, speculative decoding state, and application workloads. Developers can start from a published, calibrated Qwen3.6-27B NVFP4 checkpoint . A deployment team can use a published quantized checkpoint or perform post-training quantization once on any development system before deploying the model. Reusing KV cache across agent turns Each new request in an agent trajectory contains most of the preceding conversation plus a new model response or tool result. Without reuse, the model must prefill the shared history again on every turn. The cost increases as the conversation grows. TensorRT Edge-LLM identifies reusable prompt prefixes and restores their cached attention KV pages. Qwen3.6 uses a hybrid model architecture, so the runtime also restores the recurrent state and partial KV-page state required to continue execution correctly. It then prefills only the new suffix of the conversation. KV cache and recurrent-state reuse reduce repeated long-context computation across the complete agent trajectory. This optimization complements tree-based MTP: cache reuse reduces the cost before generation begins, while MTP reduces the number of target-model steps during generation. On this workload, ~96% of the prompt tokens are served with hot cache. The runtime only prefills ~0.5M of the total 13.6M prompt tokens across the turns. Using tree-based multi-token prediction to accelerate LLM inference Standard autoregressive decoding generates one token for each model invocation. Multi-token prediction uses a draft model to predict several future tokens, which the target model then verifies together. Recent models typically have official MTP weights trained and shipped together with the main model. In addition to traditional linear MTP, TensorRT Edge-LLM implements a tree-based MTP implementation. Instead of keeping only one predicted continuation, the runtime organizes high-probability candidates into a tree. The target model verifies the candidates in one forward pass, and the runtime accepts the matching path. If multiple candidates are accepted, the system advances generation by several tokens. You can adjust drafting parameters when launching the server. The MLPerf server configuration uses 8 draft steps, the top-2 candidates at each drafting depth, and a 16-node verification tree. Tree-based verification is useful for function calling because tool names, JSON syntax, and common argument structures are often predictable, while multiple branches can preserve likely alternatives for individual argument values. Compared with a linear MTP with 3 draft steps, tree-based MTP could achieve an additional ~40% decoding performance gain for this workload. How to run the MLPerf Edge Agentic benchmark The implementation used for this submission is available on the TensorRT Edge-LLM release/0.9.1-mlpinf branch . The branch includes the model export settings, TensorRT engine build commands, server configuration, and MLPerf client configuration 1. Clone TensorRT Edge-LLM and initialize its submodules. git clone --branch release/0.9.1-mlpinf \ https://github.com/NVIDIA/TensorRT-Edge-LLM.git cd TensorRT-Edge-LLM git submodule update --init --recursive 2. Download the calibrated NVFP4 checkpoint. huggingface-cli download \ centml/Qwen3.6-27B-NVFP4-W4A4-mlpinf \ --local-dir "$WORK/Qwen3.6-27B-NVFP4-W4A4-mlpinf" 3. Follow mlperf/README.md to build TensorRT Edge-LLM, export the checkpoint with the tree-MTP interface, and build the base and draft TensorRT engines. $VENV/bin/python -m tensorrt_edgellm.scripts.export \ "$WORK/Qwen3.6-27B-NVFP4-W4A4-mlpinf" \ "$WORK/onnx" \ --mtp-tree-base --skip-visual 4. Launch the OpenAI-compatible TensorRT Edge-LLM server. export REPO="$PWD" export VENV=/path/to/venv-edgellm-export export WORK=/path/to/mlperf-artifacts bash mlperf/serve_edgellm.sh 5. Clone the MLCommons endpoint harness, install its BFCL dependencies, update the model and tokenizer paths in mlperf/config.yaml , and run the benchmark. git clone https://github.com/mlcommons/endpoints.git cd endpoints python3.12 -m venv .venv source .venv/bin/activate pip install -e ".[dev,bfcl]" inference-endpoint benchmark from-config \ --config "$REPO/mlperf/config.
由 claude-code/sonnet 自動生成