Skip to content

Llama 3.1 8B Instruct VRAM requirements

How much VRAM Llama 3.1 8B Instruct needs
4-bit weights: 4.5 GBWith 8K context: 6.4 GBWith 32K context: 9.4 GB8-bit, 8K context: 9.8 GB
Parameters
8B
Longest context
128K
Released
Jul 2024
License
wtfpl
Strongest at
Not rated

Its licence (wtfpl) is not a standard open-source one: check the terms before commercial use.

How much VRAM Llama 3.1 8B Instruct needs

Memory Llama 3.1 8B Instruct needs at each precision and context length
PrecisionWeightsWith 8KWith 32KWith 128K
16-bit15.0 GB16.8 GB19.8 GB31.8 GB
8-bit7.9 GB9.8 GB12.8 GB24.8 GB
6-bit6.1 GB8.0 GB11.0 GB23.0 GB
5-bit5.3 GB7.1 GB10.1 GB22.1 GB
4-bit4.5 GB6.4 GB9.4 GB21.4 GB
3-bit3.7 GB5.5 GB8.5 GB20.5 GB
2-bit2.8 GB4.6 GB7.6 GB19.6 GB
1.6-bit1.5 GB3.4 GB6.4 GB18.4 GB

One conversation, 16-bit context cache, runtime overhead included.

GPUs and Macs that run Llama 3.1 8B Instruct

