What hybrid models interleave
Hybrid models interleave state-space model (SSM) layers with a few attention layers. [1]
Why SSM layers can still bottleneck
SSM layers are designed to make decoding fast: they use a fixed-size state in place of a key-value (KV) cache that grows with context length. [2]
At serving batch sizes, however, the SSM layers, not attention, can be the latency bottleneck up to 100K tokens of context. [3]
What bounds an SSM decoding step
An SSM decoding step loads and stores the full state while performing little arithmetic on it, so the kernel is bound by HBM bandwidth, not compute. [4]
Sources
- The NVIDIA source says: Hybrid models interleave state-space model (SSM) layers with a few attention layers. ReplaySSM
- The NVIDIA source says: SSM layers are designed to make decoding fast: they use a fixed-size state in place of a key-value (KV) cache that grows with context length. ReplaySSM
- The NVIDIA source says: At serving batch sizes, however, the SSM layers, not attention, can be the latency bottleneck up to 100K tokens of context. ReplaySSM
- The NVIDIA source says: An SSM decoding step loads and stores the full state while performing little arithmetic on it, so the kernel is bound by HBM bandwidth, not compute. ReplaySSM