ROCmigrator is an autonomous engineering agent that transforms PyTorch CUDA C++ extensions into verified AMD ROCm/HIP implementations. It addresses a critical challenge in GPU software portability: translating CUDA code is only the beginning. A reliable migration must also compile, execute correctly, preserve numerical accuracy, and produce reviewable changes. ROCmigrator implements an explicit 12-stage state machine covering repository acquisition, security scanning, CUDA analysis, CPU reference generation, deterministic HIPIFY conversion, real HIP compilation, GPU verification, benchmarking, reporting, human approval, and GitHub pull request creation. The system combines a Next.js frontend, FastAPI backend, Pydantic-validated contracts, isolated Docker execution, and a bounded AI-assisted repair mechanism. Deterministic tools are prioritized; AI repair is invoked only when necessary and remains subject to strict limits. We validated ROCmigrator on a real AMD Instinct MI300X VF (gfx942) using AMD Developer Cloud. The Golden 01 CUDA extension was successfully transformed, compiled with the ROCm HIP toolchain, and executed on AMD hardware. All 18 numerical comparisons passed across three random seeds, three tensor shapes, and float32/float64 data types. CPU reference verification and determinism checks also passed. The successful run required zero AI repair rounds. After verification, ROCmigrator paused for explicit human approval. Only after approval did the agent create GitHub Pull Request #1 containing the migrated changes and verification evidence. ROCmigrator demonstrates a complete CUDA-to-ROCm engineering workflow: from source transformation to real GPU execution, numerical validation, and human-controlled delivery.
Category tags: