@@ -339,6 +339,180 @@ jobs:
339339 path : llama-bench-win-cuda-${{ matrix.cuda }}-x64.zip
340340 name : llama-bench-win-cuda-${{ matrix.cuda }}-x64.zip
341341
342+ ubuntu-cpu :
343+ strategy :
344+ matrix :
345+ include :
346+ - build : ' x64'
347+ os : ubuntu-22.04
348+ - build : ' arm64'
349+ os : ubuntu-22.04-arm
350+ # Non-public runners - commented out:
351+ # - build: 's390x'
352+ # os: ubuntu-24.04-s390x
353+ # - build: 'ppc64le'
354+ # os: ubuntu-24.04-ppc64le
355+
356+ runs-on : ${{ matrix.os }}
357+
358+ steps :
359+ - name : Clone
360+ id : checkout
361+ uses : actions/checkout@v4
362+
363+ - name : ccache
364+ uses : ggml-org/ccache-action@v1.2.16
365+ with :
366+ key : ubuntu-cpu-bench-${{ matrix.build }}
367+ evict-old-files : 1d
368+
369+ - name : Build
370+ id : cmake_build
371+ run : |
372+ cmake -B build \
373+ -DCMAKE_BUILD_TYPE=Release \
374+ -DGGML_NATIVE=OFF \
375+ -DGGML_BACKEND_DL=ON \
376+ -DLLAMA_CURL=OFF \
377+ -DGGML_OPENMP=ON \
378+ -DLLAMA_BUILD_TOOLS=ON \
379+ -DLLAMA_BUILD_EXAMPLES=OFF \
380+ -DLLAMA_BUILD_TESTS=OFF \
381+ -DLLAMA_BUILD_SERVER=OFF
382+ cmake --build build --config Release --target llama-bench -j $(nproc)
383+
384+ - name : Pack artifacts
385+ id : pack_artifacts
386+ run : |
387+ cd build/bin
388+ tar -czvf ../../llama-bench-ubuntu-cpu-${{ matrix.build }}.tar.gz ./*
389+
390+ - name : Upload artifacts
391+ uses : actions/upload-artifact@v4
392+ with :
393+ path : llama-bench-ubuntu-cpu-${{ matrix.build }}.tar.gz
394+ name : llama-bench-ubuntu-cpu-${{ matrix.build }}.tar.gz
395+ if-no-files-found : error
396+
397+ ubuntu-vulkan :
398+ runs-on : ubuntu-24.04
399+
400+ steps :
401+ - name : Clone
402+ id : checkout
403+ uses : actions/checkout@v4
404+
405+ - name : ccache
406+ uses : ggml-org/ccache-action@v1.2.16
407+ with :
408+ key : ubuntu-24-vulkan-bench
409+ evict-old-files : 1d
410+
411+ - name : Dependencies
412+ id : depends
413+ run : |
414+ sudo add-apt-repository -y ppa:kisak/kisak-mesa
415+ sudo apt-get update -y
416+ sudo apt-get install -y build-essential mesa-vulkan-drivers libxcb-xinput0 libxcb-xinerama0 libxcb-cursor-dev
417+
418+ - name : Get latest Vulkan SDK version
419+ id : vulkan_sdk_version
420+ run : |
421+ echo "VULKAN_SDK_VERSION=$(curl https://vulkan.lunarg.com/sdk/latest/linux.txt)" >> "$GITHUB_ENV"
422+
423+ - name : Use Vulkan SDK Cache
424+ uses : actions/cache@v4
425+ id : cache-sdk
426+ with :
427+ path : ./vulkan_sdk
428+ key : vulkan-sdk-${{ env.VULKAN_SDK_VERSION }}-${{ runner.os }}
429+
430+ - name : Setup Vulkan SDK
431+ if : steps.cache-sdk.outputs.cache-hit != 'true'
432+ uses : ./.github/actions/linux-setup-vulkan
433+ with :
434+ path : ./vulkan_sdk
435+ version : ${{ env.VULKAN_SDK_VERSION }}
436+
437+ - name : Build
438+ id : cmake_build
439+ run : |
440+ source ./vulkan_sdk/setup-env.sh
441+ cmake -B build \
442+ -DCMAKE_BUILD_TYPE=Release \
443+ -DGGML_NATIVE=OFF \
444+ -DGGML_CPU=OFF \
445+ -DGGML_BACKEND_DL=ON \
446+ -DGGML_VULKAN=ON \
447+ -DLLAMA_CURL=OFF
448+ cmake --build build --config Release --target ggml-vulkan -j $(nproc)
449+
450+ - name : Pack artifacts
451+ id : pack_artifacts
452+ run : |
453+ cd build/bin
454+ tar -czvf ../../llama-bench-ubuntu-vulkan-x64.tar.gz ./*
455+
456+ - name : Upload artifacts
457+ uses : actions/upload-artifact@v4
458+ with :
459+ path : llama-bench-ubuntu-vulkan-x64.tar.gz
460+ name : llama-bench-ubuntu-vulkan-x64.tar.gz
461+ if-no-files-found : error
462+
463+ ubuntu-cuda :
464+ runs-on : ubuntu-latest
465+ container : nvidia/cuda:12.6.2-devel-ubuntu24.04
466+
467+ strategy :
468+ matrix :
469+ cuda : ['12.6']
470+
471+ steps :
472+ - name : Clone
473+ id : checkout
474+ uses : actions/checkout@v4
475+
476+ - name : Install dependencies
477+ env :
478+ DEBIAN_FRONTEND : noninteractive
479+ run : |
480+ apt update
481+ apt install -y cmake build-essential ninja-build libgomp1 git
482+
483+ - name : ccache
484+ uses : ggml-org/ccache-action@v1.2.16
485+ with :
486+ key : ubuntu-cuda-bench-${{ matrix.cuda }}
487+ evict-old-files : 1d
488+
489+ - name : Build
490+ id : cmake_build
491+ run : |
492+ cmake -S . -B build -G Ninja \
493+ -DCMAKE_BUILD_TYPE=Release \
494+ -DCMAKE_CUDA_ARCHITECTURES=89-real \
495+ -DCMAKE_EXE_LINKER_FLAGS=-Wl,--allow-shlib-undefined \
496+ -DGGML_NATIVE=OFF \
497+ -DGGML_CPU=OFF \
498+ -DGGML_BACKEND_DL=ON \
499+ -DGGML_CUDA=ON \
500+ -DLLAMA_CURL=OFF
501+ cmake --build build --config Release --target ggml-cuda
502+
503+ - name : Pack artifacts
504+ id : pack_artifacts
505+ run : |
506+ cd build/bin
507+ tar -czvf ../../llama-bench-ubuntu-cuda-${{ matrix.cuda }}-x64.tar.gz ./*
508+
509+ - name : Upload artifacts
510+ uses : actions/upload-artifact@v4
511+ with :
512+ path : llama-bench-ubuntu-cuda-${{ matrix.cuda }}-x64.tar.gz
513+ name : llama-bench-ubuntu-cuda-${{ matrix.cuda }}-x64.tar.gz
514+ if-no-files-found : error
515+
342516 release :
343517 if : ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/benchmarks' ) || github.event.inputs.create_release == 'true' }}
344518
@@ -355,6 +529,9 @@ jobs:
355529 - windows-cpu
356530 - windows
357531 - windows-cuda
532+ - ubuntu-cpu
533+ - ubuntu-vulkan
534+ - ubuntu-cuda
358535
359536 steps :
360537 - name : Clone
@@ -432,6 +609,7 @@ jobs:
432609
433610 echo "Moving other artifacts..."
434611 mv -v artifact/*.zip release/ || true
612+ mv -v artifact/*.tar.gz release/ || true
435613
436614 # Rename remaining artifacts to include tag
437615 cd release
@@ -446,6 +624,17 @@ jobs:
446624 fi
447625 done
448626
627+ for f in llama-bench-*.tar.gz; do
628+ # Skip already renamed files
629+ if [[ "$f" == *"${{ steps.tag.outputs.name }}"* ]]; then
630+ continue
631+ fi
632+ if [ -f "$f" ]; then
633+ newname="llama-bench-${{ steps.tag.outputs.name }}-${f#llama-bench-}"
634+ mv "$f" "$newname"
635+ fi
636+ done
637+
449638 - name : Create release
450639 id : create_release
451640 uses : ggml-org/action-create-release@v1
@@ -464,7 +653,8 @@ jobs:
464653 const fs = require('fs');
465654 const release_id = '${{ steps.create_release.outputs.id }}';
466655 for (let file of await fs.readdirSync('./release')) {
467- if (path.extname(file) === '.zip') {
656+ const ext = path.extname(file);
657+ if (ext === '.zip' || ext === '.gz') {
468658 console.log('uploadReleaseAsset', file);
469659 await github.repos.uploadReleaseAsset({
470660 owner: context.repo.owner,
0 commit comments