The best way Llama 3.1 8B Instruct runs on common GPUs, Macs and AI boxes
MachineBest fitContextSpeedFirst replyReport
RTX 40604-bit16K40 tok/s1.0 sPDF: Llama 3.1 8B Instruct on RTX 4060 report
RTX 50604-bit16K65 tok/s0.8 sPDF: Llama 3.1 8B Instruct on RTX 5060 report
RTX 30704-bit16K65 tok/s0.8 sPDF: Llama 3.1 8B Instruct on RTX 3070 report
RTX 3080 10 GB6-bit20K80 tok/s0.5 sPDF: Llama 3.1 8B Instruct on RTX 3080 10 GB report
RTX 3060 12 GB8-bit20K31 tok/s1.2 sPDF: Llama 3.1 8B Instruct on RTX 3060 12 GB report
Arc B5808-bit20K27 tok/s0.8 sPDF: Llama 3.1 8B Instruct on Arc B580 report
RTX 40708-bit20K42 tok/s0.5 sPDF: Llama 3.1 8B Instruct on RTX 4070 report
RTX 4070 Super8-bit20K42 tok/s0.4 sPDF: Llama 3.1 8B Instruct on RTX 4070 Super report
RTX 50708-bit20K56 tok/s0.5 sPDF: Llama 3.1 8B Instruct on RTX 5070 report
RTX 4060 Ti 16 GB8-bit48K25 tok/s0.7 sPDF: Llama 3.1 8B Instruct on RTX 4060 Ti 16 GB report
RTX 5060 Ti 16 GB8-bit48K38 tok/s0.7 sPDF: Llama 3.1 8B Instruct on RTX 5060 Ti 16 GB report
Arc A770 16 GB8-bit48K33 tok/s0.8 sPDF: Llama 3.1 8B Instruct on Arc A770 16 GB report
Radeon RX 9070 XT8-bit48K45 tok/s0.4 sPDF: Llama 3.1 8B Instruct on Radeon RX 9070 XT report
RTX 4070 Ti Super8-bit48K56 tok/s0.4 sPDF: Llama 3.1 8B Instruct on RTX 4070 Ti Super report
RTX 4080 Super8-bit48K61 tok/s0.3 sPDF: Llama 3.1 8B Instruct on RTX 4080 Super report
RTX 5070 Ti8-bit48K73 tok/s0.4 sPDF: Llama 3.1 8B Instruct on RTX 5070 Ti report
RTX 50808-bit48K78 tok/s0.3 sPDF: Llama 3.1 8B Instruct on RTX 5080 report
Radeon RX 7900 XTX8-bit112K65 tok/s0.7 sPDF: Llama 3.1 8B Instruct on Radeon RX 7900 XTX report
RTX 30908-bit112K76 tok/s0.4 sPDF: Llama 3.1 8B Instruct on RTX 3090 report
RTX 40908-bit112K82 tok/s0.2 sPDF: Llama 3.1 8B Instruct on RTX 4090 report
Radeon AI PRO R97008-bit128K45 tok/s0.4 sPDF: Llama 3.1 8B Instruct on Radeon AI PRO R9700 report
RTX 50908-bit128K137 tok/s0.1 sPDF: Llama 3.1 8B Instruct on RTX 5090 report
2× RTX 30908-bit128K76 tok/s0.3 sPDF: Llama 3.1 8B Instruct on 2× RTX 3090 report
2× RTX 40908-bit128K82 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 2× RTX 4090 report
RTX PRO 5000 Blackwell 48 GB8-bit128K106 tok/s0.2 sPDF: Llama 3.1 8B Instruct on RTX PRO 5000 Blackwell 48 GB report
RTX 6000 Ada8-bit128K78 tok/s0.2 sPDF: Llama 3.1 8B Instruct on RTX 6000 Ada report
L40S8-bit128K71 tok/s0.3 sPDF: Llama 3.1 8B Instruct on L40S report
2× RTX 50908-bit128K137 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 2× RTX 5090 report
4× RTX 30908-bit128K76 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 4× RTX 3090 report
RTX PRO 6000 Blackwell8-bit128K137 tok/s0.1 sPDF: Llama 3.1 8B Instruct on RTX PRO 6000 Blackwell report
Mac mini M4 16 GB6-bit24K15 tok/s9.9 sPDF: Llama 3.1 8B Instruct on Mac mini M4 16 GB report
Mac mini M4 24 GB8-bit52K12 tok/s9.9 sPDF: Llama 3.1 8B Instruct on Mac mini M4 24 GB report
Mac mini M4 32 GB8-bit88K12 tok/s9.9 sPDF: Llama 3.1 8B Instruct on Mac mini M4 32 GB report
Mac mini M4 Pro 24 GB8-bit52K26 tok/s5.0 sPDF: Llama 3.1 8B Instruct on Mac mini M4 Pro 24 GB report
Mac mini M4 Pro 48 GB8-bit128K26 tok/s5.0 sPDF: Llama 3.1 8B Instruct on Mac mini M4 Pro 48 GB report
Mac mini M4 Pro 64 GB8-bit128K26 tok/s5.0 sPDF: Llama 3.1 8B Instruct on Mac mini M4 Pro 64 GB report
M4 Max 128 GB8-bit128K45 tok/s2.5 sPDF: Llama 3.1 8B Instruct on M4 Max 128 GB report
M5 Max 128 GB8-bit128K50 tok/s0.7 sPDF: Llama 3.1 8B Instruct on M5 Max 128 GB report
M3 Ultra 96 GB8-bit128K57 tok/s1.4 sPDF: Llama 3.1 8B Instruct on M3 Ultra 96 GB report
M3 Ultra 256 GB8-bit128K57 tok/s1.4 sPDF: Llama 3.1 8B Instruct on M3 Ultra 256 GB report
M3 Ultra 512 GB8-bit128K57 tok/s1.4 sPDF: Llama 3.1 8B Instruct on M3 Ultra 512 GB report
M5 Ultra 512 GB8-bit128K78 tok/s0.4 sPDF: Llama 3.1 8B Instruct on M5 Ultra 512 GB report
Ryzen AI Max+ 395 64 GB8-bit128K19 tok/s1.4 sPDF: Llama 3.1 8B Instruct on Ryzen AI Max+ 395 64 GB report
Ryzen AI Max+ 395 128 GB8-bit128K19 tok/s1.4 sPDF: Llama 3.1 8B Instruct on Ryzen AI Max+ 395 128 GB report
RTX Spark8-bit128K26 tok/s0.5 sPDF: Llama 3.1 8B Instruct on RTX Spark report
DGX Spark8-bit128K23 tok/s0.5 sPDF: Llama 3.1 8B Instruct on DGX Spark report
Dual DGX Spark8-bit128K23 tok/s0.3 sPDF: Llama 3.1 8B Instruct on Dual DGX Spark report
DGX Station GB3008-bit128K390 tok/s0.1 sPDF: Llama 3.1 8B Instruct on DGX Station GB300 report
2× RTX PRO 6000 Blackwell8-bit128K137 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 2× RTX PRO 6000 Blackwell report
4× RTX PRO 6000 Blackwell8-bit128K137 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 4× RTX PRO 6000 Blackwell report
8× RTX PRO 6000 Blackwell8-bit128K137 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 8× RTX PRO 6000 Blackwell report
A100 80 GB SXM8-bit128K153 tok/s0.3 sPDF: Llama 3.1 8B Instruct on A100 80 GB SXM report
H100 SXM8-bit128K229 tok/s0.1 sPDF: Llama 3.1 8B Instruct on H100 SXM report
4× H200 NVL8-bit128K300 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 4× H200 NVL report
8× H200 NVL8-bit128K300 tok/s0.1 sPDF: Llama 3.1 8B Instruct on 8× H200 NVL report

Best fit is the highest quality, up to 8-bit, that leaves 16K of context. First reply is the wait for a 2K prompt. Speeds are rough, plus or minus 25%.

How to run it

llama.cpp
llama-server -hf featherless-ai-quants/TroyDoesAI-Llama-3.1-8B-Instruct-GGUF
vLLM
vllm serve TroyDoesAI/Llama-3.1-8B-Instruct

Questions

How much VRAM does Llama 3.1 8B Instruct need?

Llama 3.1 8B Instruct needs 4.5 GB for its weights at 4-bit, 6.4 GB with an 8K context and 9.4 GB with 32K. At 8-bit, 9.8 GB.

What is the minimum VRAM for Llama 3.1 8B Instruct?

About 5.5 GB at 3-bit with an 8K context, the lowest precision we recommend for a model this size. The smallest machine here that runs it without spilling is the RTX 4060.

How big is Llama 3.1 8B Instruct?

8B parameters: 15.0 GB of weights at 16-bit, 4.5 GB at 4-bit.

Can Llama 3.1 8B Instruct run on an RTX 4090?

Yes. At 8-bit it holds 112K of context and writes about 82 tokens a second.

More models