Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
3168285f
Unverified
Commit
3168285f
authored
Nov 20, 2025
by
Fadi Arafeh
Committed by
GitHub
Nov 20, 2025
Browse files
[cpu][ci] Add initial set of tests for Arm CPUs (#28657)
Signed-off-by:
Fadi Arafeh
<
fadi.arafeh@arm.com
>
parent
3fb0d909
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
74 additions
and
0 deletions
+74
-0
.buildkite/scripts/hardware_ci/run-cpu-test-arm.sh
.buildkite/scripts/hardware_ci/run-cpu-test-arm.sh
+64
-0
docker/Dockerfile.cpu
docker/Dockerfile.cpu
+10
-0
No files found.
.buildkite/scripts/hardware_ci/run-cpu-test-arm.sh
0 → 100755
View file @
3168285f
#!/bin/bash
# This script build the CPU docker image and run the offline inference inside the container.
# It serves a sanity check for compilation and basic model usage.
set
-ex
# allow to bind to different cores
CORE_RANGE
=
${
CORE_RANGE
:-
0
-16
}
OMP_CORE_RANGE
=
${
OMP_CORE_RANGE
:-
0
-16
}
NUMA_NODE
=
${
NUMA_NODE
:-
0
}
export
CMAKE_BUILD_PARALLEL_LEVEL
=
32
# Setup cleanup
remove_docker_container
()
{
set
-e
;
docker
rm
-f
cpu-test-
"
$NUMA_NODE
"
||
true
;
}
trap
remove_docker_container EXIT
remove_docker_container
# Try building the docker image
numactl
-C
"
$CORE_RANGE
"
-N
"
$NUMA_NODE
"
docker build
--tag
cpu-test-
"
$NUMA_NODE
"
--target
vllm-test
-f
docker/Dockerfile.cpu
.
# Run the image, setting --shm-size=4g for tensor parallel.
docker run
-itd
--cpuset-cpus
=
"
$CORE_RANGE
"
--cpuset-mems
=
"
$NUMA_NODE
"
--entrypoint
/bin/bash
-v
~/.cache/huggingface:/root/.cache/huggingface
--privileged
=
true
-e
HF_TOKEN
--env
VLLM_CPU_KVCACHE_SPACE
=
16
--env
VLLM_CPU_CI_ENV
=
1
-e
E2E_OMP_THREADS
=
"
$OMP_CORE_RANGE
"
--shm-size
=
4g
--name
cpu-test-
"
$NUMA_NODE
"
cpu-test-
"
$NUMA_NODE
"
function
cpu_tests
()
{
set
-e
export
NUMA_NODE
=
$2
docker
exec
cpu-test-
"
$NUMA_NODE
"
bash
-c
"
set -e
pip list"
# offline inference
docker
exec
cpu-test-
"
$NUMA_NODE
"
bash
-c
"
set -e
python3 examples/offline_inference/basic/generate.py --model facebook/opt-125m"
# Run kernel tests
docker
exec
cpu-test-
"
$NUMA_NODE
"
bash
-c
"
set -e
pytest -x -v -s tests/kernels/test_onednn.py
pytest -x -v -s tests/kernels/attention/test_cpu_attn.py"
# basic online serving
docker
exec
cpu-test-
"
$NUMA_NODE
"
bash
-c
'
set -e
VLLM_CPU_OMP_THREADS_BIND=$E2E_OMP_THREADS vllm serve meta-llama/Llama-3.2-3B-Instruct --max-model-len 2048 &
server_pid=$!
timeout 600 bash -c "until curl localhost:8000/v1/models; do sleep 1; done" || exit 1
vllm bench serve \
--backend vllm \
--dataset-name random \
--model meta-llama/Llama-3.2-3B-Instruct \
--num-prompts 20 \
--endpoint /v1/completions
kill -s SIGTERM $server_pid &'
}
# All of CPU tests are expected to be finished less than 40 mins.
export
-f
cpu_tests
timeout
2h bash
-c
"cpu_tests
$CORE_RANGE
$NUMA_NODE
"
docker/Dockerfile.cpu
View file @
3168285f
...
...
@@ -37,6 +37,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
&& update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 10 --slave /usr/bin/g++ g++ /usr/bin/g++-12 \
&& curl -LsSf https://astral.sh/uv/install.sh | sh
ENV CC=/usr/bin/gcc-12 CXX=/usr/bin/g++-12
ENV CCACHE_DIR=/root/.cache/ccache
ENV CMAKE_CXX_COMPILER_LAUNCHER=ccache
...
...
@@ -122,6 +123,15 @@ WORKDIR /workspace/vllm
RUN --mount=type=bind,src=requirements/test.in,target=requirements/test.in \
cp requirements/test.in requirements/cpu-test.in && \
sed -i '/mamba_ssm/d' requirements/cpu-test.in && \
remove_packages_not_supported_on_aarch64() { \
case "$(uname -m)" in \
aarch64|arm64) \
sed -i '/decord/d' requirements/cpu-test.in; \
sed -i '/terratorch/d' requirements/cpu-test.in; \
;; \
esac; \
}; \
remove_packages_not_supported_on_aarch64 && \
sed -i 's/^torch==.*/torch==2.8.0/g' requirements/cpu-test.in && \
sed -i 's/torchaudio.*/torchaudio/g' requirements/cpu-test.in && \
sed -i 's/torchvision.*/torchvision/g' requirements/cpu-test.in && \
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment