开发者将 PyTorch 与 Mamba-1 移植至旧款英伟达 GPU
一名开发者宣布在 Windows 上将一套大模型训练栈移植至 SM 3.5 至 SM 7.5 的 NVIDIA GPU,包括采用 CUDA 11.8 的定制 PyTorch 2.7.1、移植版 causal-conv1d、原生 CUDA Mamba-1 和 Windows NCCL。作者称 Mamba-1 已支持这些架构,并在 2013 年 Tesla K40c 上取得相对 PyTorch 参考实现 3.8e-06 的最大绝对误差。Mamba-2 和 Mamba-3 依赖 Triton 与 TileLang,仅支持 Turing 及更新架构,旧硬件会自动回退至 Mamba-1。
该项目让用户可在许多现行 AI 软件栈已不再支持的旧款 NVIDIA 硬件上使用 PyTorch 和 Mamba,但其结果目前仅为开发者自报,社区实测范围仍然有限。
Hello!
I want to share an active development project. If you have a drawer full of old NVIDIA GPU's collecting dust because modern AI stacks refuse to compile for them, this is for you.
I have ported the modern LLM training stack on Windows to legacy CUDA GPUs (sm_35 through sm_75):
- PyTorch (v2.7.1) (custom build compiled with CUDA 11.8, keeping the legacy SASS) ([https://github.com/theIvanR/torch-on-clunkers])
- causal-conv1d (v1.7.0) (https://github.com/theIvanR/conv-on-clunkers)
- mamba_ssm (Mamba-1) with pure native CUDA kernels (https://github.com/theIvanR/mamba-on-clunkers)
- Windows NCCL (DDP) for multi-GPU training across Kepler cards (https://github.com/theIvanR/nccl-on-windows)
Status
- Mamba-1 (Pure CUDA): Fully functional with optimized execution across legacy GPU architectures (SM 3.5–SM 7.5). Tested on a 2013 NVIDIA Tesla K40c, achieving a maximum absolute error of
3.8e-06against the PyTorch reference implementation. - Mamba-2 & Mamba-3: Currently supported with optimized execution on Turing (SM 7.5) and newer architectures, due to their reliance on Triton and TileLang.
- Graceful Fallback: On older hardware, the package detects unavailable Triton-dependent modules and automatically falls back to the pure-CUDA Mamba-1 implementation.
#Mamba on Clunkers#NVIDIA#PyTorch#Mamba-1#Mamba-2#Mamba-3#causal-conv1d#NCCL#Triton#TileLang#Tesla K40c