Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .github/workflows/cuda-build-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,12 @@ jobs:
- name: Cache Rust
uses: Swatinem/rust-cache@v2
with:
cache-bin: false
prefix-key: v1-rust-no-bin
save-if: ${{ github.ref_name == 'main' || github.ref_name == 'master' || github.ref_name == 'development' || github.ref_name == 'dev' }}

- name: Install CUDA Toolkit
uses: Jimver/cuda-toolkit@v0.2.30
uses: Jimver/cuda-toolkit@v0.2.35
id: cuda-toolkit
with:
cuda: '12.6.3'
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/go-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
os: [ubuntu-latest, windows-2022, macOS-latest]
go-version: ["stable"] # Latest stable (experimental bindings)

steps:
Expand All @@ -54,13 +54,14 @@ jobs:
- name: Cache Rust
uses: Swatinem/rust-cache@v2
with:
cache-bin: false
prefix-key: v1-rust-no-bin
workspaces: go/pecos-go-ffi

- name: Set up Visual Studio environment on Windows
if: runner.os == 'Windows'
uses: ilammy/msvc-dev-cmd@v1
with:
arch: x64
shell: pwsh
run: ./scripts/ci/setup-msvc.ps1 -Arch x64 -HostArch x64

- name: Build Rust FFI library (Windows)
if: runner.os == 'Windows'
Expand Down
15 changes: 7 additions & 8 deletions .github/workflows/julia-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ jobs:
- os: macos-latest
architecture: aarch64
runner: macos-latest # ARM64 Mac
- os: windows-latest
- os: windows-2022
architecture: x86_64

steps:
Expand Down Expand Up @@ -144,9 +144,8 @@ jobs:

- name: Set up Visual Studio environment on Windows
if: runner.os == 'Windows'
uses: ilammy/msvc-dev-cmd@v1
with:
arch: x64
shell: pwsh
run: ./scripts/ci/setup-msvc.ps1 -Arch x64 -HostArch x64

- name: Build library (Windows)
if: runner.os == 'Windows'
Expand Down Expand Up @@ -249,8 +248,8 @@ jobs:
- runner: ubuntu-latest
os: ubuntu-latest
architecture: x86_64
- runner: windows-latest
os: windows-latest
- runner: windows-2022
os: windows-2022
architecture: x86_64
- runner: macos-15-intel
os: macos-15-intel
Expand All @@ -264,7 +263,7 @@ jobs:
ref: ${{ inputs.sha || github.sha }}

- name: Set up Julia ${{ matrix.julia-version }}
uses: julia-actions/setup-julia@v2
uses: julia-actions/setup-julia@v3
with:
version: ${{ matrix.julia-version }}

Expand Down Expand Up @@ -342,7 +341,7 @@ jobs:
ref: ${{ inputs.sha || github.sha }}

- name: Set up Julia
uses: julia-actions/setup-julia@v2
uses: julia-actions/setup-julia@v3
with:
version: '1.10'

Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/julia-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,14 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
os: [ubuntu-latest, windows-2022, macOS-latest]
julia-version: ["1"] # Latest stable (experimental bindings)

steps:
- uses: actions/checkout@v6

- name: Set up Julia ${{ matrix.julia-version }}
uses: julia-actions/setup-julia@v2
uses: julia-actions/setup-julia@v3
with:
version: ${{ matrix.julia-version }}

Expand Down Expand Up @@ -90,13 +90,14 @@ jobs:
- name: Cache Rust
uses: Swatinem/rust-cache@v2
with:
cache-bin: false
prefix-key: v1-rust-no-bin
workspaces: julia/pecos-julia-ffi

- name: Set up Visual Studio environment on Windows
if: runner.os == 'Windows'
uses: ilammy/msvc-dev-cmd@v1
with:
arch: x64
shell: pwsh
run: ./scripts/ci/setup-msvc.ps1 -Arch x64 -HostArch x64

- name: Build Rust FFI library (Windows)
if: runner.os == 'Windows'
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/python-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -118,16 +118,15 @@ jobs:
# Set up Visual Studio environment on Windows (required for nvcc to find cl.exe)
- name: Set up Visual Studio environment (Windows)
if: runner.os == 'Windows' && matrix.install_cuda
uses: ilammy/msvc-dev-cmd@v1
with:
arch: x64
shell: pwsh
run: ./scripts/ci/setup-msvc.ps1 -Arch x64 -HostArch x64

