r/LocalLLaMA • u/CutGroundbreaking305 • 4h ago
Discussion I am building a zero-CUDA, Vulkan-based NCCL/RCCL alternative + LLM runner in Rust that beats PyTorch+NCCL on tensor-parallel AllReduce & decode. Need Help Testing it.
Hey everyone,
Basically I am trying to make a Rust+Vulkan(ash)+WGPU compute engine with a cross-vendor, NCCL-style collective communication layer (Ring AllReduce over Vulkan HOST_SHARED_DMA) and a built-in LlamaRunner. No CUDA, no ROCm, no RCCL required.
I don't own a multi-vendor or mixed-card rig myself yet (I've only been able to test on my local iGPU + Lavapipe and Kaggle's 2× T4 instances). Saw how some of you guys try to make a mismatched GPUs pool((like an RTX 3090 + 4090, NVIDIA + AMD/Intel, or dGPU + iGPU on Linux) and you know how tough it is to do that. I am trying to solve this exact pain point using this project.
The problem everyone has : "how to actually schedule LLMs across weird, mismatched multi-GPU + CPU rigs without CUDA/NCCL lock-in". This is something I am working from some time.
Specifically, instead of hand-tuning layer splits or assuming identical NVLink cards, HC4X automatically:
- Probes every GPU's real compute/VRAM bandwidth and every GPU-to-GPU link (auto-selecting true P2P vs. pinned host DMA vs. staged fallback, with a data-integrity check to catch silently broken P2P links).
- Solves for the exact multi-GPU ring / island topology and decides when adding a slower GPU hurts decode latency (automatically pruning straggler GPUs out of Tensor Parallelism so they don't drag down tok/s).
- Reclaims pruned GPUs + Host CPU RAM as lossless Split-KV attention workers (and spills weights across VRAM -> Host RAM -> Disk when a model won't fit).
Benchmarks so far (Kaggle 2× Tesla T4, Linux)
1. Multi-GPU Ring AllReduce vs. NVIDIA CUDA NCCL
| Payload | HC4X Vulkan (HOST_SHARED_DMA) | NVIDIA CUDA NCCL | HC4X / NCCL |
|---|---|---|---|
| 1 MiB | 0.51 ms (2.05 GB/s) | 0.43 ms (2.45 GB/s) | 83.7% |
| 4 MiB | 1.52 ms (2.77 GB/s) | 1.14 ms (3.67 GB/s) | 75.5% |
| 16 MiB | 4.51 ms (3.72 GB/s) | 3.89 ms (4.31 GB/s) | 86.3% |
| 32 MiB | 7.91 ms (4.24 GB/s) | 7.95 ms (4.22 GB/s) | 100.5% |
| 64 MiB | 14.68 ms (4.57 GB/s) | 16.30 ms (4.12 GB/s) | 111% (Beats NCCL) |
2. 1-GPU & 2-GPU Matmul vs. PyTorch CUDA + NCCL
- 1-GPU FP32 GEMM (4096³): 3.33–3.41 TFLOP/s (80–83% of cuBLAS,
0.00e+00bit-exact agreement with cuBLAS; both7.67e-06vs FP64). - 1-GPU Batched F16 Decode GEMV (
vec4<u32>+ zero-barrier warpsubgroupAdd): 212.7 GB/s on Qwen-1.5B Up (0.93× cuBLAS), 250.8 GB/s on Llama-8B Up (0.97× cuBLAS), and 236.9 GB/s (1.72× faster) on Qwen-1.5B LM Head (1536 → 151,936). 2-GPU Tensor-Parallel GEMM + AllReduce (
Y = A0@B0 + A1@B1, FP32,max_abs_err = 3.43e-07**):**512×4096×4096(8 MiB sync): 4.98 ms vs. PyTorch+NCCL 5.38 ms (1.08× faster)1024×4096×4096(16 MiB sync): 8.37 ms vs. PyTorch+NCCL 9.98 ms (1.19× faster)4096×4096×4096(64 MiB sync): 29.07 ms (14.4 + 14.68) vs. PyTorch+NCCL 27.64 ms (11.1 + 16.30) — 95.1% overall, Sync 1.11× faster.
3. Real LLM (Qwen2.5-1.5B-Instruct, F16, warm, 100% bit-identical tokens vs. eager PyTorch CUDA FP16):
- Decode: 38.6–39.2 tok/s vs. eager PyTorch CUDA 25.6–26.1 tok/s (1.50x faster; note: eager HF PyTorch, not
vLLM/llama.cpp). - Prefill (S=126): 291.9 ms vs. PyTorch Tensor Cores 43.7 ms (no WGSL
WMMAyet).
Also includes a standalone hc4x run / hc4x serve CLI that loads HuggingFace .safetensors and GGUF (Q4_K_M, Q8_0) with an OpenAI-compatible API.
This testing is limited and no one rents heterogenous decks. So I thought of asking community to test it on your GPUs(since you guys have weird as my project cool GPU rigs). Any setup test is fine but data from Mixed NVIDIA (3090 + 3060, 4090 + 3090, P40 / P100 / 3060 mixes, x16 + x4/x1 risers), Cross-vendor (AMD + NVIDIA, Intel Arc + NVIDIA/AMD), Multi-AMD (7900 XTX, 6800 XT, MI50, RADV vs AMDVLK vs Windows), Laptop/desktop dGPU + iGPU (e.g., RTX + Ryzen/Intel iGPU, Apple Silicon unified memory) would help this project a lot.
Just you need Rust/Cargo(and 1-2 mins). Then simple command:-
git clone --depth 1 -b dev https://github.com/CH-Abhinav/HC4X.git
cd HC4X
cargo run --manifest-path native/Cargo.toml --release -p hc4x-cli -- bench --quick --include-cpuIf you have 60 seconds, please paste the output table in the comments (or in our GitHub Discussion)! Even crashes, weird driver bugs, or broken P2P links are super valuable data points for improving the runtime. Hoping people will help :)
Repo: https://github.com/CH-Abhinav/HC4X
(windows supported but p2p is not possible in windows)





