ci : move sanitizer jobs to self-hosted runners (#23713)

This commit is contained in:
Georgi Gerganov
2026-05-26 15:22:09 +03:00
committed by GitHub
parent 3dc7684f39
commit ef41a69179
3 changed files with 49 additions and 39 deletions
+30 -21
View File
@@ -27,61 +27,70 @@ env:
LLAMA_LOG_TIMESTAMPS: 1 LLAMA_LOG_TIMESTAMPS: 1
jobs: jobs:
ubuntu-latest-sanitizer: ctest:
runs-on: ubuntu-latest runs-on: [self-hosted, CPU, Linux]
continue-on-error: true continue-on-error: true
strategy: strategy:
matrix: matrix:
sanitizer: [ADDRESS, THREAD, UNDEFINED] sanitizer: [ADDRESS, THREAD, UNDEFINED]
build_type: [Debug]
steps: steps:
- name: Clone - name: Clone
id: checkout id: checkout
uses: actions/checkout@v6 uses: actions/checkout@v6
- name: ccache #- name: ccache
uses: ggml-org/ccache-action@v1.2.21 # uses: ggml-org/ccache-action@v1.2.21
with: # with:
key: ubuntu-latest-sanitizer-${{ matrix.sanitizer }} # key: ubuntu-latest-sanitizer-${{ matrix.sanitizer }}
evict-old-files: 1d # evict-old-files: 1d
save: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }} # save: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
- name: Dependencies #- name: Dependencies
id: depends # id: depends
# run: |
# sudo apt-get update
# sudo apt-get install build-essential libssl-dev
# with UNDEFINED sanitizer, we have to build in Debug to avoid GCC 13 false-positive warnings
- name: Build (undefined)
id: cmake_build_undefined
if: ${{ matrix.sanitizer == 'UNDEFINED' }}
run: | run: |
sudo apt-get update cmake -B build \
sudo apt-get install build-essential libssl-dev -DLLAMA_FATAL_WARNINGS=ON \
-DLLAMA_SANITIZE_${{ matrix.sanitizer }}=ON \
-DGGML_SANITIZE_${{ matrix.sanitizer }}=ON
cmake --build build --config Debug -j $(nproc)
- name: Build - name: Build
id: cmake_build id: cmake_build
if: ${{ matrix.sanitizer != 'THREAD' }} if: ${{ matrix.sanitizer != 'THREAD' }}
run: | run: |
cmake -B build \ cmake -B build \
-DLLAMA_FATAL_WARNINGS=ON \
-DLLAMA_SANITIZE_${{ matrix.sanitizer }}=ON \ -DLLAMA_SANITIZE_${{ matrix.sanitizer }}=ON \
-DGGML_SANITIZE_${{ matrix.sanitizer }}=ON \ -DGGML_SANITIZE_${{ matrix.sanitizer }}=ON
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
cmake --build build --config ${{ matrix.build_type }} -j $(nproc) cmake --build build --config RelWithDebInfo -j $(nproc)
- name: Build (no OpenMP) - name: Build (no OpenMP)
id: cmake_build_no_openmp id: cmake_build_no_openmp
if: ${{ matrix.sanitizer == 'THREAD' }} if: ${{ matrix.sanitizer == 'THREAD' }}
run: | run: |
cmake -B build \ cmake -B build \
-DLLAMA_FATAL_WARNINGS=ON \
-DLLAMA_SANITIZE_${{ matrix.sanitizer }}=ON \ -DLLAMA_SANITIZE_${{ matrix.sanitizer }}=ON \
-DGGML_SANITIZE_${{ matrix.sanitizer }}=ON \ -DGGML_SANITIZE_${{ matrix.sanitizer }}=ON \
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
-DGGML_OPENMP=OFF -DGGML_OPENMP=OFF
cmake --build build --config ${{ matrix.build_type }} -j $(nproc) cmake --build build --config RelWithDebInfo -j $(nproc)
- name: Test - name: Test
id: cmake_test id: cmake_test
# skip run in Debug - very slow
if: ${{ matrix.sanitizer != 'UNDEFINED' }}
run: | run: |
cd build cd build
ctest -L main --verbose --timeout 900 ctest -L main -E tokenizer --verbose --timeout 900
+14 -14
View File
@@ -37,7 +37,7 @@ concurrency:
jobs: jobs:
server: server:
runs-on: ubuntu-latest runs-on: [self-hosted, CPU, Linux, llama-server]
strategy: strategy:
matrix: matrix:
@@ -46,19 +46,19 @@ jobs:
fail-fast: false fail-fast: false
steps: steps:
- name: Dependencies #- name: Dependencies
id: depends # id: depends
run: | # run: |
sudo apt-get update # sudo apt-get update
sudo apt-get -y install \ # sudo apt-get -y install \
build-essential \ # build-essential \
xxd \ # xxd \
git \ # git \
cmake \ # cmake \
curl \ # curl \
wget \ # wget \
language-pack-en \ # language-pack-en \
libssl-dev # libssl-dev
- name: Clone - name: Clone
id: checkout id: checkout
+5 -4
View File
@@ -630,10 +630,11 @@ std::optional<gguf_remote_model> gguf_fetch_model_meta(
} }
for (int i = 2; i <= model.n_split; i++) { for (int i = 2; i <= model.n_split; i++) {
char num_buf[6], total_buf[6]; char buf_num[32];
snprintf(num_buf, sizeof(num_buf), "%05d", i); char buf_tot[32];
snprintf(total_buf, sizeof(total_buf), "%05d", (int)model.n_split); snprintf(buf_num, sizeof(buf_num), "%05d", i);
std::string shard_name = split_prefix + "-" + num_buf + "-of-" + total_buf + ".gguf"; snprintf(buf_tot, sizeof(buf_tot), "%05d", (int)model.n_split);
std::string shard_name = split_prefix + "-" + buf_num + "-of-" + buf_tot + ".gguf";
auto shard = fetch_or_cached(repo, shard_name, cdir, repo_part, verbose); auto shard = fetch_or_cached(repo, shard_name, cdir, repo_part, verbose);
if (!shard.has_value()) { if (!shard.has_value()) {