char-fork/llama.cpp

git clone https://git.t4t.associates/char-fork/llama.cpp

Georgi Gerganovtests : add fusion baseline README and broaden fusion CI triggers (#28893)bbdd9f246

char/aliceai-t5-moe
1.8 KiB71 linesraw
1name: Fusion
2
3on:
4  workflow_dispatch: # allows manual triggering
5  push:
6    branches:
7      - master
8    paths: [
9      '.github/workflows/fusion.yml',
10      'ggml/**',
11      'tests/fusion/**',
12      'tests/test-fusion.cpp',
13      'tests/test-llama-archs.cpp',
14      'src/models/**'
15    ]
16
17  pull_request:
18    types: [opened, synchronize, reopened]
19    paths: [
20      '.github/workflows/fusion.yml',
21      'ggml/**',
22      'tests/fusion/**',
23      'tests/test-fusion.cpp',
24      'tests/test-llama-archs.cpp',
25      'src/models/**'
26    ]
27
28concurrency:
29  group: ${{ github.workflow }}-${{ github.head_ref && github.ref || github.run_id }}
30  cancel-in-progress: true
31
32env:
33  GGML_NLOOP: 3
34  GGML_N_THREADS: 1
35  LLAMA_ARG_LOG_COLORS: 1
36  LLAMA_ARG_LOG_PREFIX: 1
37  LLAMA_ARG_LOG_TIMESTAMPS: 1
38
39jobs:
40  # TODO: add jobs for other backends as they adopt the fusion debug API
41  metal:
42    runs-on: [self-hosted, macOS, ARM64]
43
44    steps:
45      - name: Clone
46        id: checkout
47        uses: actions/checkout@v6
48
49      - name: Build
50        id: cmake_build
51        run: |
52          cmake -B build \
53            -DCMAKE_BUILD_TYPE=Release \
54            -DLLAMA_FATAL_WARNINGS=ON \
55            -DLLAMA_OPENSSL=OFF \
56            -DGGML_SCHED_NO_REALLOC=ON \
57            -DGGML_BLAS=OFF \
58            -DGGML_METAL=ON
59          time cmake --build build --config Release --target test-llama-archs -j $(sysctl -n hw.logicalcpu)
60          time cmake --build build --config Release --target test-fusion -j $(sysctl -n hw.logicalcpu)
61
62      - name: Generate models
63        id: generate_models
64        run: |
65          rm -rf build-ci-models && mkdir -p build-ci-models
66          ./build/bin/test-llama-archs -o build-ci-models
67
68      - name: Test fusion
69        id: test_fusion
70        run: |
71          ./build/bin/test-fusion --models build-ci-models --device MTL0 --check tests/fusion/MTL.csv