mac and linux threads

This commit is contained in:
Eve 2023-09-22 22:19:31 +00:00 committed by GitHub
parent bc9d3e3971
commit 537ff64a61
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -19,7 +19,10 @@ env:
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
GGML_NLOOP: 3
GGML_N_THREADS: 1
LINHOST_THR: 2
MACHOST_THR: 3
WINHOST_THR: 2
jobs:
ubuntu-focal-make:
runs-on: ubuntu-20.04
@ -38,13 +41,13 @@ jobs:
- name: Build
id: make_build
run: |
CC=gcc-8 make
CC=gcc-8 make -j${LINHOST_THR}
- name: Test
id: make_test
run: |
CC=gcc-8 make tests
make test
CC=gcc-8 make tests -j${LINHOST_THR}
make test -j${LINHOST_THR}
ubuntu-latest-cmake:
runs-on: ubuntu-latest
@ -66,7 +69,7 @@ jobs:
mkdir build
cd build
cmake ..
cmake --build . --config Release
cmake --build . --config Release -j${LINHOST_THR}
- name: Test
id: cmake_test
@ -101,7 +104,7 @@ jobs:
mkdir build
cd build
cmake .. -DLLAMA_SANITIZE_${{ matrix.sanitizer }}=ON -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
cmake --build . --config ${{ matrix.build_type }}
cmake --build . --config ${{ matrix.build_type }} -j${LINHOST_THR}
- name: Test
id: cmake_test
@ -135,7 +138,7 @@ jobs:
mkdir build
cd build
cmake -DLLAMA_MPI=ON ..
cmake --build . --config Release
cmake --build . --config Release -j${LINHOST_THR}
- name: Test
id: cmake_test
@ -160,13 +163,13 @@ jobs:
- name: Build
id: make_build
run: |
make
make -j${MACHOST_THR}
- name: Test
id: make_test
run: |
make tests
make test
make tests -j${MACHOST_THR}
make test -j${MACHOST_THR}
macOS-latest-cmake:
runs-on: macos-latest
@ -189,7 +192,7 @@ jobs:
mkdir build
cd build
cmake -DLLAMA_AVX2=OFF -DLLAMA_FMA=OFF ..
cmake --build . --config Release
cmake --build . --config Release -j${MACHOST_THR}
- name: Test
id: cmake_test
@ -223,7 +226,7 @@ jobs:
-DLLAMA_BUILD_SERVER=OFF \
-DCMAKE_SYSTEM_NAME=iOS \
-DCMAKE_OSX_DEPLOYMENT_TARGET=14.0
cmake --build . --config Release
cmake --build . --config Release -j${MACHOST_THR}
macOS-latest-cmake-tvos:
runs-on: macos-latest
@ -251,7 +254,7 @@ jobs:
-DLLAMA_BUILD_SERVER=OFF \
-DCMAKE_SYSTEM_NAME=tvOS \
-DCMAKE_OSX_DEPLOYMENT_TARGET=14.0
cmake --build . --config Release
cmake --build . --config Release -j${MACHOST_THR}
windows-latest-cmake:
runs-on: windows-latest