核显跑 Gemma4 全实测:4.6GB 到 26B,五条路线一次看全

独显这么贵,核显到底能不能跑大模型?能跑到多大?我把 Intel Arc 140T(12GB 核显 + 23.5GB 共享内存)折腾了一整天,把 Gemma 4 家族两个代表性模型——E4B 和 supergemma4-26B——从下载、装环境、四后端横评到调显存、服务化、OpenVINO 官方路线全部实测了一遍。结论一句话:核显不仅能跑,26B 都能全量进核显,只是需要一点参数门道。

测试环境:Windows(RDP 远程会话)/ Intel Arc 140T 核显 / 23.5GB 内存 / llama.cpp b10621(Vulkan、SYCL、OpenVINO、CPU 四后端)/ 基准 llama-bench pp512·tg128,8 线程。2026-09-01~02 实测。

两款模型,两种命运

核显没有独立显存,用的是系统内存(共享内存)。能不能跑、跑多快,取决于模型能不能塞进核显可用的显存预算

模型体积参数量定位
gemma-4-E4B-it-Q4_K_M4.62 GiB7.52 BMoE,可整体放入核显
supergemma4-26b-uncensored-fast-v2-Q4_K_M15.63 GiB25.23 B(26B.A4B)MoE 改版,默认显存装不下

E4B 4.6GB 能完整进核显,天生亲核显;26B 是 15.63GB 的大家伙,默认 13.4GB 预算根本装不下——但这也正是这篇最有价值的部分:调显存后 26B 全量 offload 成功

E4B:五后端完整数据

后端参数pp512 (t/s)tg128 (t/s)
Vulkan(核显)-ngl 99380.80 ± 4.1720.34 ± 0.25
SYCL(核显)-ngl 99366.60 ± 2.5416.43 ± 0.01
OpenVINO GPU-ngl 99 -fa 11666.84 ± 13.8712.53 ± 0.09
OpenVINO CPU-ngl 99116.21 ± 4.798.81 ± 0.06
原生 CPU-ngl 084.37 ± 2.4914.92 ± 0.03

三条信息量很大的发现:

  • 生成(tg)最快是 Vulkan 20.3 t/s,第二是 SYCL 16.4,原生 CPU 反而比 OpenVINO CPU 快(14.9 vs 8.8)
  • 预填充(pp)OpenVINO GPU 一骑绝尘:1667 t/s,是 Vulkan 的 4.4 倍、原生 CPU 的 20 倍
  • OpenVINO GPU 生成反而最慢(12.5 t/s)——它是给重 prompt 场景用的,聊天/生成还是 Vulkan 最平衡

26B:调显存前的挣扎

默认共享显存(57%)下核显预算只有 13.4GB,15.63GB 的 26B 全量 offload 全部失败——Vulkan OOM(OutOfDeviceMemory)、SYCL 层数一高就 UR_RESULT_ERROR_OUT_OF_DEVICE_MEMORY、OpenVINO GPU 加载成功但解码报 res=-3。只有 SYCL 部分 offload 能跑,最佳 -ngl 8:

配置pp512 (t/s)tg128 (t/s)
SYCL -ngl 8134.03 ± 8.1617.80 ± 0.09
SYCL -ngl 12130.05 ± 7.6116.78 ± 0.20
SYCL -ngl 16122.70 ± 5.5715.76 ± 0.25
原生 CPU -ngl 062.85 ± 9.8817.39 ± 0.08

注意到没有?层数从 8 加到 16,速度反而更慢——因为溢出到系统内存的部分在拖后腿。调显存前,26B 最好的成绩就是 SYCL 部分 offload 的 pp 134 / tg 17.8。

关键开关:核显共享显存注册表

核显可用的显存预算来自注册表 SystemPartitionCommitLimitPercentage(默认 57)。改到 87 并重启后,Vulkan 预算从 12.67 GiB → 19.73 GiB——26B 终于能整体进核显了:

配置pp512 (t/s)tg128 (t/s)
调显存前 SYCL -ngl 8134.0317.80
调显存后 Vulkan -ngl 99243.62 ± 2.1421.38 ± 0.06
调显存后 SYCL -ngl 99178.80 ± 1.9815.24 ± 0.39

