Felipe97/llama-cpp-compiled
01.2k
1name: HIP quality check2 3on:4 workflow_dispatch: # allows manual triggering5 push:6 branches:7 - master8 paths: [9 '.github/workflows/hip-quality-check.yml',10 '**/*.cu',11 '**/*.cuh',12 'ggml/src/ggml-hip/CMakeLists.txt',13 'ggml/src/ggml-cuda/vendors/hip.h',14 'scripts/hip/gcn-cdna-vgpr-check.py'15 ]16 17 pull_request:18 types: [opened, synchronize, reopened]19 paths: [20 '.github/workflows/hip-quality-check.yml',21 '**/*.cu',22 '**/*.cuh',23 'ggml/src/ggml-hip/CMakeLists.txt',24 'ggml/src/ggml-cuda/vendors/hip.h',25 'scripts/hip/gcn-cdna-vgpr-check.py'26 ]27 28concurrency:29 group: ${{ github.workflow }}-${{ github.head_ref && github.ref || github.run_id }}30 cancel-in-progress: true31 32env:33 GGML_NLOOP: 334 GGML_N_THREADS: 135 LLAMA_ARG_LOG_COLORS: 136 LLAMA_ARG_LOG_PREFIX: 137 LLAMA_ARG_LOG_TIMESTAMPS: 138 39jobs:40 ubuntu-22-hip-quality-check:41 runs-on: ubuntu-22.0442 container: rocm/dev-ubuntu-22.04:7.2.143 steps:44 - name: Clone45 id: checkout46 uses: actions/checkout@v647 48 - name: Dependencies49 id: depends50 run: |51 sudo apt-get update52 sudo apt-get install -y build-essential git cmake rocblas-dev hipblas-dev libssl-dev python3 python3-venv python3-pip jq53 54 - name: ccache55 uses: ggml-org/ccache-action@v1.2.2456 with:57 key: hip-quality-check-ubuntu-22.0458 save: false59 60 - name: ccache-buckets-restore61 uses: ./.github/actions/ccache-buckets62 env:63 HF_TOKEN: ${{ secrets.HF_TOKEN_CI }}64 with:65 key: hip-quality-check-ubuntu-22.0466 folder: llama.cpp67 hf_bucket: ggml-org/cache68 69 - name: Build with Werror70 id: cmake_build71 run: |72 cmake -B build -S . \73 -DCMAKE_HIP_COMPILER="$(hipconfig -l)/clang" \74 -DGPU_TARGETS=gfx942 \75 -DGGML_HIP=ON \76 -DGGML_HIP_EXPORT_METRICS=Off \77 -DCMAKE_HIP_FLAGS="-Werror -Wno-tautological-compare" \78 -DCMAKE_BUILD_TYPE=Release79 cd build80 make -j $(nproc)81 82 - name: Check for major VGPR spills83 id: vgpr_check84 run: |85 cmake -B build -S . \86 -DCMAKE_HIP_COMPILER="$(hipconfig -l)/clang" \87 -DGPU_TARGETS=gfx908 \88 -DGGML_HIP=ON \89 -DGGML_HIP_EXPORT_METRICS=On \90 -DCMAKE_HIP_FLAGS="" \91 -DCMAKE_BUILD_TYPE=Release92 cd build93 make -j $(nproc) 2>&1 | tee metrics.log | grep -v 'Rpass-analysis=kernel-resource-usage\|remark:\|^$'94 python3 ../scripts/hip/gcn-cdna-vgpr-check.py metrics.log95 96 - name: ccache-buckets-save97 if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}98 uses: ./.github/actions/ccache-buckets99 env:100 HF_TOKEN: ${{ secrets.HF_TOKEN_CACHE_OUTPUT }}101 with:102 key: hip-quality-check-ubuntu-22.04103 folder: llama.cpp104 evict-old-files: 1d105 hf_bucket: ggml-org/cache106 save: true107 