# Install CUDA on Windows before cibuildwheel (cibuildwheel runs on host, not in containers)
# Uses specific sub-packages to avoid VS 17.3.x bug that hangs on NSight/VS Integration
# See: https://github.com/Jimver/cuda-toolkit/issues/382
- name: Install CUDA Toolkit (Windows)
if: runner.os == 'Windows' && matrix.install_cuda
uses: Jimver/cuda-toolkit@v0.2.30
uses: Jimver/cuda-toolkit@v0.2.35
with:
cuda: '12.5.1'
method: 'local'
Expand Down Expand Up @@ -336,7 +335,7 @@ jobs:
- runner: ubuntu-latest
os: ubuntu-latest
architecture: x86_64
- runner: windows-latest
- runner: windows-2022
os: windows-2022
architecture: x86_64
- runner: macos-15-intel
Expand Down
69 changes: 32 additions & 37 deletions .github/workflows/python-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ jobs:
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
include:
# Windows/macOS: only test oldest and newest stable Python (slow platforms)
- os: windows-latest
- os: windows-2022
python-version: "3.10"
- os: windows-latest
- os: windows-2022
python-version: "3.14"
- os: macOS-latest
python-version: "3.10"
Expand Down Expand Up @@ -74,41 +74,52 @@ jobs:

- name: Set up Visual Studio environment on Windows
if: runner.os == 'Windows'
uses: ilammy/msvc-dev-cmd@v1
with:
arch: x64
shell: pwsh
run: ./scripts/ci/setup-msvc.ps1 -Arch x64 -HostArch x64

- name: Install the latest version of uv
uses: astral-sh/setup-uv@v7
with:
version: "0.11.14"
enable-cache: true

- name: Set up Rust
run: rustup show
- name: Set up Rust (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
curl -sSf -o rustup-init.exe https://win.rustup.rs
./rustup-init.exe -y --default-toolchain stable --default-host x86_64-pc-windows-msvc --profile minimal
"$HOME\.cargo\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
$env:Path += ";$HOME\.cargo\bin"
rustup show

- name: Set up Rust (Unix)
if: runner.os != 'Windows'
run: |
curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain stable --profile minimal
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
export PATH="$HOME/.cargo/bin:$PATH"
rustup show

- name: Install just
uses: extractions/setup-just@v3
uses: extractions/setup-just@v4

- name: Cache Rust
uses: Swatinem/rust-cache@v2
with:
cache-bin: false
prefix-key: v1-rust-no-bin
workspaces: |
python/pecos-rslib
python/pecos-rslib-llvm

# Cache LLVM installation (fixed version, only varies by OS)
- name: Cache LLVM ${{ env.LLVM_VERSION }}
id: cache-llvm
uses: actions/cache@v4
uses: actions/cache@v5
with:
path: ~/.pecos/deps/llvm-14
key: llvm-${{ env.LLVM_VERSION }}-${{ runner.os }}-${{ runner.arch }}

# Install LLVM first (needed before CLI install since inkwell requires LLVM_SYS_140_PREFIX)
# Use cargo run for LLVM install — only builds pecos+pecos-build, not the full workspace
- name: Install LLVM ${{ env.LLVM_VERSION }} (Unix)
if: steps.cache-llvm.outputs.cache-hit != 'true' && runner.os != 'Windows'
run: cargo run -p pecos-cli --release -- install llvm
key: llvm-${{ env.LLVM_VERSION }}-${{ runner.os }}-${{ runner.arch }}-v2

# Configure MSVC linker BEFORE any cargo build (Git's link.exe conflicts with MSVC's)
- name: Configure MSVC linker (Windows)
Expand All @@ -129,32 +140,16 @@ jobs:
exit 1
}

- name: Install LLVM ${{ env.LLVM_VERSION }} (Windows)
if: steps.cache-llvm.outputs.cache-hit != 'true' && runner.os == 'Windows'
run: cargo run -p pecos-cli --release -- install llvm

# Configure LLVM environment
- name: Configure LLVM environment (Unix)
if: runner.os != 'Windows'
run: |
PECOS_LLVM=$(cargo run -p pecos-cli --release -- llvm find 2>/dev/null)
echo "PECOS_LLVM=$PECOS_LLVM" >> $GITHUB_ENV
echo "LLVM_SYS_140_PREFIX=$PECOS_LLVM" >> $GITHUB_ENV
- name: Ensure LLVM ${{ env.LLVM_VERSION }}
run: just ci-env

- name: Configure LLVM environment (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
$env:PECOS_LLVM = (cargo run -p pecos-cli --release -- llvm find 2>$null)
$env:LLVM_SYS_140_PREFIX = $env:PECOS_LLVM
"PECOS_LLVM=$env:PECOS_LLVM" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
"LLVM_SYS_140_PREFIX=$env:LLVM_SYS_140_PREFIX" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append

# Add LLVM bin to PATH
$llvmBinDir = Join-Path -Path $env:PECOS_LLVM -ChildPath "bin"
if (Test-Path $llvmBinDir) {
"$llvmBinDir" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
}
# Rewrite .cargo/config.toml with both linker and LLVM config
# (`pecos env --github-actions` sets LLVM_SYS_140_PREFIX for following steps.)
$env:PECOS_LLVM = $env:LLVM_SYS_140_PREFIX

# Rewrite .cargo/config.toml with both linker and LLVM config
# (pecos install llvm may have already written this, so overwrite cleanly)
Expand Down
Loading
Loading