---
title: "LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scale"
description: "How LLM.int8() preserves transformer accuracy with 8-bit matrix multiplication, why outliers matter, and where its memory savings stop."
canonical: "https://research.elamur.ai/free/en/papers/dettmers-2022-llm-int8-8-bit-matrix/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/dettmers-2022-llm-int8-8-bit-matrix/)

[home](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2022](https://md.research.elamur.ai/free/en/papers/2022/) / LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scale

# LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scale

Paper · 2022 · Tim Dettmers, Mike Lewis, Younes Belkada et al.

**Authors:** [Tim Dettmers](https://md.research.elamur.ai/free/en/authors/tim-dettmers/), [Mike Lewis](https://md.research.elamur.ai/free/en/authors/mike-lewis/), [Younes Belkada](https://md.research.elamur.ai/free/en/authors/younes-belkada/) and [Luke Zettlemoyer](https://md.research.elamur.ai/free/en/authors/luke-zettlemoyer/) · **Year:** 2022 · **Venue:** arXiv:2208.07339 · **Licence:** [CC BY 4.0 (arXiv)](http://creativecommons.org/licenses/by/4.0/)

[**276** citations OpenAlex, 2026-10-14](https://openalex.org/works?filter=cites:W7133198810) · [arXiv:2208.07339](https://openalex.org/S4363606243) · [licence](http://creativecommons.org/licenses/by/4.0/)

- [PDF](https://arxiv.org/pdf/2208.07339)
- [arXiv 2208.07339](https://arxiv.org/abs/2208.07339)
- [OpenAlex](https://openalex.org/W7133198810)

Citations: OpenAlex, 2026-10-14.

## Deep dive: LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scale

How LLM.int8() preserves transformer accuracy with 8-bit matrix multiplication, why outliers matter, and where its memory savings stop. · about 32 minutes to read

**In this deep dive**

1. [Summary](#dd-summary)
2. [Ideas worth borrowing](#dd-ideas-worth-borrowing)
3. [How Mova uses it](#dd-how-mova-uses-it)
4. [The problem and its context](#dd-the-problem-and-its-context)
5. [The method, step by step](#dd-the-method-step-by-step)
6. [Experiments and results](#dd-experiments-and-results)
7. [What the ablations show](#dd-what-the-ablations-show)
8. [Limitations](#dd-limitations)
9. [What came after](#dd-what-came-after)

### Summary

Large [language models](https://md.research.elamur.ai/free/en/concepts/language-model/) can require more GPU memory than a researcher has available, even when the task is only to run an already trained system. LLM.int8() addresses that obstacle by reducing the precision used for the large matrix multiplications inside a [transformer](https://md.research.elamur.ai/free/en/concepts/transformer/). The goal is to reduce memory consumption while preserving the predictions obtained with higher precision. The paper reports that its method maintains the evaluated predictive performance through the OPT scale of 175B parameters, while allowing the original checkpoint to be converted and used without a further training stage.

The difficulty is that a small number of internal features behave very differently from the rest. Their values can become much larger than ordinary hidden-state values, yet they carry information that the transformer needs. A quantizer that accommodates these extremes can represent the surrounding smaller values too coarsely. The authors observe a particularly consequential change around 6.7B parameters: large values become widespread across layers and token positions, although they remain concentrated in very few feature dimensions. At that scale, an example sequence contains about 150,000 outlier occurrences distributed across only 6 dimensions. Removing the exceptional dimensions damages both attention probabilities and language prediction, so discarding them is not an acceptable compression strategy.

LLM.int8() combines more precise scaling with selective use of higher precision. Its vector-wise quantization gives each input row and each weight column a separate scale, improving the accuracy of the individual inner products that form a matrix multiplication. Its mixed-precision decomposition then separates the exceptional feature dimensions from the rest. Those dimensions use 16-bit multiplication; the much larger remainder uses 8-bit multiplication. The authors report that more than 99.9% of values still participate in the lower-precision path. For BLOOM-176B, the reported memory reduction is 1.96x.

The evidence includes C4 validation perplexity, zero-shot task accuracy, interventions on internal features, and runtime measurements. Vector-wise scaling alone preserves performance through 2.7B parameters, but handling outliers becomes essential at larger scales. The complete method preserves the measured accuracy where ordinary quantization deteriorates. Its strongest practical result is access: OPT-175B and BLOOM-176B can run on a server equipped with consumer GPUs. Speed is more conditional. Large matrix multiplications can benefit, while conversion and decomposition overhead can slow smaller ones; the end-to-end BLOOM benchmark is slightly slower than the higher-precision reference. The work establishes an inference method, instead of a general solution for low-precision attention, training, or [fine-tuning](https://md.research.elamur.ai/free/en/concepts/fine-tuning/). The authors release their implementation through bitsandbytes and integrate it with Hugging Face Transformers.

### Ideas worth borrowing

Protect the exceptional cases. The paper succeeds by recognizing that numerical difficulty is concentrated in a small, structured subset of the computation. It gives that subset a more accurate representation while compressing the remainder aggressively. This is useful whenever a uniform approximation spends resources poorly: most inputs tolerate a cheaper operation, but a few consequential inputs do not. The transferable idea is to identify those exceptions through their effect on the final task, then make the expensive path selective. A large magnitude alone is a warning sign; the removal experiments establish why preserving these particular dimensions matters.

Match scaling to the operation. Matrix multiplication consists of inner products between input rows and weight columns. Vector-wise quantization follows that structure rather than assigning a scale according to an arbitrary storage boundary. Each output can be reconstructed from the scales attached to its contributing vectors. This makes a numerical representation easier to reason about because the normalization corresponds directly to the computation. The same design principle applies elsewhere: choose approximation boundaries around the units that interact, and preserve enough metadata to reconstruct the meaning of their outputs.

Study the direction of the error. More scaling constants help, but their orientation matters. In this paper, hidden-state rows correspond to token positions, whereas the troublesome values recur in columns corresponding to features. Row scaling cannot isolate a feature that appears throughout the sequence. That mismatch explains why a seemingly refined quantizer still fails. An engineer can reuse this reasoning when a numerical method improves average error without fixing application quality: inspect whether the exceptional structure lies along the dimension that the method actually separates.

Evaluate the trend across scale. A quantizer can look adequate on a small transformer and become unusable on a larger one. The authors therefore make the behavior across checkpoint sizes central to evaluation. Their question is whether increased capacity continues to produce better predictions after conversion. This is a useful pattern for [efficient models and compression](https://md.research.elamur.ai/free/en/topics/efficient-models/): test whether an optimization preserves the benefit of the resource being increased, rather than presenting a successful result at a convenient size. A method that saves memory but destroys the value of a larger checkpoint has failed its intended purpose.

Pair internal measurements with interventions. The outlier analysis does more than describe unusual activation statistics. The authors remove selected dimensions and compare the consequences with removing random dimensions. They also separate an attention experiment that avoids cascading errors from a perplexity experiment that allows changes to propagate. This makes the evidence more informative: one intervention examines a local mechanism, while the other measures the resulting damage to prediction. Similar designs can help connect representation analysis to observable behavior without treating correlation as a complete explanation.

Separate numerical speed from system speed. An integer matrix multiplication can be faster while the surrounding application remains unchanged or becomes slower. Quantization, dequantization, decomposition, and distributed communication all contribute to elapsed time. The paper measures both the arithmetic operation and complete generation, revealing different outcomes. This distinction is useful in any systems optimization. Benchmark the proposed primitive, then measure the workflow that pays for preparing its inputs and consuming its outputs. Memory savings can remain valuable even when the application does not receive a latency improvement.

### How Mova uses it

For Mova, the small transparent language system written in Rust, the most useful lesson is a way to organize numerical approximation. A compact implementation can make its precision decisions explicit: which values are compressed, how their scales are stored, which exceptional values receive separate treatment, and how the outputs are combined. LLM.int8() offers a concrete example of such a design. Its ordinary and exceptional paths have distinct responsibilities, and the reason for retaining higher precision can be examined through measurements.

There is no established implementation evidence here that Mova already performs LLM.int8() multiplication. The appropriate application is therefore a possible engineering direction. If Mova contains learned linear transformations whose memory cost matters, it could investigate storing their weights in a lower-precision representation and reconstructing outputs with documented scaling rules. That would be an adaptation to Mova’s own computations. It would need its own accuracy and runtime evaluation before carrying the paper’s performance claims.

A useful starting point would be measurement rather than an outlier bypass. The paper’s exceptional dimensions are a property observed in the transformers it studies. Mova should not assume that its own internal values have the same distribution, the same concentration by feature, or the same relationship to prediction. It could record value ranges along the dimensions used by its actual operations and examine whether a small subset repeatedly determines the required numerical range. This would reveal whether selective precision addresses a real constraint.

Transparency also changes what a successful implementation should expose. A reader examining Mova could benefit from seeing the scale associated with a vector, the rule that sends a feature to a higher-precision path, and the contribution made by each path. These are proposed implementation properties, not reported features. They follow naturally from the paper’s decomposition: a memory-saving operation remains understandable when its exceptions and reconstruction steps are visible.

The evaluation strategy transfers even if the arithmetic does not. Mova could compare its original computation with a compressed version on the same inputs, then investigate whether errors concentrate in particular internal features. It could also compare targeted feature removal with a random control. The point would be to establish whether the compressed representation preserves useful behavior, rather than relying only on small numerical differences in intermediate arrays.

The paper also provides a reason to keep expectations modest for a small Rust system. Its runtime benefits depend on sufficiently large matrix operations and the behavior of the GPU implementation. Mova’s name, size, language, or emphasis on transparency does not establish those conditions. A compact CPU implementation, or a system with little dense matrix arithmetic, may gain little from reproducing this particular method. The reusable contribution is the discipline of matching precision to measured importance and reporting the full cost of that choice.

### The problem and its context

#### Why parameter memory was the immediate target

Inference begins with parameters that have already been learned, but those parameters still have to be stored somewhere accessible to the computation. Increasing the capacity of a transformer can therefore make it unavailable to researchers whose GPUs cannot hold its weights. The obstacle is distinct from the cost of training. A publicly released checkpoint does not automatically become practical to use simply because the training has already been paid for.

The authors identify a particularly valuable place to reduce this storage requirement. In transformers at or beyond 6.7B parameters, the feed-forward transformations and attention projections account for 95% of parameters. The paper attributes 65-85% of computation to these operations as well. Embeddings contain most of the remaining parameters, with norms and biases contributing a small amount. Quantizing the large linear transformations therefore attacks most of the parameter footprint without requiring every operation to use the same representation.

A linear transformation combines hidden-state values with learned weights through matrix multiplication. In the original checkpoint, those values may be represented with 16-bit or 32-bit floating-point numbers. An 8-bit integer representation uses less storage, but it cannot express the same range of distinct values with the same precision. Quantization specifies how real-valued quantities are mapped into that restricted representation and how the results are interpreted afterwards.

The practical question is whether this substitution changes the behavior that makes a checkpoint useful. A compressed transformer that occupies less memory but produces substantially worse predictions may offer a poor trade. LLM.int8() sets a demanding objective: preserve the evaluated predictive performance while obtaining the storage advantage of mostly 8-bit parameters and multiplication.

#### What earlier transformer quantization had established

The paper describes earlier transformer quantization as concentrated on smaller systems, particularly masked language architectures such as [BERT](https://md.research.elamur.ai/free/en/papers/devlin-2019-bert-pre-training-deep-bidirectional/) and [RoBERTa](https://md.research.elamur.ai/free/en/papers/liu-2019-roberta-robustly-optimized-bert-pretraining/). The cited approaches include Q8BERT, QBERT, and methods that combine product quantization with quantization noise. It also discusses more aggressive representations, including [TernaryBERT](https://md.research.elamur.ai/free/en/papers/zhang-2020-ternarybert-distillation-aware-ultra-low/) and BinaryBERT.

According to the authors, these approaches commonly need an additional procedure to make low-precision operation usable, such as quantization-aware fine-tuning or post-training adjustment. Much of the earlier evidence concerned checkpoints smaller than 350M parameters. The introduction presents performance-preserving quantization at that scale as incompletely understood, with the multi-billion regime still requiring investigation.

The distinction from LLM.int8() is therefore partly about deployment. The proposed method is intended to take an existing checkpoint, convert the targeted transformations, and begin inference. It does not depend on teaching the converted system to compensate through a further optimization stage. This makes understanding the numerical failure especially important: the method must preserve the relevant computation directly.

Vector-wise scaling itself is not presented as an entirely unprecedented numerical construction. The appendix explains its relationship to channel-wise quantization in convolutional networks combined with row scaling. It also acknowledges earlier matrix-multiplication use at the BERT scale. The contribution is to investigate that approach for autoregressive transformers at much larger sizes and to supply the additional mechanism needed when vector-wise scaling fails.

#### Why larger transformers changed the problem

A larger matrix is not merely a more expensive instance of the same quantization problem. The internal values also change. The authors observe that sufficiently large transformers contain features whose magnitudes greatly exceed those of other features. These values are sparse when counted by feature dimension, but they recur across many token positions and layers.

This structure creates a conflict for a quantizer with a shared scale. To accommodate a very large value, it must spread its finite integer levels across a wider real-valued interval. Ordinary values then receive fewer useful distinctions. Some can be rounded to zero, eliminating information that was represented in the floating-point computation.

The outliers themselves cannot simply be clipped away without concern. The paper’s interventions show that they are important to attention and predictive performance. That observation connects the numerical problem to [interpretability](https://md.research.elamur.ai/free/en/topics/interpretability/): understanding which internal coordinates matter becomes part of designing a reliable implementation.

Earlier work had already investigated unusually large features in language representations. The paper describes connections with layer normalization and token-frequency distributions, including studies of BERT-family systems. Its own analysis extends that discussion to autoregressive transformers across scale and asks how those features constrain low-precision arithmetic.

#### Parallel approaches and a different emphasis

The related-work section identifies nuQmm and [ZeroQuant](https://md.research.elamur.ai/free/en/papers/yao-2022-zeroquant-efficient-affordable-post-training/) as parallel efforts. Both use group-wise quantization, which assigns normalization constants more finely than vector-wise scaling. The authors describe that precision as helpful, while noting the need for custom CUDA kernels.

The largest evaluated sizes reported for those works are 2.7B for nuQmm and 20B for ZeroQuant. The paper credits ZeroQuant with preserving performance for an 8-bit version of its 20B checkpoint. These are meaningful nearby results, rather than evidence that LLM.int8() was the only route to useful multi-billion quantization.

The difference in emphasis is that LLM.int8() prioritizes preserving prediction quality while obtaining an 8-bit memory footprint. Its exceptional-feature path addresses a particular failure mechanism directly. The authors regard finer-grained scaling and their decomposition as compatible ideas, leaving room for combinations rather than requiring a single universal quantization scheme.

### The method, step by step

#### Follow the computation before changing its precision

The method operates on linear transformations within feed-forward networks and attention projections. Attention projections create or transform the vectors used around attention; they are distinct from the attention function that combines those vectors. LLM.int8() converts the former operations. It does not establish an 8-bit implementation of the latter.

Consider a hidden-state matrix whose rows correspond to token positions and whose columns correspond to features. A weight matrix maps those features to output coordinates. Each output entry is formed by multiplying an input row against a weight column and summing the products. This structure explains both parts of the method: vector-wise normalization follows the row–column pair, while decomposition separates troublesome coordinates along the shared feature dimension.

How LLM.int8() computes a linear transformation The steps in order.

The diagram describes the logical computation. Its two multiplication paths contribute to the same output. The higher-precision path protects important exceptions; the integer path provides most of the memory benefit.

#### Start with absolute-maximum quantization

Absolute-maximum quantization, abbreviated absmax, chooses a scale from the largest absolute value in the tensor being quantized. It maps the data into the signed integer interval [-127, 127] and rounds each scaled value to a nearby integer. A compact form of the paper’s equation is:

```
Xᵢ₈ = round(127X𝒻₁₆ / maxᵢⱼ|X𝒻₁₆,ᵢⱼ|) = round(sₓX𝒻₁₆)
```

Here, X𝒻₁₆ is the original matrix of 16-bit floating-point values, and Xᵢ₈ is its integer representation. The indices i and j identify a matrix entry. The maximum is taken over all entries included in the quantization unit. The scalar sₓ is the multiplier formed by dividing 127 by that maximum magnitude. The round operation selects the nearest integer.

This rule is simple and symmetric around zero. Positive and negative values are treated through the same magnitude-based scale. It works well when that symmetry and the chosen range match the data, but it becomes inefficient when a large exceptional value determines the scale for many small values.

The paper also writes the maximum magnitude as an infinity norm. That notation denotes the same scaling quantity in this context; it does not introduce a different quantization procedure. The important design choice is the set of values that share the maximum. A whole tensor, an individual row, and a selected group can produce very different precision even when all use absmax.

#### Understand the asymmetric alternative

The authors compare absmax with zeropoint quantization. This alternative uses the minimum and maximum values to fit an asymmetric distribution more effectively into the available integer range. Its normalized dynamic-range multiplier is:

```
ndₓ = (2 · 127) / (maxᵢⱼX𝒻₁₆,ᵢⱼ − minᵢⱼX𝒻₁₆,ᵢⱼ)
```

The symbol ndₓ denotes the scaling multiplier. X𝒻₁₆ again denotes the floating-point input, while max and min select its greatest and least entries. The indices i and j range over the entries sharing that scale. The factor 2 · 127 corresponds to the signed interval used by the paper.

The motivation is easiest to see with a distribution confined to one side of zero. A symmetric mapping reserves integer values for a side of the real-valued distribution that may contain no data. An asymmetric mapping can use those representational levels for values that actually occur. This becomes relevant because the outlier features are typically one-sided.

For completeness, the displayed background equations introduce the following zeropoint expression:

```
zpₓ,ᵢ₁₆ = round(X𝒻₁₆ · minᵢⱼX𝒻₁₆,ᵢⱼ)
```

The symbol zpₓ,ᵢ₁₆ denotes the stated integer offset, and min selects the smallest input entry. As written, this expression multiplies a matrix by a scalar minimum, so it does not specify a conventional scalar zeropoint unambiguously. The surrounding explanation nevertheless makes the intended role clear: an offset accompanies the quantized values when multiplication is performed. This notation issue belongs to the background presentation, rather than to the absmax-based definition of LLM.int8().

The scaled integer input is written as:

```
Xᵢ₈ = round(ndₓX𝒻₁₆)
```

Here, ndₓ is the dynamic-range multiplier just defined, X𝒻₁₆ is the floating-point input, and Xᵢ₈ contains the rounded integer values. The offset is handled with the operation, rather than appearing explicitly in this displayed scaling expression.

For scalar multiplication, the paper describes combining quantized values with their offsets:

```
Cᵢ₃₂ = (Aᵢ₈ + zpₐ,ᵢ₁₆)(Bᵢ₈ + zpᵦ,ᵢ₁₆)
```

Aᵢ₈ and Bᵢ₈ are the quantized operands. The quantities zpₐ,ᵢ₁₆ and zpᵦ,ᵢ₁₆ are their associated offsets. Cᵢ₃₂ is the integer result accumulated with 32-bit precision. The subscripts identify numerical formats; they are not sequence or feature indices.

When hardware does not provide the combined operation assumed in that description, the multiplication can be expanded:

```
Cᵢ₃₂ = Aᵢ₈Bᵢ₈ + Aᵢ₈zpᵦ,ᵢ₁₆ + Bᵢ₈zpₐ,ᵢ₁₆ + zpₐ,ᵢ₁₆zpᵦ,ᵢ₁₆
```

All symbols retain their preceding meanings. The first term is the direct product of the quantized operands. The other terms account for the offsets and require additional arithmetic. This explains the paper’s distinction between numerical precision and implementation cost: an asymmetric mapping can reduce representation error while introducing work beyond ordinary integer matrix multiplication.

#### Recover floating-point outputs from integer products

Quantizing the inputs does not mean that every later operation must remain integer-valued. The paper’s targeted transformation accepts floating-point inputs, performs the central multiplication using integer representations, and returns a floating-point output.

Its tensor-wise reconstruction can be written as:

```
C𝒻₁₆ = X𝒻₁₆W𝒻₁₆ ≈ Cᵢ₃₂/(cₓc𝓌) = SCᵢ₃₂ ≈ SQ(X𝒻₁₆)Q(W𝒻₁₆)
```

X𝒻₁₆ is the hidden-state matrix and W𝒻₁₆ is the learned weight matrix. Their floating-point product is C𝒻₁₆. The operator Q quantizes its argument using the selected rule. Cᵢ₃₂ is the accumulated integer product. The quantities cₓ and c𝓌 are the scaling multipliers for the input and weights, and S is their reciprocal product.

The approximation sign matters. Integer rounding has already discarded some distinctions, so rescaling cannot generally recreate the exact original product. The engineering objective is to make that error small enough in the places that determine predictive performance.

In the paper’s setup, X has shape s × h and W has shape h × o. The symbol s is the number of sequence positions, h is the input feature width, and o is the output width. Their shared feature dimension determines which input coordinates multiply which weight rows.

#### Give rows and columns their own scales

Tensor-wise quantization lets a single extreme value determine the precision of an entire matrix. Vector-wise quantization reduces that dependence. It assigns a separate input scale to each row and a separate weight scale to each column.

For a particular output entry, only the corresponding input-row scale and weight-column scale are needed. Across the whole output, those paired products form an outer product:

```
C𝒻₁₆ ≈ Cᵢ₃₂/(cₓ ⊗ c𝓌) = S ⊙ Cᵢ₃₂ ≈ S ⊙ [Q(X𝒻₁₆)Q(W𝒻₁₆)]
```

The vector cₓ contains the input-row scaling multipliers, and c𝓌 contains the weight-column multipliers. The symbol ⊗ forms their outer product, producing a scale for each output position. Division by that matrix is element by element. S contains the corresponding reciprocal scales, and ⊙ denotes element-wise multiplication. The matrix multiplication inside brackets is the integer operation.

This gives each inner product a reconstruction scale derived from the two vectors it actually combines. A large value in one weight column no longer determines the scale of every other weight column. Similarly, input rows can adapt independently to their ranges.

The improvement is substantial enough to preserve the evaluated performance through 2.7B parameters. It is not sufficient once extreme feature columns become widespread. An outlier column can place a large value in many input rows, so each of those rows still has to accommodate it.

#### Separate outlier dimensions along the shared axis

Mixed-precision decomposition addresses the remaining mismatch. Instead of asking row scaling to absorb every exceptional column, it removes those feature dimensions from the integer multiplication and computes their contribution separately.

The method forms a set O of feature indices. A feature enters O when at least one value in that input dimension exceeds the magnitude threshold α. The authors find α = 6.0 sufficient to make inference degradation nearly disappear in their evaluation.

The multiplication is then expressed as:

```
C𝒻₁₆ ≈ Σₖ∈O X𝒻₁₆[:,k]W𝒻₁₆[k,:] + S𝒻₁₆ ⊙ Σₖ∉O Xᵢ₈[:,k]Wᵢ₈[k,:]
```

C𝒻₁₆ is the output matrix. The index k runs over input feature dimensions. O is the exceptional-feature set, and k ∉ O denotes all remaining features. The notation X[:,k] selects a feature column of the input; W[k,:] selects its matching weight row. Their product contributes to every relevant output position.

The first sum uses 16-bit floating-point operands for the selected dimensions. The second sum uses 8-bit integer representations for the rest, with S𝒻₁₆ restoring the vector-wise scales. The symbol ⊙ again indicates element-wise rescaling. Both contributions are combined into the floating-point output.

The separation preserves entire feature dimensions, rather than isolated large entries. That is appropriate because the exceptional values recur systematically along those dimensions. It also keeps the decomposition aligned with the shared axis of matrix multiplication.

For the analyzed transformers through 13B parameters, the authors report no more than 7 exceptional dimensions. They estimate the extra memory for this decomposition at about 0.1%. The argument depends on this sparsity: higher precision remains affordable because the exceptional path is small.

#### Distinguish deployment from the analysis procedure

The conversion procedure does not train a new predictor. It starts from pretrained weights, quantizes the targeted operations, and uses the resulting computation for inference. The paper’s official implementation makes this operation available through bitsandbytes, with a Hugging Face Transformers integration for systems containing linear layers.

The analysis that motivated the method is more selective than the runtime outlier rule. To study persistent features across checkpoints, the authors require a magnitude of at least 6.0, occurrence in at least 25% of layers, and presence in at least 6% of sequence positions. These persistence conditions make the descriptive statistics manageable. They should not be mistaken for a requirement that deployment first establish the same cross-layer recurrence.

The thresholds were chosen empirically. In the smallest analyzed transformer, the layer and sequence conditions retain the most persistent exceptional feature while excluding much less common cases. The magnitude threshold is tied to the point at which the decomposition stops producing noticeable perplexity degradation. The paper therefore presents a measured operating choice, rather than a mathematical guarantee that the same cutoff is optimal everywhere.

### Experiments and results

#### Two complementary tests of predictive preservation

The main evaluation asks whether quantization preserves the improvement obtained from increasing transformer capacity. It uses language prediction and downstream task performance as complementary views.

For language prediction, the authors evaluate dense autoregressive transformers spanning 125M to 13B parameters. These checkpoints were pretrained using fairseq. Their training sources include Books, English Wikipedia, and CC-News, together with OpenWebText. The remaining named sources are CC-Stories and English CC100. The evaluation then measures perplexity on the validation portion of C4, a corpus derived from Common Crawl.

Perplexity measures how well the predictor assigns probability to the observed text. Lower values indicate better prediction. It is useful here because quantization can disturb the probability distribution even when a particular highest-scoring answer remains unchanged. The authors treat it as a sensitive measure of numerical damage.

The C4 evaluation uses NVIDIA A40 GPUs. It compares the original floating-point computation with several integer quantization choices, including tensor-wise absmax, row-wise scaling, and zeropoint variants. Vector-wise quantization and the complete LLM.int8() method establish whether better normalization alone is sufficient or whether the exceptional-feature path is needed.

The second setup uses [OPT](https://md.research.elamur.ai/free/en/papers/zhang-2022-opt-open-pre-trained-transformer/) checkpoints and the EleutherAI evaluation harness. The headline figure aggregates zero-shot accuracy across WinoGrande, HellaSwag, PIQA, and LAMBADA. Zero-shot evaluation means that task-specific training examples are not used to adapt the checkpoint for each task in this comparison. The reference is its 16-bit behavior.

#### What happens as capacity increases

In the C4 experiment, ordinary quantization eventually reverses the desirable trend with scale. The paper reports that several lower-precision variants become worse after 2.7B parameters, so a larger converted checkpoint can predict less effectively than a smaller converted one. Zeropoint quantization is more resistant, but its advantage does not survive the largest evaluated language-modeling setting.

The complete LLM.int8() method preserves the evaluated perplexity trend through 13B parameters. Its vector-wise component supplies needed precision before the strongest outliers dominate, while decomposition prevents those outliers from determining the integer representation of the remaining values.

The text does not give the individual C4 perplexity cells in prose. Its results therefore support the reported ordering and scaling behavior without supporting an invented table of exact perplexities. The important conclusion is that preserving quality requires more than assigning additional normalization constants once the exceptional features become pervasive.

The OPT comparison extends the predictive test through 175B parameters. LLM.int8() follows the 16-bit reference across the evaluated scale range, while absmax vector-wise quantization deteriorates toward random task performance. This is the central evidence that the decomposition solves a practical inference problem beyond the smaller checkpoints used for the detailed feature analysis.

These findings should be read together. C4 provides a sensitive probability-based comparison among numerical schemes. The OPT tasks show that the same distinction matters for useful task accuracy. Agreement across these evaluations makes the case stronger than either an isolated arithmetic-error measurement or a single downstream score would.

#### A directly measured consequence of removing outliers

The intervention experiment supplies numerical evidence for why the special path is needed. The authors remove the selected outlier dimensions and examine the largest attention softmax probability. They report an approximate mean change from 40% to 20%.

Attention intervention, mean top-1 softmax probability, approximate values Keeping the exceptional dimensions preserves a substantially stronger leading attention probability.

**The numbers**

| System or setting | mean top-1 softmax probability % |
| --- | --- |
| Outlier dimensions retained, reference setting (this paper) | 40 |
| Outlier dimensions removed | 20 |

This chart concerns an internal attention statistic, not task accuracy. The values are approximate as stated by the authors, and the intervention is applied independently by layer to prevent errors from earlier modifications from contaminating the local comparison.

A separate experiment allows the altered hidden states to propagate through the transformer. There, removing the exceptional dimensions raises validation perplexity by 600-1000%. Removing random dimensions has a much smaller effect: the reported perplexity increase is about 0.1%.

The comparison explains why LLM.int8() protects the outliers rather than suppressing them. Their numerical extremity is not evidence that they are expendable. They occupy little representational space but make a disproportionate contribution to the measured computation.

#### Memory reduction and practical access

The paper reports roughly 50% lower memory consumption relative to the 16-bit representation targeted by the method. BLOOM-176B provides a concrete measured example, with a 1.96x reduction in its memory footprint.

The savings are close to the intuitive benefit of replacing most 16-bit weights with 8-bit weights, while allowing room for scales, exceptional dimensions, and operations outside the converted set. This is why the result is better described through the actual footprint than through an assumption that every part of inference has been halved.

The practical demonstration is that OPT-175B and BLOOM-176B can be accommodated on a single node using consumer GPUs. The significance is access to a checkpoint that would otherwise exceed the available memory. The paper’s appendix discusses hardware configurations, but the narrative evidence does not justify reconstructing precise device counts or capacities that are not explicitly supplied.

The authors connect this access to research using released checkpoints and prompting. A smaller memory requirement can let a researcher investigate behavior without reproducing the original training. The engineering contribution is therefore meaningful even when generation latency remains close to its previous value.

#### Runtime depends on what is included

The runtime study distinguishes raw integer multiplication from the complete numerical procedure. Integer arithmetic helps only after the matrices are large enough to use the GPU effectively. The appendix identifies a model dimension of 4096 or greater as the regime where this becomes relevant.

At a model dimension of 5140, with hidden size 20,560, the paper describes raw Int8 multiplication as two times faster than its comparison implementation. Including input quantization and output dequantization reduces the reported speedup to 1.6x. This is an important boundary on the result: the faster primitive is not the whole operation.

The overhead matters more for smaller matrices. At model dimensions of 2560 or below, the evaluated procedure slows the computation. Adding the mixed-precision path introduces further work; in the detailed benchmark discussion, only the 13B and 175B settings retain speedups after that addition.

The complete BLOOM-176B generation benchmark is more restrained still. It uses Hugging Face inference with cached attention values and distributed execution. The authors compare settings that can exploit the smaller footprint through fewer GPUs or a larger batch. Overall, integer inference is slightly slower, while remaining close to the reference in per-token latency.

This does not contradict the matrix benchmark. Generation includes communication and other work whose duration does not fall in proportion to the matrix arithmetic. The results establish a substantial memory advantage and conditional computational benefits, rather than a universal increase in generation speed.

### What the ablations show

#### Better scaling and decomposition solve different problems

The quantization comparisons act as a component study. Tensor-wise scaling, row-wise scaling, vector-wise scaling, and asymmetric mapping expose different ways to spend the available integer precision.

Vector-wise scaling improves the representation of both sides of each inner product. Its success through 2.7B parameters shows that more careful normalization is already valuable before the strongest outlier regime. Its later failure shows that normalization granularity alone, at this particular row–column arrangement, does not fully solve the problem.

Decomposition adds a different capability. It changes which values are subjected to integer quantization at all. The exceptional columns no longer force the ordinary input values to share their range. This is a structural intervention in the multiplication, rather than another choice of scale for the same undivided input.

The persistence of a vector-wise advantage over row-wise scaling after decomposition also matters. It indicates that protecting the exceptional input dimensions does not remove every precision requirement. Accurate treatment of weight columns remains useful. The complete method combines complementary improvements rather than relying on the bypass alone.

#### Asymmetric quantization reveals the shape of the difficulty

Zeropoint quantization performs better than symmetric alternatives over part of the scaling range. The outlier analysis offers an explanation: most exceptional dimensions have values confined to one side of zero.

A symmetric range wastes representational levels when a distribution is strongly one-sided. An asymmetric mapping makes better use of its integer values, which helps preserve the exceptional features for longer. This is why a baseline that differs only in its mapping can have a noticeably different scaling trend.

At 13B parameters, the authors report that even this approach fails. The magnitudes have grown, and the remaining quantization error accumulates enough to damage prediction. Asymmetry is part of the problem, but it is not its entire cause.

Once decomposition removes the exceptional dimensions from the integer path, zeropoint quantization loses its advantage. The authors interpret that result as evidence that the remaining values are sufficiently symmetric for absmax. This supports the final choice of an absmax-based method, avoiding the extra offset arithmetic where it no longer provides a predictive benefit.

#### Targeted removal establishes functional importance

The feature-removal experiments distinguish unusual values from important values. A distributional analysis could show that certain coordinates are large without showing that they matter. Setting them to zero tests their contribution more directly.

For attention, the authors intervene independently at each layer. They compare the altered attention statistic with its unaltered counterpart while forwarding the regular values onward. This avoids turning a local measurement into the combined effect of many earlier perturbations.

For language prediction, they deliberately allow the altered hidden states to propagate. That experiment measures the damage to the transformer’s overall predictive distribution. The large perplexity deterioration shows that the exceptional dimensions are not merely changing an internal diagnostic with little consequence for output.

Random feature removal provides the control. With 7 randomly chosen dimensions removed, the reported reduction in the leading attention probability is only 0.02-0.3%, and the perplexity increase is about 0.1%. The disparity supports selective protection of the outliers. It does not imply that every ordinary dimension is unimportant, only that the selected exceptional dimensions are unusually consequential under this intervention.

#### The apparent phase transition depends on the horizontal axis

The descriptive analysis tracks the same exceptional feature dimensions across layers and token positions. When organized by parameter count, the change appears abrupt between 6B and 6.7B parameters.

Across that interval, the fraction of affected layers rises from 65% to 100%. The affected sequence positions rise from 35% to 75%. This is also where the paper observes a sharp deterioration in ordinary quantization. The coincidence motivates the connection between widespread outliers and numerical failure.

The interpretation changes when the horizontal axis is C4 perplexity. Against better predictive performance, the authors describe a smoother exponential progression. Outlier counts are strictly monotonic with decreasing perplexity in the analyzed checkpoints, while their relationship with parameter count is not monotonic.

This is evidence against treating 6.7B as a universal numerical boundary determined by size alone. The authors suggest that training data quantity and quality may also matter, drawing on the [compute-optimal training](https://md.research.elamur.ai/free/en/papers/hoffmann-2022-training-compute-optimal-large-language/) and [autoregressive scaling](https://md.research.elamur.ai/free/en/papers/henighan-2020-scaling-laws-autoregressive-generative-modeling/) literature they cite. Their observations identify a useful relationship; they do not isolate the causal contribution of each training factor.

The smooth curves are descriptive fits to the observations. They help compare views of the same measurements, but they do not establish a law predicting the exact onset of outliers in every transformer family.

#### Checks across software and architecture

The authors investigate whether the feature pattern could be an implementation artifact. Their analysis includes checkpoints trained using OpenAI software, fairseq, and Tensorflow-Mesh. It also uses fairseq and Hugging Face Transformers for inference.

The analyzed collection contains four GPT-2 checkpoints and five Meta AI checkpoints, together with GPT-J from EleutherAI. Observing the same broad pattern across these sources weakens the explanation that a single training or inference codebase introduced the phenomenon.

The appendix also describes robustness to architectural variations involving rotary embeddings, embedding normalization, residual scaling, and initialization. These checks broaden the evidence, although they remain observations within the evaluated collection. They do not prove that every transformer or every future architecture must develop the same exceptional coordinates.

#### Training and fine-tuning expose a stricter regime

The appendix tests whether the inference result transfers to optimization. It compares Int8 configurations with 32-bit references, varying whether feed-forward layers, attention projections, or the attention function use integer computation.

Language-modeling experiments include 209M and 1.1B parameter settings. Attention-projection quantization is acceptable in the smaller setting but degrades the larger one. Translation experiments on WMT14+WMT16 show degradation as well. Mixed-precision decomposition helps slightly, but it generally does not restore the original performance.

The translation evaluation uses [BLEU](https://md.research.elamur.ai/free/en/concepts/bleu/) and reports the median across three random seeds. The fine-tuning study uses RoBERTa-large on GLUE, reporting median results over 5 seeds. These repeated optimization runs differ from the deterministic conversion experiments used for the main inference study.

For GLUE fine-tuning, low-precision feed-forward computation preserves performance. Quantizing attention projections requires a more substantial protected subset: the authors report that at least the top 2% of dimensions by magnitude must use 16-bit computation to avoid degradation.

The implication is specific. Selective precision remains useful beyond inference, but the small exceptional fraction sufficient for the main deployment result does not automatically suffice during learning. Optimization changes the numerical requirements.

### Limitations

#### Limits explicitly identified by the authors

The first stated boundary concerns the numerical format. The paper studies Int8 and does not evaluate FP8. Its discussion of the hardware support available during the work explains that choice, while its favorable expectations about floating-point alternatives remain expectations. The experiments cannot establish which format would be best under another hardware configuration.

The evaluated scale is another explicit limit. The authors demonstrate the method through 175B parameters in the main predictive claim, while also reporting BLOOM-176B deployment measurements. They acknowledge that still larger transformers might develop additional numerical properties that defeat the same procedure. The observed sparsity of troublesome dimensions is useful evidence, not a guarantee that the exceptional path will remain equally small indefinitely.

The attention function is outside the converted computation. Attention projections contain learned matrices, whereas the attention function itself does not contribute parameters in the same way. Since the primary objective is parameter-memory reduction, the authors leave that operation at higher precision. Their preliminary exploration suggests that quantizing it would need additional techniques.

Inference is the final major stated boundary. The paper includes exploratory training and fine-tuning experiments, so it would be inaccurate to say that learning is entirely unexamined. Those experiments do not establish a general solution. They instead show degradation in settings where the successful inference recipe is insufficient.

The authors also identify a broader distributional concern about access. Smaller memory requirements can help researchers with limited resources, but they can also let well-resourced organizations deploy more systems on their existing equipment. The technique alone does not determine whether access becomes more equal.

#### Limits that follow from the evaluation

A careful reader should distinguish matching benchmark performance from reproducing every floating-point result. Quantization contains rounding, and the reconstruction equations are approximate. Preserving C4 perplexity and the evaluated zero-shot accuracy does not establish bit-for-bit equality, identical probability distributions, or identical generated text for every input.

The detailed feature analysis also covers a narrower scale than the headline deployment result. Its analysis of persistence and exceptional-dimension counts extends through 13B parameters. The larger predictive and memory demonstrations support the method’s practicality, but they do not provide the same depth of internal characterization at every larger size.

The threshold is empirically selected. A magnitude cutoff of 6.0 works in the reported inference study, and the persistence criteria organize the descriptive analysis. Neither result proves that these choices transfer unchanged to another architecture, training distribution, or numerical implementation. The method offers a procedure for handling measured exceptions; its exact settings still require validation in a new setting.

The main inference comparisons do not include repeated-run uncertainty estimates. The checklist explains that the converted computation is deterministic for each checkpoint, so the authors evaluate different sizes rather than rerunning the same conversion. This is reasonable for the reported arithmetic comparison, but it does not measure variation across independently trained checkpoints with the same configuration.

The removal interventions have a further interpretive limit. They establish that selected coordinates matter when set to zero. That is a much stronger perturbation than an ordinary small rounding error. The experiments support protecting those coordinates, especially when combined with the successful decomposition results, but do not provide a complete quantitative map from every possible quantization error to final predictive damage.

#### Memory savings do not settle every deployment question

The reported footprint concerns the targeted inference implementation. It should not be extended automatically to every source of memory consumption, every input length, or every batching arrangement. The attention function remains outside the integer multiplication scheme, and the method does not claim to compress every intermediate object in generation.

Likewise, a matrix speedup is not a latency guarantee. The appendix explicitly shows the cost of quantization and decomposition, and the distributed BLOOM benchmark includes communication that the arithmetic optimization cannot eliminate. The practical trade can therefore be favorable even when generation is slightly slower: a checkpoint that fits is usable, while one that exceeds memory is not.

Finally, the paper does not establish that its particular feature phenomenon is the sole cause of low-precision difficulty. It identifies a dominant obstacle in the evaluated transformers and demonstrates an effective response. Training failures, the unquantized attention function, and the possibility of further emergent behavior all leave other numerical problems open.

### What came after

#### A direct continuation identified in the paper

The clearest documented transfer is [GLM-130B](https://md.research.elamur.ai/free/en/papers/zeng-2022-glm-130b-open-bilingual-pre/), which the authors describe as parallel work using their insights for performance-preserving 8-bit quantization. The implementation distinction is important: GLM-130B stores weights in 8-bit form but performs matrix multiplication in 16-bit precision.

That provides a concrete example of an idea traveling without the entire computational recipe traveling with it. The shared insight concerns the difficulty of compressing large-transformer values while retaining quality. The resulting system can make a different choice about where low precision applies. Weight storage and multiplication precision are separate design decisions.

This example also sharpens the meaning of LLM.int8(). Its contribution is not exhausted by saying that the weights occupy fewer bits. It includes an integer multiplication path and a separate floating-point path for exceptional dimensions. A later system can draw on the diagnosis while choosing another balance between storage and arithmetic.

#### Quantization research beyond the original inference setting

The subsequent citing works include [QLoRA: Efficient Finetuning of Quantized LLMs](https://md.research.elamur.ai/free/en/papers/dettmers-2023-qlora-efficient-finetuning-quantized-llms/). Its stated subject places quantization in the fine-tuning problem that LLM.int8() leaves open. That makes it a relevant continuation of the broader question: how can reduced-precision storage support useful work with large checkpoints beyond running an unchanged predictor? The citation alone does not establish that it uses the same threshold, decomposition, or arithmetic path.

[LLM-QAT: Data-Free Quantization Aware Training for Large Language Models](https://md.research.elamur.ai/free/en/papers/liu-2024-llm-qat-data-free-quantization/) addresses another direction named in the original discussion: adapting training procedures to quantization. Its title identifies a quantization-aware approach, in contrast with LLM.int8()’s goal of immediate conversion for inference. The relationship is a shared precision problem, with a different place for adaptation.

[OmniQuant: Omnidirectionally Calibrated Quantization for Large Language Models](https://md.research.elamur.ai/free/en/papers/shao-2023-omniquant-omnidirectionally-calibrated-quantization-large/) places calibration at the center of its stated approach. It belongs to the later quantization literature that cites LLM.int8(), but that fact does not establish whether it reproduces the outlier bypass. A citation can acknowledge a baseline, a diagnosis, or a neighboring technique without implying implementation inheritance.

Similarly, [Atom: Low-bit Quantization for Efficient and Accurate LLM Serving](https://md.research.elamur.ai/free/en/papers/zhao-2023-atom-low-bit-quantization-efficient/) links lower-precision computation with serving efficiency and accuracy. Its stated scope connects both sides of the original trade: numerical preservation and practical execution. The available relationship supports that connection, without supplying comparative results or a specific account of which LLM.int8() components it adopts.

These works show that quantization continued to be investigated through several engineering choices: immediate conversion, calibration, training, and serving. They should not be compressed into a single lineage in which every later method inherits the same mixed-precision design.

#### Other memory objects and other system bottlenecks

The original paper concentrates on large learned matrices. Later citing titles also identify memory held in the attention cache as a separate target. [KVQuant: Towards 10 Million Context Length LLM Inference with KV Cache Quantization](https://md.research.elamur.ai/free/en/papers/hooper-2024-kvquant-towards-10-million-context/) explicitly studies cache quantization, as does [KIVI: A Tuning-Free Asymmetric 2bit Quantization for KV Cache](https://md.research.elamur.ai/free/en/papers/liu-2024-kivi-tuning-free-asymmetric-2bit/).

These titles establish the different object being compressed. They do not establish that exceptional hidden-state columns, identified for LLM.int8() matrix multiplication, behave identically in cached attention values. The useful connection is the need to study the distribution and role of the particular data structure before selecting its representation.

The citing literature also includes [FlexGen: High-Throughput Generative Inference of Large Language Models with a Single GPU](https://md.research.elamur.ai/free/en/papers/sheng-2023-flexgen-high-throughput-generative-inference/). Its stated focus places the original memory-access problem inside a broader inference-system objective. [Splitwise: Efficient generative LLM inference using phase splitting](https://md.research.elamur.ai/free/en/papers/patel-2023-splitwise-efficient-generative-llm-inference/) and [Sarathi-Serve](https://md.research.elamur.ai/free/en/papers/agrawal-2024-taming-throughput-latency-tradeoff-llm/) identify phase organization and the throughput–latency tradeoff as further concerns.

The original runtime results help explain why those concerns belong alongside quantization. Arithmetic, memory capacity, communication, and execution organization can constrain different parts of generation. The later titles identify neighboring approaches to the overall deployment problem; their presence in the citation list does not supply evidence of a particular combination with LLM.int8().

#### A broader reference point, with a precise contribution

The citing collection extends to surveys, including [A Survey of Large Language Models](https://md.research.elamur.ai/free/en/papers/zhao-2023-survey-large-language-models/) and [A Comprehensive Overview of Large Language Models](https://md.research.elamur.ai/free/en/papers/naveed-2023-comprehensive-overview-large-language-models/). It also includes technical reports such as [Qwen](https://md.research.elamur.ai/free/en/papers/bai-2023-qwen-technical-report/) and [The Falcon Series](https://md.research.elamur.ai/free/en/papers/almazrouei-2023-falcon-series-open-language-models/). Their citations place LLM.int8() within the broader discussion of large-transformer development, without establishing that every reported system uses its implementation.

The strongest contribution to carry forward is more specific than a general endorsement of low precision. The paper connects a deployment failure to a measurable internal structure, demonstrates that the structure matters for prediction, and changes the arithmetic around it. Its later relevance can therefore take several forms: a numerical baseline, a reason to inspect outliers, a selective-precision design, or an example of evaluating memory savings together with predictive quality and complete runtime.

## Cite

Cite as Tim Dettmers, Mike Lewis, Younes Belkada and Luke Zettlemoyer. 2022. LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scale. arXiv:2208.07339.

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.48550/arxiv.2208.07339](https://doi.org/10.48550/arxiv.2208.07339) · [arXiv 2208.07339](https://arxiv.org/abs/2208.07339)

```bibtex
@misc{dettmers2022llm,
  title = {{LLM.int8(): 8-bit Matrix Multiplication for Transformers at Scale}},
  author = {Tim Dettmers, Mike Lewis, Younes Belkada and Luke Zettlemoyer},
  year = {2022},
  doi = {10.48550/arxiv.2208.07339},
  eprint = {2208.07339},
  archivePrefix = {arXiv},
  url = {https://doi.org/10.48550/arxiv.2208.07339}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
