Google · 12B · Q4_K_M · 6.63 GiB

Gemma 4 12B at Q4_K_M needs about 7.95 GiB at 8K context, and the smallest listed machine that fits it is GeForce RTX 3080 10GB.

Dense Gemma 4 12B. 40 sliding layers (window 1,024) and 8 full layers with global_head_dim 512 and 1 global KV head. Sliding layers use head_dim and num_key_value_heads. Full layers use global_head_dim. When num_global_key_value_heads is null, full layers keep num_key_value_heads.

ollama run gemma4:12b

Weights: gemma-4-12b-it-Q4_K_M.gguf. Architecture: config source. Hugging Face repo created 2026-05-23. License field: apache-2.0.

Quants with a measured file size

QuantFileSize
Q4_K_M · recommendedgemma-4-12b-it-Q4_K_M.gguf6.63 GiB
Q5_K_Mgemma-4-12b-it-Q5_K_M.gguf7.84 GiB
Q6_Kgemma-4-12b-it-Q6_K.gguf9.11 GiB
Q8_0gemma-4-12b-it-Q8_0.gguf11.8 GiB

Machines

Same quant and 8,192 tokens on every row.
MachineMemoryTotalVerdictSpeed
Apple M1, 8 GB8 GB unified7.95 GiBNo—
Apple M2, 8 GB8 GB unified7.95 GiBNo—
Apple M3, 8 GB8 GB unified7.95 GiBNo—
GeForce RTX 3060 Ti8 GB GDDR7.95 GiBTight32–50 tok/s
GeForce RTX 30708 GB GDDR7.95 GiBTight32–50 tok/s
GeForce RTX 40608 GB GDDR7.95 GiBTight20–31 tok/s
GeForce RTX 4060 Ti 8GB8 GB GDDR7.95 GiBTight21–32 tok/s
GeForce RTX 50608 GB GDDR7.95 GiBTight32–50 tok/s
GeForce RTX 5060 Ti 8GB8 GB GDDR7.95 GiBTight32–50 tok/s
Radeon RX 66008 GB GDDR67.95 GiBTight16–25 tok/s
Radeon RX 76008 GB GDDR67.95 GiBTight21–32 tok/s
GeForce RTX 3080 10GB10 GB GDDR7.95 GiBFits55–85 tok/s
GeForce RTX 3060 12GB12 GB GDDR7.95 GiBFits26–40 tok/s
GeForce RTX 407012 GB GDDR7.95 GiBFits37–57 tok/s
GeForce RTX 4070 Super12 GB GDDR7.95 GiBFits37–57 tok/s
GeForce RTX 4070 Ti12 GB GDDR7.95 GiBFits37–57 tok/s
GeForce RTX 507012 GB GDDR7.95 GiBFits49–75 tok/s
Intel Arc B58012 GB GDDR67.95 GiBFits33–51 tok/s
Radeon RX 6700 XT12 GB GDDR67.95 GiBFits28–43 tok/s
Radeon RX 7700 XT12 GB GDDR67.95 GiBFits31–49 tok/s
Apple M1 Pro, 16 GB16 GB unified7.95 GiBFits14–22 tok/s
Apple M1, 16 GB16 GB unified7.95 GiBFits5–8 tok/s
Apple M2 Pro, 16 GB16 GB unified7.95 GiBFits14–22 tok/s
Apple M2, 16 GB16 GB unified7.95 GiBFits7–11 tok/s
Apple M3, 16 GB16 GB unified7.95 GiBFits7–11 tok/s
Apple M4, 16 GB16 GB unified7.95 GiBFits9–13 tok/s
GeForce RTX 4060 Ti 16GB16 GB GDDR7.95 GiBFits21–32 tok/s
GeForce RTX 4070 Ti Super16 GB GDDR7.95 GiBFits49–75 tok/s
GeForce RTX 408016 GB GDDR7.95 GiBFits52–81 tok/s
GeForce RTX 4080 Super16 GB GDDR7.95 GiBFits53–83 tok/s
GeForce RTX 5060 Ti 16GB16 GB GDDR7.95 GiBFits32–50 tok/s
GeForce RTX 5070 Ti16 GB GDDR7.95 GiBFits65–101 tok/s
GeForce RTX 508016 GB GDDR7.95 GiBFits70–108 tok/s
Intel Arc A770 16GB16 GB GDDR67.95 GiBFits37–58 tok/s
Legion Go16 GB LPDDR5X-75007.95 GiBFits9–13 tok/s
Radeon RX 6800 XT16 GB GDDR67.95 GiBFits37–58 tok/s
Radeon RX 7800 XT16 GB GDDR67.95 GiBFits45–70 tok/s
Radeon RX 9060 XT 16GB16 GB GDDR67.95 GiBFits23–36 tok/s
Radeon RX 9070 XT16 GB GDDR67.95 GiBFits46–72 tok/s
ROG Ally16 GB LPDDR5-64007.95 GiBFits7–12 tok/s
Steam Deck LCD16 GB LPDDR5-55007.95 GiBFits6–10 tok/s
Steam Deck OLED16 GB LPDDR5-64007.95 GiBFits7–12 tok/s
Apple M3 Pro, 18 GB18 GB unified7.95 GiBFits11–17 tok/s
Radeon RX 7900 XT20 GB GDDR67.95 GiBFits58–90 tok/s
Apple M2, 24 GB24 GB unified7.95 GiBFits7–11 tok/s
Apple M3, 24 GB24 GB unified7.95 GiBFits7–11 tok/s
Apple M4 Pro, 24 GB24 GB unified7.95 GiBFits20–31 tok/s
Apple M4, 24 GB24 GB unified7.95 GiBFits9–13 tok/s
GeForce RTX 309024 GB GDDR7.95 GiBFits68–105 tok/s
GeForce RTX 409024 GB GDDR7.95 GiBFits73–113 tok/s
Radeon RX 7900 XTX24 GB GDDR67.95 GiBFits70–108 tok/s
ROG Ally X24 GB LPDDR5X-75007.95 GiBFits9–13 tok/s
Apple M1 Max, 32 GB32 GB unified7.95 GiBFits29–45 tok/s
Apple M1 Pro, 32 GB32 GB unified7.95 GiBFits14–22 tok/s
Apple M2 Max, 32 GB32 GB unified7.95 GiBFits29–45 tok/s
Apple M2 Pro, 32 GB32 GB unified7.95 GiBFits14–22 tok/s
Apple M4, 32 GB32 GB unified7.95 GiBFits9–13 tok/s
GeForce RTX 509032 GB GDDR7.95 GiBFits130–201 tok/s
Apple M3 Pro, 36 GB36 GB unified7.95 GiBFits11–17 tok/s
Apple M4 Max 14-core, 36 GB36 GB unified7.95 GiBFits30–46 tok/s
Apple M3 Max 16-core, 48 GB48 GB unified7.95 GiBFits29–45 tok/s
Apple M4 Max 16-core, 48 GB48 GB unified7.95 GiBFits40–61 tok/s
Apple M4 Pro, 48 GB48 GB unified7.95 GiBFits20–31 tok/s
Apple M1 Max, 64 GB64 GB unified7.95 GiBFits29–45 tok/s
Apple M2 Max, 64 GB64 GB unified7.95 GiBFits29–45 tok/s
Apple M3 Max 16-core, 64 GB64 GB unified7.95 GiBFits29–45 tok/s
Apple M4 Max 16-core, 64 GB64 GB unified7.95 GiBFits40–61 tok/s
Apple M4 Pro, 64 GB64 GB unified7.95 GiBFits20–31 tok/s
Apple M2 Max, 96 GB96 GB unified7.95 GiBFits29–45 tok/s
Apple M3 Max 16-core, 128 GB128 GB unified7.95 GiBFits29–45 tok/s
Apple M4 Max 16-core, 128 GB128 GB unified7.95 GiBFits40–61 tok/s

Exact answers

GeForce RTX 3060 12GBfitsGeForce RTX 4060tightGeForce RTX 4070fitsGeForce RTX 5070fitsIntel Arc B580fitsSteam Deck OLEDfitsApple M4, 16 GBfits

FAQ

Why Q4_K_M?

Q4_K_M is the quant this page recommends. The file is gemma-4-12b-it-Q4_K_M.gguf at 6.63 GiB. Other single-file quants are in the table when a real size was available.

Where do the architecture numbers come from?

Official text_config: layer_types, sliding_window, head_dim, global_head_dim, num_key_value_heads, num_global_key_value_heads. Source: https://huggingface.co/google/gemma-4-12B-it/raw/main/config.json

Does this include a long context?

The fit uses 8,192 tokens, or less when that is all the fast memory can hold. The model file allows up to 262,144 tokens, and KV cache grows as you use more of that.

What is the Ollama command?

ollama run gemma4:12b. The library tag is Q4-class or the vendor quant. Compare it with the GGUF linked on this page before you treat the sizes as identical.

Does this include image input?

No. Weight memory is the cited language-model GGUF. A separate vision projector, when one exists, needs more memory.