Skip to content

Fix dangling suffix pointer in tracked library info #397

Fix dangling suffix pointer in tracked library info

Fix dangling suffix pointer in tracked library info #397

Workflow file for this run

name: CI
on:
push:
branches:
- main
tags: ['*']
pull_request:
workflow_dispatch:
concurrency:
# Cancel in-progress runs for the same PR / branch, but never on `main`.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
permissions:
contents: read
jobs:
test:
name: ${{ matrix.backend }} / ${{ matrix.os }} / julia ${{ matrix.julia-version }}
runs-on: ${{ matrix.os }}
timeout-minutes: 10
strategy:
fail-fast: false
matrix:
# Each BLAS/LAPACK backend is tested in its own job (and its own process, with
# its own `test/backends/<backend>/Project.toml`) so that only a single set of
# BLAS/LAPACK libraries is ever loaded at once.
backend: [openblas, mkl, refblas, blis, blas64, accelerate, direct]
os: [ubuntu-latest, ubuntu-24.04-arm, windows-latest, macos-latest, macos-15-intel]
julia-version: ['1.10', 'nightly']
exclude:
# MKL is x86_64-only.
- {backend: mkl, os: ubuntu-24.04-arm}
- {backend: mkl, os: macos-latest}
# Accelerate is a macOS-only system framework.
- {backend: accelerate, os: ubuntu-latest}
- {backend: accelerate, os: ubuntu-24.04-arm}
- {backend: accelerate, os: windows-latest}
# blas64 uses the Debian `libblas64-dev`/`liblapack64-dev` packages.
- {backend: blas64, os: windows-latest}
- {backend: blas64, os: macos-latest}
- {backend: blas64, os: macos-15-intel}
# blis_jll has no Windows build we exercise here.
- {backend: blis, os: windows-latest}
# Reference BLAS DLLs are not yet resolvable on Windows.
- {backend: refblas, os: windows-latest}
# Only the core `openblas` and `direct` backends run on nightly; every other
# backend runs on the 1.10 LTS only.
- {backend: mkl, julia-version: 'nightly'}
- {backend: refblas, julia-version: 'nightly'}
- {backend: blis, julia-version: 'nightly'}
- {backend: blas64, julia-version: 'nightly'}
- {backend: accelerate, julia-version: 'nightly'}
steps:
- uses: actions/checkout@v6
- uses: julia-actions/setup-julia@v3
with:
version: ${{ matrix.julia-version }}
arch: ${{ (matrix.os == 'ubuntu-24.04-arm' || matrix.os == 'macos-latest') && 'aarch64' || 'x64' }}
- uses: julia-actions/cache@v3
# The `blas64` backend tests against a system-provided ILP64 reference BLAS/LAPACK.
- name: Install system libblas64 / liblapack64 (Debian)
if: matrix.backend == 'blas64'
run: |
sudo apt-get update
sudo apt-get install -y libblas64-dev liblapack64-dev
# Windows needs a MinGW toolchain (gcc + make) to build the C test programs and
# libblastrampoline itself.
- uses: msys2/setup-msys2@v2
id: msys2
if: runner.os == 'Windows'
with:
msystem: MINGW64
path-type: inherit
install: >-
make
mingw-w64-x86_64-gcc
- name: Add MSYS2 tools to PATH (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
Add-Content -Path $env:GITHUB_PATH -Value "${{ steps.msys2.outputs.msys2-location }}\mingw64\bin"
Add-Content -Path $env:GITHUB_PATH -Value "${{ steps.msys2.outputs.msys2-location }}\usr\bin"
- name: Instantiate ${{ matrix.backend }} project
run: julia --project=test/backends/${{ matrix.backend }} -e 'import Pkg; Pkg.instantiate()'
- name: Run ${{ matrix.backend }} tests
run: julia --project=test/backends/${{ matrix.backend }} test/runtests.jl ${{ matrix.backend }}
# 32-bit (i686) Linux and Windows: GitHub only offers 64-bit runners, so we install a
# 32-bit Julia on the x86_64 runner (Pkg then resolves i686 JLL artifacts) and build the
# C tests / libblastrampoline as 32-bit (`-m32` on Linux via gcc-multilib; a native i686
# MinGW toolchain on Windows).
test-32bit:
name: ${{ matrix.backend }} / ${{ matrix.os }} (i686) / julia ${{ matrix.julia-version }}
runs-on: ${{ matrix.os }}
timeout-minutes: 10
strategy:
fail-fast: false
matrix:
backend: [openblas, refblas, direct]
os: [ubuntu-latest, windows-latest]
julia-version: ['1.10', 'nightly']
exclude:
# Reference BLAS DLLs are not yet resolvable on Windows.
- {backend: refblas, os: windows-latest}
# Only the core `openblas` and `direct` backends run on nightly.
- {backend: refblas, julia-version: 'nightly'}
steps:
- uses: actions/checkout@v6
- uses: julia-actions/setup-julia@v3
with:
version: ${{ matrix.julia-version }}
arch: x86
- uses: julia-actions/cache@v3
# Linux: a 64-bit gcc with multilib can target i686 via `-m32` (utils.jl's
# `needs_m32()` adds it automatically when GCC is 64-bit but Julia is 32-bit).
- name: Install 32-bit build support (Debian)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y gcc-multilib
# Windows: use a native i686 MinGW toolchain (MINGW32) so the C tests and
# libblastrampoline are built as 32-bit directly.
- uses: msys2/setup-msys2@v2
id: msys2
if: runner.os == 'Windows'
with:
msystem: MINGW32
path-type: inherit
install: >-
make
mingw-w64-i686-gcc
- name: Add MSYS2 tools to PATH (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
Add-Content -Path $env:GITHUB_PATH -Value "${{ steps.msys2.outputs.msys2-location }}\mingw32\bin"
Add-Content -Path $env:GITHUB_PATH -Value "${{ steps.msys2.outputs.msys2-location }}\usr\bin"
- name: Instantiate ${{ matrix.backend }} project
run: julia --project=test/backends/${{ matrix.backend }} -e 'import Pkg; Pkg.instantiate()'
- name: Run ${{ matrix.backend }} tests
run: julia --project=test/backends/${{ matrix.backend }} test/runtests.jl ${{ matrix.backend }}
func-list-idempotency:
name: func_list idempotency
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@v6
- name: Regenerate func_list and check for diff
run: |
cd ext/gensymbol
./generate_func_list.sh
git diff --exit-code