FFN vs. Attention FLOPs: The Hidden Cost Ratio

In standard Transformer blocks, the Feed-Forward Network (FFN) typically accounts for 60% to 75% of the total Floating Point Operations (FLOPs), significantly out-costing the Attention mechanism, especially in larger language models where Attention's quadratic terms become less dominant.

Sources

Open the full topic