torch-tbccl¶
torch-tbccl is a PyTorch torch.distributed backend named "tbccl". It lets one PyTorch program communicate between machines that differ in operating system and accelerator, for example a Linux host with an NVIDIA GPU and a Mac with Apple silicon, over TCP including a direct Thunderbolt 4 link. PyTorch is not modified: import torch_tbccl and use the normal distributed API.
Note
Release. The current release is 0.3.1 (PyTorch 2.13.x, CPython 3.13, TBCCL C ABI 1 / wire protocol 4), whose wheels bundle TBCCL 0.7.1. It is experimental.
What you get¶
The normal distributed API
dist.init_process_group("tbccl") with torchrun, process groups and DistributedDataParallel. Your program keeps using torch.distributed.
Collectives and devices
Point-to-point, broadcast, all_gather, all_reduce (SUM only) and barrier on CPU, CUDA (Linux) and MPS (macOS) tensors.
DDP across unlike machines
Train with DistributedDataParallel on CPU, CUDA and, next to a CPU or CUDA rank, MPS ranks.
Built on TBCCL
The wheel contains a statically linked libtbccl, so you do not install TBCCL separately.
Get started¶
What is supported¶
Only configurations that were actually exercised are listed as validated. Everything else is not supported or not claimed.
Validated
PyTorch 2.13.x and CPython 3.13 on Linux x86-64 (CPU, and CUDA with the CUDA 13 build of PyTorch) and macOS arm64 (CPU and MPS).
A Linux CUDA host and a Mac with MPS over a direct Thunderbolt 4 link: point-to-point,
all_reduce,broadcast,all_gatherandbarrier, in both rank orientations.World sizes 1 to 4, and DDP, on loopback and (on the development tree) between a CUDA and an MPS rank.
Not supported or not claimed
SUMis the only reduction; there is noreduce,scatter,reduce_scatterorall_to_all, andgatherworks for two-rank groups only.No recovery after an abort or a peer failure; recreate the process group.
FSDP and world sizes 5 to 8 are not validated; two Linux hosts over a physical network are not part of the recorded validation.
Other PyTorch and CPython versions are not claimed.
Authoritative pages: compatibility, validated configurations and known limitations.
Where it fits¶
torch-tbccl is one of three independent adapters over the TBCCL runtime; the others are vllm-tbccl (vLLM) and exo-tbccl (exo). It does not depend on them and they do not depend on it. See the ecosystem overview.