Vulkan 全量 offload 直接登顶:pp 243.6(纯 CPU 的 3.9 倍)、tg 21.4(纯 CPU 的 1.2 倍)。llama-cli 冒烟测试实时生成 ~14.3 t/s(带思考块),完全可日常使用。注册表改法见本站核显共享显存调优一文。

另一条路:OpenVINO GenAI 官方管线

除了 llama.cpp 的 OpenVINO 后端,Intel 还有一条原生 OpenVINO GenAI 管线,直接吃官方预转换的 INT4-AWQ 模型(14.6GB)。我用它跑通了官方原版 26B:

路线pp512 (t/s)tg128 (t/s)特点
llama.cpp Vulkan(GGUF Q4_0)285.3020.04生成快、生态成熟
OpenVINO GenAI(IR INT4-AWQ)50013.7~14.0预填充快 75%、官方权重

同一官方模型、同为 4-bit:预填充 GenAI 快 75%(500 vs 285 t/s),生成 Vulkan 快 46%(20 vs 13.7)。差距来自 MoE 后端的实现差异(Vulkan 有异步专家调度优化),不是参数能调回来的。完整跑通细节见OpenVINO GenAI 官方路线

服务化:26B 常驻成 API

最后把它变成常驻 HTTP 服务(llama-server,OpenAI 兼容 /v1/chat/completions),多轮对话走前缀缓存。实测缓存命中后每轮只算新增 token,第二轮起 prefill 从 1.75s 降到 ~1.2s。不过长上下文有坑:16K 稳定、20K 会触发核显驱动 ErrorDeviceLost,调优方法见20K 长上下文崩溃排查

总结:核显跑模型的完整路线图

  • 8GB 级模型(E4B 等):直接全量 offload,Vulkan 生成最快(20 t/s),重 prompt 用 OpenVINO GPU
  • 16GB 级模型(26B 等):先调注册表共享显存(57→87)再重启,Vulkan 全量 offload 起飞
  • 追求官方权重:OpenVINO GenAI 原生管线吃官方 INT4-AWQ,预填充更快
  • 当服务用:llama-server 常驻 + 前缀缓存,多轮 Agent 只算增量;长上下文注意 -ub 切块
重要提醒:改注册表要重启才生效;预算调高后系统内存余量只剩 ~3GB,稳定性要留意。核显是共享内存,别拿它跟独显比绝对速度,性价比路线才是它的主场。

Discrete GPUs are pricey — can an iGPU actually run LLMs, and how big can they get? I spent a day on an Intel Arc 140T (12GB iGPU + 23.5GB shared RAM) and put two representative Gemma 4 models — E4B and supergemma4-26B — through downloads, environment setup, a five-backend benchmark, VRAM tuning, serving, and the official OpenVINO GenAI route. Bottom line: an iGPU can not only run LLMs, but a full 26B fits entirely in the iGPU — with the right flags.

Env: Windows (RDP) / Intel Arc 140T iGPU / 23.5GB RAM / llama.cpp b10621 (Vulkan, SYCL, OpenVINO, CPU) / llama-bench pp512·tg128, 8 threads. Tested 2026-09-01~02.

Two models, two fates

An iGPU has no VRAM of its own — it borrows system RAM (shared memory). Whether a model runs, and how fast, hinges on whether it fits the iGPU's usable memory budget.

ModelSizeParamsRole
gemma-4-E4B-it-Q4_K_M4.62 GiB7.52 BMoE, fits the iGPU entirely
supergemma4-26b-uncensored-fast-v2-Q4_K_M15.63 GiB25.23 B(26B.A4B)MoE mod; exceeds default VRAM

E4B at 4.6GB fits the iGPU entirely — born iGPU-friendly. The 26B is a 15.63GB beast that the default 13.4GB budget cannot hold — and that is exactly the valuable part here: after tuning VRAM, the full 26B offloads successfully.

E4B: full five-backend numbers

BackendFlagspp512 (t/s)tg128 (t/s)
Vulkan (iGPU)-ngl 99380.80 ± 4.1720.34 ± 0.25
SYCL (iGPU)-ngl 99366.60 ± 2.5416.43 ± 0.01
OpenVINO GPU-ngl 99 -fa 11666.84 ± 13.8712.53 ± 0.09
OpenVINO CPU-ngl 99116.21 ± 4.798.81 ± 0.06
Native CPU-ngl 084.37 ± 2.4914.92 ± 0.03

