Install MIGraphX#

2026-11-27

15 min read time

Applies to Linux

Installing MIGraphX using prebuilt packages is sufficient for most users who want to use the MIGraphX API. If you plan to develop for MIGraphX or contribute to the source code, see Developing for MIGraphX.

Installation method

Prerequisites#

MIGraphX 2.20.0 is currently supported on:

  • gfx950 AMD Instinct MI355X, MI350X, and MI350P

  • gfx942 AMD Instinct MI325X, MI300X, and MI300A

  • gfx90a AMD Instinct MI250X, MI250, and MI210

  • gfx1200, gfx1201, gfx1100, gfx1101, gfx1102, and gfx1103 Radeon GPUs.

  • gfx1153, gfx1152, gfx1151, and gfx1150 Ryzen AI processors.

See the ROCm 10.2.0 compatibility matrix for more information.

Install MIGraphX on Linux#

MIGraphX requires ROCm to be installed on your system first.

Install ROCm#

For instructions, see Install AMD ROCm 10.2.0. Use the selector panel on that page to view instructions appropriate for your system environment.

Build MIGraphX from source#

Note

For reproducibility, we recommend using the provided Docker environment with MIGraphX build prerequisites preinstalled. See Build MIGraphX in a Docker container.

See the MIGraphX README for more information.

  1. Complete the appropriate ROCm installation prerequisites for your system environment and register AMD package repositories.

  2. Install required ROCm development packages:

    sudo apt install amdrocm-runtime-dev10.2 \
        amdrocm-blas-dev10.2 \
        amdrocm-blas-host10.2 \
        amdrocm-dnn-dev10.2 \
        amdrocm-dnn-host10.2 \
        amdrocm-hipblas-common-dev10.2 \
        amdrocm-core10.2
    
    sudo dnf install amdrocm-runtime-devel10.2 \
        amdrocm-blas-devel10.2 \
        amdrocm-blas-host10.2 \
        amdrocm-dnn-devel10.2 \
        amdrocm-dnn-host10.2 \
        amdrocm-hipblas-common-devel10.2 \
        amdrocm-core10.2
    
    sudo zypper install amdrocm-runtime-devel10.2 \
        amdrocm-blas-devel10.2 \
        amdrocm-blas-host10.2 \
        amdrocm-dnn-devel10.2 \
        amdrocm-dnn-host10.2 \
        amdrocm-hipblas-common-devel10.2 \
        amdrocm-core10.2
    

    amdrocm-core provides the GPU device code and links /opt/rocm/bin, /opt/rocm/llvm, and the other /opt/rocm entry points to this release, so the paths used in the remaining steps resolve.

    Note

    amdrocm-core10.2 installs the device code for every supported architecture. Append your GPU’s architecture to install only the device code that architecture needs, which is a much smaller download:

    sudo apt install amdrocm-core10.2-gfx942
    

    Run rocminfo | grep -o -m1 'gfx.*' to find the architecture of an installed GPU. The suffixed package sets up the same /opt/rocm links.

  3. Install the host build tools. The ROCm packages don’t provide CMake, Git, or the Python headers and venv module that the following steps need.

    sudo apt install build-essential cmake git pkg-config \
        python3-dev python3-pip python3-venv
    
    sudo dnf install gcc-c++ make cmake git \
        python3-devel python3-pip
    
    sudo zypper install gcc-c++ make cmake git \
        python3-devel python3-pip
    
  4. Clone the MIGraphX source code:

    git clone https://github.com/ROCm/AMDMIGraphX.git
    cd AMDMIGraphX
    
  5. Install rbuild into a Python virtual environment.

    On Python 3.14 or newer, install cget from source.

    python3 -m venv venv_rbuild
    source venv_rbuild/bin/activate
    
    pip install https://github.com/pfultz2/cget/archive/master.tar.gz
    pip install https://github.com/ROCm/rbuild/archive/master.tar.gz
    
  6. Build MIGraphX source code. Run this from the root of the checkout, because rbuild builds the source directory you invoke it from:

    rbuild build -d depend -B build -DGPU_TARGETS=$(/opt/rocm/bin/rocminfo | grep -o -m1 'gfx.*')
    

Once completed, all prerequisites are in the depend folder and MIGraphX is in the build directory.

If you plan to develop for MIGraphX or contribute to the source code, see Developing for MIGraphX.