From 83085f103c7b03e73a2986b033f50aa7a6cff0b1 Mon Sep 17 00:00:00 2001 From: nimlgen <138685161+nimlgen@users.noreply.github.com> Date: Tue, 31 Mar 2026 19:49:38 +0300 Subject: [PATCH] tinygpu docs (#15545) * tinygpu docs * x * x * fix --- docs/tinygpu.md | 57 +++++++++++++++++++++++++++++++++++++++++++++++++ mkdocs.yml | 4 +++- 2 files changed, 60 insertions(+), 1 deletion(-) create mode 100644 docs/tinygpu.md diff --git a/docs/tinygpu.md b/docs/tinygpu.md new file mode 100644 index 0000000000..c187ee20fd --- /dev/null +++ b/docs/tinygpu.md @@ -0,0 +1,57 @@ +# TinyGPU + +TinyGPU app lets you use AMD and NVIDIA GPUs on macOS over USB4/Thunderbolt with tinygrad. + +## Requirements + +- macOS (12.1+) +- USB4/Thunderbolt port +- A supported GPU (AMD RDNA3+ or NVIDIA Ampere+) + +## Setup + +### 1. Connect your GPU + +Plug the supported GPU into your Mac over USB4/Thunderbolt. + +### 2. Initiate the driver install + +```bash +PYTHONPATH=. sh extra/setup_tinygpu_osx.sh +``` + +This downloads TinyGPU.app and triggers a system prompt to install the driver extension. + +### 3. Enable the driver + +You should see a system prompt: **"TinyGPU" would like to use a new driver extension**. Click **Open System Settings** and toggle TinyGPU on. + +If you missed the prompt, go to **System Settings > General > Login Items & Extensions > Driver Extensions** and toggle TinyGPU on. + +### 4. Compiler Setup + +#### AMD + +```bash +curl -fsSL https://raw.githubusercontent.com/tinygrad/tinygrad/master/extra/setup_hipcomgr_osx.sh | sh +``` + +#### NV + +Install [Docker Desktop](https://www.docker.com/products/docker-desktop/) if you don't have it. + +```bash +curl -fsSL https://raw.githubusercontent.com/tinygrad/tinygrad/master/extra/setup_nvcc_osx.sh | sh +``` + +Make sure `~/.local/bin` is on your `PATH`: + +```bash +export PATH="$HOME/.local/bin:$PATH" +``` + +### 5. Use it! + +```bash +DEV={AMD|NV} python3 tinygrad/apps/llm.py +``` diff --git a/mkdocs.yml b/mkdocs.yml index 721ff1a48c..b71f38e83d 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -19,7 +19,9 @@ nav: - dtypes: dtypes.md - nn (Neural Networks): nn.md - Environment Variables: env_vars.md - - Runtime: runtime.md + - Runtime: + - runtime.md + - egpu for mac: tinygpu.md - Developer: - Intro: developer/developer.md - Layout: developer/layout.md