A high-throughput and memory-efficient inference and serving engine for LLMs
Mirrored from https://github.com/tduncan-lum/Nvidia-Optimization-Stack---VLLM.git
Synced Nov 14, 05:30 UTC
[ROCm][CI/Build] Use ROCm7.0 as the base (#25178)
Signed-off-by: Gregory Shtrasberg <Gregory.Shtrasberg@amd.com>
Gregory Shtrasberg committed
Sep 18, 2025 at 12:36 UTC
dc3405936090f5c964a5b38c9de8c8400f01541c
2 files changed
+16
-50
docker/Dockerfile.rocm
+4
-1
@@ -29,7 +29,10 @@ ARG VLLM_BRANCH="main"
29
ONBUILD RUN git clone ${VLLM_REPO} \
30
&& cd vllm \
31
&& git fetch -v --prune -- origin ${VLLM_BRANCH} \
32
- && git checkout FETCH_HEAD
32
+ && git checkout FETCH_HEAD \
33
+ && if [ ${VLLM_REPO} != "https://github.com/vllm-project/vllm.git" ] ; then \
34
+ git remote add upstream "https://github.com/vllm-project/vllm.git" \
35
+ && git fetch upstream ; fi
36
FROM fetch_vllm_${REMOTE_VLLM} AS fetch_vllm
37
38
# -----------------------
docker/Dockerfile.rocm_base
+12
-49
@@ -1,25 +1,23 @@
1
-ARG BASE_IMAGE=rocm/dev-ubuntu-22.04:6.4.1-complete
2
-ARG HIPBLASLT_BRANCH="aa0bda7b"
3
-ARG HIPBLAS_COMMON_BRANCH="9b80ba8e"
4
-ARG LEGACY_HIPBLASLT_OPTION=
5
-ARG TRITON_BRANCH="e5be006"
6
-ARG TRITON_REPO="https://github.com/triton-lang/triton.git"
7
-ARG PYTORCH_BRANCH="f717b2af"
8
-ARG PYTORCH_VISION_BRANCH="v0.21.0"
1
+ARG BASE_IMAGE=rocm/dev-ubuntu-22.04:7.0-complete
2
+ARG TRITON_BRANCH="f9e5bf54"
3
+ARG TRITON_REPO="https://github.com/ROCm/triton.git"
4
+ARG PYTORCH_BRANCH="b2fb6885"
5
+ARG PYTORCH_VISION_BRANCH="v0.23.0"
6
ARG PYTORCH_REPO="https://github.com/ROCm/pytorch.git"
7
ARG PYTORCH_VISION_REPO="https://github.com/pytorch/vision.git"
11
-ARG FA_BRANCH="1a7f4dfa"
8
+ARG FA_BRANCH="0e60e394"
9
ARG FA_REPO="https://github.com/Dao-AILab/flash-attention.git"
13
-ARG AITER_BRANCH="4822e675"
10
+ARG AITER_BRANCH="2ab9f4cd"
11
ARG AITER_REPO="https://github.com/ROCm/aiter.git"
12
13
FROM ${BASE_IMAGE} AS base
14
18
-ENV PATH=/opt/rocm/llvm/bin:$PATH
15
+ENV PATH=/opt/rocm/llvm/bin:/opt/rocm/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
16
ENV ROCM_PATH=/opt/rocm
17
ENV LD_LIBRARY_PATH=/opt/rocm/lib:/usr/local/lib:
21
-ARG PYTORCH_ROCM_ARCH=gfx90a;gfx942;gfx1100;gfx1101;gfx1200;gfx1201
18
+ARG PYTORCH_ROCM_ARCH=gfx90a;gfx942;gfx950;gfx1100;gfx1101;gfx1200;gfx1201
19
ENV PYTORCH_ROCM_ARCH=${PYTORCH_ROCM_ARCH}
20
+ENV AITER_ROCM_ARCH=gfx942;gfx950
21
22
ARG PYTHON_VERSION=3.12
23
@@ -45,29 +43,6 @@ RUN apt-get update -y \
43
44
RUN pip install -U packaging 'cmake<4' ninja wheel 'setuptools<80' pybind11 Cython
45
48
-FROM base AS build_hipblaslt
49
-ARG HIPBLASLT_BRANCH
50
-ARG HIPBLAS_COMMON_BRANCH
51
-# Set to "--legacy_hipblas_direct" for ROCm<=6.2
52
-ARG LEGACY_HIPBLASLT_OPTION
53
-RUN git clone https://github.com/ROCm/hipBLAS-common.git
54
-RUN apt-get remove -y hipblaslt && apt-get autoremove -y && apt-get autoclean -y
55
-RUN cd hipBLAS-common \
56
- && git checkout ${HIPBLAS_COMMON_BRANCH} \
57
- && mkdir build \
58
- && cd build \
59
- && cmake .. \
60
- && make package \
61
- && dpkg -i ./*.deb
62
-RUN git clone https://github.com/ROCm/hipBLASLt
63
-RUN cd hipBLASLt \
64
- && git checkout ${HIPBLASLT_BRANCH} \
65
- && apt-get install -y llvm-dev \
66
- && ./install.sh -dc --architecture ${PYTORCH_ROCM_ARCH} ${LEGACY_HIPBLASLT_OPTION} \
67
- && cd build/release \
68
- && make package
69
-RUN mkdir -p /app/install && cp /app/hipBLASLt/build/release/*.deb /app/hipBLAS-common/build/*.deb /app/install
70
-
46
FROM base AS build_triton
47
ARG TRITON_BRANCH
48
ARG TRITON_REPO
@@ -121,13 +96,11 @@ RUN cd aiter \
96
&& git checkout ${AITER_BRANCH} \
97
&& git submodule update --init --recursive \
98
&& pip install -r requirements.txt
124
-RUN pip install pyyaml && cd aiter && PREBUILD_KERNELS=1 GPU_ARCHS=gfx942 python3 setup.py bdist_wheel --dist-dir=dist && ls /app/aiter/dist/*.whl
99
+RUN pip install pyyaml && cd aiter && PREBUILD_KERNELS=1 GPU_ARCHS=${AITER_ROCM_ARCH} python3 setup.py bdist_wheel --dist-dir=dist && ls /app/aiter/dist/*.whl
100
RUN mkdir -p /app/install && cp /app/aiter/dist/*.whl /app/install
101
102
FROM base AS debs
103
RUN mkdir /app/debs
129
-RUN --mount=type=bind,from=build_hipblaslt,src=/app/install/,target=/install \
130
- cp /install/*.deb /app/debs
104
RUN --mount=type=bind,from=build_triton,src=/app/install/,target=/install \
105
cp /install/*.whl /app/debs
106
RUN --mount=type=bind,from=build_amdsmi,src=/app/install/,target=/install \
@@ -138,11 +111,6 @@ RUN --mount=type=bind,from=build_aiter,src=/app/install/,target=/install \
111
cp /install/*.whl /app/debs
112
113
FROM base AS final
141
-RUN --mount=type=bind,from=build_hipblaslt,src=/app/install/,target=/install \
142
- dpkg -i /install/*deb \
143
- && perl -p -i -e 's/, hipblas-common-dev \([^)]*?\), /, /g' /var/lib/dpkg/status \
144
- && perl -p -i -e 's/, hipblaslt-dev \([^)]*?\), /, /g' /var/lib/dpkg/status \
145
- && perl -p -i -e 's/, hipblaslt \([^)]*?\), /, /g' /var/lib/dpkg/status
114
RUN --mount=type=bind,from=build_triton,src=/app/install/,target=/install \
115
pip install /install/*.whl
116
RUN --mount=type=bind,from=build_amdsmi,src=/app/install/,target=/install \
@@ -153,9 +121,6 @@ RUN --mount=type=bind,from=build_aiter,src=/app/install/,target=/install \
121
pip install /install/*.whl
122
123
ARG BASE_IMAGE
156
-ARG HIPBLAS_COMMON_BRANCH
157
-ARG HIPBLASLT_BRANCH
158
-ARG LEGACY_HIPBLASLT_OPTION
124
ARG TRITON_BRANCH
125
ARG TRITON_REPO
126
ARG PYTORCH_BRANCH
@@ -167,9 +132,6 @@ ARG FA_REPO
132
ARG AITER_BRANCH
133
ARG AITER_REPO
134
RUN echo "BASE_IMAGE: ${BASE_IMAGE}" > /app/versions.txt \
170
- && echo "HIPBLAS_COMMON_BRANCH: ${HIPBLAS_COMMON_BRANCH}" >> /app/versions.txt \
171
- && echo "HIPBLASLT_BRANCH: ${HIPBLASLT_BRANCH}" >> /app/versions.txt \
172
- && echo "LEGACY_HIPBLASLT_OPTION: ${LEGACY_HIPBLASLT_OPTION}" >> /app/versions.txt \
135
&& echo "TRITON_BRANCH: ${TRITON_BRANCH}" >> /app/versions.txt \
136
&& echo "TRITON_REPO: ${TRITON_REPO}" >> /app/versions.txt \
137
&& echo "PYTORCH_BRANCH: ${PYTORCH_BRANCH}" >> /app/versions.txt \
@@ -177,5 +139,6 @@ RUN echo "BASE_IMAGE: ${BASE_IMAGE}" > /app/versions.txt \
139
&& echo "PYTORCH_REPO: ${PYTORCH_REPO}" >> /app/versions.txt \
140
&& echo "PYTORCH_VISION_REPO: ${PYTORCH_VISION_REPO}" >> /app/versions.txt \
141
&& echo "FA_BRANCH: ${FA_BRANCH}" >> /app/versions.txt \
142
+ && echo "FA_REPO: ${FA_REPO}" >> /app/versions.txt \
143
&& echo "AITER_BRANCH: ${AITER_BRANCH}" >> /app/versions.txt \
144
&& echo "AITER_REPO: ${AITER_REPO}" >> /app/versions.txt
\ No newline at end of file