Three findings worth unpacking:

  • Decode is fastest on Vulkan at 20.3 t/s, SYCL second at 16.4, and native CPU beats OpenVINO CPU (14.9 vs 8.8)
  • Prefill on OpenVINO GPU crushes it: 1667 t/s — 4.4× Vulkan, 20× native CPU
  • Yet OpenVINO GPU decodes slowest (12.5 t/s) — it shines for prompt-heavy workloads; for chat/decode, Vulkan is the balanced pick

The 26B: struggling before VRAM tuning

At the default 57% shared memory the iGPU budget is only 13.4GB, and full offload of the 15.63GB 26B fails everywhere — Vulkan OOMs (OutOfDeviceMemory), SYCL dies as layer count rises (UR_RESULT_ERROR_OUT_OF_DEVICE_MEMORY), OpenVINO GPU loads but decode returns res=-3. Only partial SYCL offload works, best at -ngl 8:

Configpp512 (t/s)tg128 (t/s)
SYCL -ngl 8134.03 ± 8.1617.80 ± 0.09
SYCL -ngl 12130.05 ± 7.6116.78 ± 0.20
SYCL -ngl 16122.70 ± 5.5715.76 ± 0.25
Native CPU -ngl 062.85 ± 9.8817.39 ± 0.08

Notice how raising layers from 8 to 16 makes it slower — the part spilling into system RAM drags everything down. Before tuning, the best the 26B could do was SYCL partial offload at pp 134 / tg 17.8.

The key lever: the iGPU shared-memory registry

The iGPU's usable memory budget comes from the registry key SystemPartitionCommitLimitPercentage (default 57). Set it to 87 and reboot, and the Vulkan budget grows from 12.67 GiB → 19.73 GiB — the 26B finally fits:

Configpp512 (t/s)tg128 (t/s)
Before tuning: SYCL -ngl 8134.0317.80
After tuning: Vulkan -ngl 99243.62 ± 2.1421.38 ± 0.06
After tuning: SYCL -ngl 99178.80 ± 1.9815.24 ± 0.39

Vulkan full offload takes the crown: pp 243.6 (3.9× pure CPU), tg 21.4 (1.2× pure CPU). A llama-cli smoke test streams at ~14.3 t/s (thinking blocks included) — perfectly usable. How to change the registry: see iGPU VRAM tuning.

The other route: the official OpenVINO GenAI pipeline

Beyond llama.cpp's OpenVINO backend, Intel offers a native OpenVINO GenAI pipeline that consumes officially pre-converted INT4-AWQ models (14.6GB). I got the official 26B running through it:

Routepp512 (t/s)tg128 (t/s)Notes
llama.cpp Vulkan (GGUF Q4_0)285.3020.04fast decode, mature ecosystem
OpenVINO GenAI (IR INT4-AWQ)50013.7~14.075% faster prefill, official weights

Same official model, both 4-bit: GenAI is 75% faster at prefill (500 vs 285 t/s), Vulkan 46% faster at decode (20 vs 13.7). The gap is MoE-backend implementation (Vulkan has async expert scheduling), not a tunable flag. Full walkthrough: OpenVINO GenAI official route.

Serving: the 26B as a resident API

Finally I made it a resident HTTP service (llama-server, OpenAI-compatible /v1/chat/completions) with prefix caching for multi-turn. With cache hits each turn only processes new tokens — prefill drops from 1.75s to ~1.2s from the second turn. Long context has a catch though: 16K is stable, 20K trips the iGPU driver's ErrorDeviceLost — tuning in the 20K context fix.

Summary: the complete iGPU roadmap

  • 8GB-class models (E4B, etc.): full offload directly; Vulkan fastest to decode (20 t/s), OpenVINO GPU for prompt-heavy work
  • 16GB-class models (26B, etc.): raise the shared-memory registry first (57→87), reboot, then Vulkan full offload takes off
  • For official weights: the native OpenVINO GenAI pipeline consumes official INT4-AWQ, with faster prefill
  • As a service: llama-server resident + prefix cache; multi-turn agents only pay for increments; watch -ub batching at long context
Heads-up:Registry changes need a reboot; after raising the budget only ~3GB of system RAM is left — watch stability. An iGPU shares system RAM; don't compare raw speed with discrete GPUs — cost-performance is its lane.
返回文章列表