Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
1ae469c
[Refactor][NFC] Vendor in _DispatcherBase for CUDA-specific changes
VijayKandiah Aug 4, 2025
bde7128
[Refactor][WIP] Vendoring in dispatcher cext for CUDA-specific changes
VijayKandiah Aug 5, 2025
e0c2ea8
[Refactor][NFC] _dispatcher cext: Re-enable array handling, invoke ty…
VijayKandiah Aug 5, 2025
edeed47
[Refactor][NFC] Trim CUDA _dispatcher cext
VijayKandiah Aug 5, 2025
df14bad
[Refactor][NFC] Remove sysmon from _dispatcher cext
VijayKandiah Aug 5, 2025
0f7c9a7
[Refactor][NFC] Changes to build _dispatcher cext with pip install -e .
VijayKandiah Aug 6, 2025
21fd506
Add numpy build dep to conda/recipes/numba-cuda
VijayKandiah Aug 6, 2025
3bcdaad
[Refactor][NFC] Add _devicearray, mviewbuf cext, move all cexts to to…
VijayKandiah Aug 8, 2025
5c80d56
Update CI numpy version reqs and build matrix
VijayKandiah Aug 12, 2025
22a41f8
Fix numpy ver requirements
VijayKandiah Aug 12, 2025
47e5b18
Remove additional configs in build-matrix and simulator-matrix
VijayKandiah Aug 12, 2025
52da47e
Fix setup.py build_commands list
VijayKandiah Aug 12, 2025
366b3d7
Make numba_cuda.cext a package
gmarkall Aug 19, 2025
487e872
Modify build matrix for each Python version
gmarkall Aug 19, 2025
42bea6a
Move cext to numba_cuda.numba.cuda and enable build matrix for arm64
VijayKandiah Aug 26, 2025
7cfe7c3
Make py3.9 arm64 and amd64 builds use cuda_ver 11.8.0
VijayKandiah Aug 26, 2025
88c0b2c
Make py3.9 a supported python version for cext.
VijayKandiah Aug 26, 2025
970e5bc
Make CI build-docs and simulator workflows point to correct build
VijayKandiah Aug 26, 2025
afaea07
Make CI scripts point to the right conda-repo-py dirs
VijayKandiah Aug 26, 2025
f9d9e22
Change numpy ver for py3.9 build to 2.0.2 to support 1.x and 2.x
VijayKandiah Aug 27, 2025
24c5fda
CI with pip install -e to ensure C extensions are properly linked
VijayKandiah Aug 27, 2025
f289d12
Fix CI build
VijayKandiah Aug 27, 2025
3c48a3d
Hack C extensions into import mechanism
ashermancinelli Aug 29, 2025
618a885
Fix redirector
ashermancinelli Aug 29, 2025
582b66e
Shorten CI runs for development
ashermancinelli Aug 30, 2025
203e152
Debugging CI
ashermancinelli Aug 30, 2025
ce8bc89
Merge branch 'main' of github.com:NVIDIA/numba-cuda into vk/dispatche…
ashermancinelli Aug 30, 2025
12026f8
Use platform-dependent wheel path
gmarkall Sep 2, 2025
4dba8db
Build modules in cext
gmarkall Sep 2, 2025
486dfae
Don't use editable install in conda build
gmarkall Sep 2, 2025
a93e465
Use correct search path for C extensions
gmarkall Sep 2, 2025
58b6cae
Merge remote-tracking branch 'NVIDIA/main' into vk/dispatcher-ext
gmarkall Sep 2, 2025
9b59060
Remove debug prints
gmarkall Sep 2, 2025
1658db6
COrrect conda-repo location
gmarkall Sep 2, 2025
6349ad7
Again try to correct conda repo location
gmarkall Sep 3, 2025
727e6f8
Correct usage of `download-artifact`
gmarkall Sep 3, 2025
dc1bbb8
Revert "Again try to correct conda repo location"
gmarkall Sep 3, 2025
fc3c577
Revert "COrrect conda-repo location"
gmarkall Sep 3, 2025
1e507b5
Another attempt to fix artifact locations / paths
gmarkall Sep 3, 2025
4265442
Remove Python 3.9 from matrix
gmarkall Sep 3, 2025
112f3c9
Fix up pre-commit violations
gmarkall Sep 3, 2025
0cf1ca8
Fix up pre-commit violations
gmarkall Sep 3, 2025
e7c5c91
Attempt to fix docs build repo
gmarkall Sep 3, 2025
f3948a0
Fix matrix for coverage report
gmarkall Sep 3, 2025
1994397
Build wheel on Windows
gmarkall Sep 3, 2025
faed178
Use correct script for wheel Windows build
gmarkall Sep 3, 2025
9d0ca3a
Add MSVC to Windows build
gmarkall Sep 3, 2025
d9cbd9e
Use a different runner for Windows build
gmarkall Sep 3, 2025
770813c
Try using env var for GITHUB_ENV in Windows wheel build
gmarkall Sep 3, 2025
180c9a4
Attempt to have Python matrix for Windows build
gmarkall Sep 3, 2025
31399f1
Add missing output in compute-matrix
gmarkall Sep 3, 2025
bef9816
Another attempt to fix things
gmarkall Sep 3, 2025
145767c
Another attempt at matrix fix
gmarkall Sep 3, 2025
3ecc2ac
Fix potential issue in yaml files
gmarkall Sep 4, 2025
b7eac0c
Experiment if issue is with matrix
gmarkall Sep 4, 2025
af75294
Does this fix it?
gmarkall Sep 4, 2025
9157012
Attempt to simplify Windows matrix setup
gmarkall Sep 4, 2025
bab4281
Merge remote-tracking branch 'NVIDIA/main' into vk/dispatcher-ext
gmarkall Sep 4, 2025
d1cf984
Remove accidental duplicate install of numba-cuda in docs build
gmarkall Sep 4, 2025
300d90c
Remove some duplicate installation steps
gmarkall Sep 4, 2025
d27dd77
Remove unnecessary NumPy version pins
gmarkall Sep 4, 2025
aa4ecc3
Remove debugging code
gmarkall Sep 4, 2025
13eb53f
Merge branch 'main' into vk/dispatcher-ext
gmarkall Sep 4, 2025
bbe7b3c
Minor changes to address review feedback
VijayKandiah Sep 5, 2025
0313df6
Remove all cext import hacks
gmarkall Sep 5, 2025
3ec1352
Correct `NUMBA_CUDA_DEVICEARRAY_IMPORT_NAME`
gmarkall Sep 5, 2025
0aea2a0
Add debug prints to the initialization of `_devicearray`
gmarkall Sep 5, 2025
1f027f4
Add debugging prints to `import_devicearray()`
gmarkall Sep 5, 2025
91a1043
Use module dict to get device array capsule pointer
gmarkall Sep 5, 2025
cbe0975
Remove debug prints
gmarkall Sep 5, 2025
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
2 changes: 1 addition & 1 deletion .github/workflows/conda-python-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ jobs:
if: "!cancelled()"
uses: actions/upload-artifact@v4
with:
name: conda-repo
name: conda-repo-py${{ matrix.PY_VER }}-${{ matrix.ARCH }}
path: "/tmp/conda-bld-output"
- name: Publish conda package
if: inputs.upload_to_anaconda
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/conda-python-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,9 @@ jobs:
ref: ${{ inputs.sha }}
fetch-depth: 0
- uses: actions/download-artifact@v4
name: conda-repo
with:
name: conda-repo-py${{ matrix.PY_VER }}-${{ matrix.ARCH }}
path: conda-repo
- name: Display structure of downloaded files
run: ls -R
- name: Standardize repository information
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/docs-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
env:
RAPIDS_ARTIFACTS_DIR: ${{ github.workspace }}/artifacts
container:
image: rapidsai/ci-conda:latest
image: rapidsai/ci-conda:cuda13.0.0-ubuntu24.04-py3.13
env:
RAPIDS_BUILD_TYPE: ${{ inputs.build_type }}
steps:
Expand All @@ -59,7 +59,9 @@ jobs:
ref: ${{ inputs.sha }}
fetch-depth: 0
- uses: actions/download-artifact@v4
name: conda-repo
with:
name: conda-repo-py3.13-amd64
path: conda-repo
- name: Display structure of downloaded files
run: ls -R
- name: Standardize repository information
Expand Down
8 changes: 5 additions & 3 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
- test-conda-ctypes-binding
- test-simulator
- build-wheels
- build-wheels-windows
- test-wheels-windows
- test-wheels
- test-wheels-ctypes-binding
Expand Down Expand Up @@ -108,10 +109,11 @@ jobs:
build_type: pull-request
script: "ci/build_wheel.sh"
matrix: ${{ needs.compute-matrix.outputs.BUILD_MATRIX }}
build-wheels-windows:
uses: ./.github/workflows/wheel-windows-build.yaml
test-wheels-windows:
needs:
- build-wheels
- compute-matrix
- build-wheels-windows
uses: ./.github/workflows/wheel-windows-tests.yaml
test-wheels:
needs:
Expand Down Expand Up @@ -169,4 +171,4 @@ jobs:
build_type: pull-request
script: "ci/coverage_report.sh"
matrix: ${{ needs.compute-matrix.outputs.TEST_MATRIX }}
matrix_filter: 'map(select(.ARCH == "amd64" and .CUDA_VER == "12.9.1" and .PY_VER == "3.11")) | .[0:1]'
matrix_filter: 'map(select(.ARCH == "amd64" and .CUDA_VER == "12.9.1" and .PY_VER == "3.12")) | .[0:1]'
4 changes: 3 additions & 1 deletion .github/workflows/simulator-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,9 @@ jobs:
ref: ${{ inputs.sha }}
fetch-depth: 0
- uses: actions/download-artifact@v4
name: conda-repo
with:
name: conda-repo-py${{ matrix.PY_VER }}-${{ matrix.ARCH }}
path: conda-repo
- name: Display structure of downloaded files
run: ls -R
- name: Standardize repository information
Expand Down
55 changes: 55 additions & 0 deletions .github/workflows/wheel-windows-build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: BSD-2-Clause

name: "CI: Build wheel on Windows"

on:
workflow_call:
inputs:
sha:
type: string
repo:
type: string
script:
type: string
default: "./ci/build_wheel.ps1"

jobs:
build:
name: ${{ matrix.PY_VER }}, windows
strategy:
fail-fast: false
matrix:
PY_VER:
- "3.10"
- "3.11"
- "3.12"
- "3.13"
runs-on: windows-2022
steps:
- uses: actions/checkout@v4
with:
repository: ${{ inputs.repo }}
ref: ${{ inputs.sha }}
fetch-depth: 0

- name: Set up Python ${{ matrix.PY_VER }}
uses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
with:
python-version: ${{ matrix.PY_VER }}

- name: Set up MSVC
uses: ilammy/msvc-dev-cmd@v1 # TODO: ask admin to allow pinning commits

- name: Python build
run: |
${{ inputs.script }}
env:
CUDA_VER: "12.8.0"

- name: Upload wheel
if: "!cancelled()"
uses: actions/upload-artifact@v4
with:
name: wheel-py${{ matrix.PY_VER }}-windows
path: ${{ env.wheel_path }}
28 changes: 11 additions & 17 deletions .github/workflows/wheel-windows-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,24 +15,16 @@ on:
default: "./ci/test_wheel.ps1"

jobs:
compute-matrix:
runs-on: ubuntu-latest
outputs:
MATRIX: ${{ steps.compute-matrix.outputs.MATRIX }}
steps:
- name: Compute Python Test Matrix
id: compute-matrix
run: |
set -eo pipefail
export TEST_MATRIX="{ ARCH: 'amd64', PY_VER: '3.12', CUDA_VER: '12.8.0' }"
MATRIX=$(yq -n -o json 'env(TEST_MATRIX)' | jq -c)
echo "MATRIX=${MATRIX}" | tee --append "${GITHUB_OUTPUT}"
tests:
name: ${{ matrix.CUDA_VER }}, ${{ matrix.PY_VER }}, ${{ matrix.ARCH }}, windows
needs: compute-matrix
name: ${{ matrix.PY_VER }}, windows
strategy:
fail-fast: false
matrix: ${{ fromJSON('{"ARCH":["amd64"],"PY_VER":["3.12"],"CUDA_VER":["12.8.0"]}') }}
matrix:
PY_VER:
- "3.10"
- "3.11"
- "3.12"
- "3.13"
runs-on: "cuda-python-windows-gpu-github"
steps:
- uses: actions/checkout@v4
Expand All @@ -49,7 +41,9 @@ jobs:
run: nvidia-smi

- uses: actions/download-artifact@v4
name: wheel
with:
name: wheel-py${{ matrix.PY_VER }}-windows
path: wheel

- name: Display structure of downloaded files
run: Get-ChildItem -Recurse
Expand All @@ -63,4 +57,4 @@ jobs:
run: |
${{ inputs.script }}
env:
CUDA_VER: ${{ matrix.CUDA_VER }}
CUDA_VER: "12.8.0"
4 changes: 2 additions & 2 deletions .github/workflows/wheels-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -152,11 +152,11 @@ jobs:
if: "!cancelled()"
uses: actions/upload-artifact@v4
with:
name: sdist
name: sdist-py${{ matrix.PY_VER }}-${{ matrix.ARCH }}
path: ${{ env.sdist_path }}
- name: Upload wheel
if: "!cancelled()"
uses: actions/upload-artifact@v4
with:
name: wheel
name: wheel-py${{ matrix.PY_VER }}-${{ matrix.ARCH }}
path: ${{ env.wheel_path }}
4 changes: 3 additions & 1 deletion .github/workflows/wheels-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,9 @@ jobs:
fetch-depth: 0 # unshallow fetch for setuptools-scm
persist-credentials: false
- uses: actions/download-artifact@v4
name: wheel
with:
name: wheel-py${{ matrix.PY_VER }}-${{ matrix.ARCH }}
path: wheel
- name: Display structure of downloaded files
run: ls -R
- name: Standardize repository information
Expand Down
33 changes: 33 additions & 0 deletions ci/build_wheel.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# SPDX-FileCopyrightText: Copyright (c) 2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: BSD-2-Clause

$ErrorActionPreference = 'Stop'
Set-StrictMode -Version Latest

function rapids-logger {
param (
[Parameter(Mandatory=$true)]
[string]$Text
)

# Determine padding and box width
$padding = 2
$boxWidth = $Text.Length + ($padding * 2)
$topBottom = '+' + ('-' * $boxWidth) + '+'
$middle = '|' + (' ' * $padding) + $Text + (' ' * $padding) + '|'

# Print the box in green
Write-Host $topBottom -ForegroundColor Green
Write-Host $middle -ForegroundColor Green
Write-Host $topBottom -ForegroundColor Green
}

rapids-logger "Install build package"
python -m pip install build

rapids-logger "Build sdist and wheel"
python -m build .

$wheel_path = Resolve-Path dist\numba_cuda*.whl | Select-Object -ExpandProperty Path
echo "Wheel path: $wheel_path"
echo "wheel_path=$wheel_path" >> $env:GITHUB_ENV
27 changes: 17 additions & 10 deletions ci/matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,30 @@
# [ARCH, PY_VER, CUDA_VER, LINUX_VER, GPU, DRIVER, DEPENDENCIES]
#
build-matrix:
- { ARCH: 'amd64', PY_VER: '3.10', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
- { ARCH: 'amd64', PY_VER: '3.11', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
- { ARCH: 'amd64', PY_VER: '3.12', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
- { ARCH: 'amd64', PY_VER: '3.13', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
- { ARCH: 'arm64', PY_VER: '3.10', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
- { ARCH: 'arm64', PY_VER: '3.11', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
- { ARCH: 'arm64', PY_VER: '3.12', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
- { ARCH: 'arm64', PY_VER: '3.13', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
simulator-matrix:
- { ARCH: 'amd64', PY_VER: '3.12', CUDA_VER: '12.8.0', LINUX_VER: 'rockylinux8' }
# We test "oldest" dependencies with the oldest supported Python version and
# the second-newest Python version.
test-matrix:
- { CUDA_VER: '12.0.1', ARCH: 'amd64', PY_VER: '3.9', LINUX_VER: 'rockylinux8', GPU: 'l4', DRIVER: 'earliest', DEPENDENCIES: 'oldest' }
- { CUDA_VER: '12.0.1', ARCH: 'amd64', PY_VER: '3.9', LINUX_VER: 'rockylinux8', GPU: 'l4', DRIVER: 'earliest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.2.2', ARCH: 'amd64', PY_VER: '3.10', LINUX_VER: 'ubuntu22.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.9.1', ARCH: 'amd64', PY_VER: '3.11', LINUX_VER: 'ubuntu24.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.0.1', ARCH: 'amd64', PY_VER: '3.10', LINUX_VER: 'rockylinux8', GPU: 'l4', DRIVER: 'earliest', DEPENDENCIES: 'oldest' }
- { CUDA_VER: '12.0.1', ARCH: 'amd64', PY_VER: '3.11', LINUX_VER: 'rockylinux8', GPU: 'l4', DRIVER: 'earliest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.2.2', ARCH: 'amd64', PY_VER: '3.11', LINUX_VER: 'ubuntu22.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.9.1', ARCH: 'amd64', PY_VER: '3.12', LINUX_VER: 'ubuntu24.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '13.0.0', ARCH: 'amd64', PY_VER: '3.12', LINUX_VER: 'ubuntu22.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'oldest' }
- { CUDA_VER: '13.0.0', ARCH: 'amd64', PY_VER: '3.12', LINUX_VER: 'ubuntu22.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '13.0.0', ARCH: 'amd64', PY_VER: '3.13', LINUX_VER: 'ubuntu22.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '13.0.0', ARCH: 'amd64', PY_VER: '3.13', LINUX_VER: 'ubuntu24.04', GPU: 'l4', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.0.1', ARCH: 'arm64', PY_VER: '3.9', LINUX_VER: 'rockylinux8', GPU: 'a100', DRIVER: 'earliest', DEPENDENCIES: 'oldest' }
- { CUDA_VER: '12.0.1', ARCH: 'arm64', PY_VER: '3.9', LINUX_VER: 'rockylinux8', GPU: 'a100', DRIVER: 'earliest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.2.2', ARCH: 'arm64', PY_VER: '3.10', LINUX_VER: 'ubuntu22.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.9.1', ARCH: 'arm64', PY_VER: '3.11', LINUX_VER: 'ubuntu24.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.0.1', ARCH: 'arm64', PY_VER: '3.10', LINUX_VER: 'rockylinux8', GPU: 'a100', DRIVER: 'earliest', DEPENDENCIES: 'oldest' }
- { CUDA_VER: '12.0.1', ARCH: 'arm64', PY_VER: '3.11', LINUX_VER: 'rockylinux8', GPU: 'a100', DRIVER: 'earliest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.2.2', ARCH: 'arm64', PY_VER: '3.11', LINUX_VER: 'ubuntu22.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '12.9.1', ARCH: 'arm64', PY_VER: '3.12', LINUX_VER: 'ubuntu24.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '13.0.0', ARCH: 'arm64', PY_VER: '3.12', LINUX_VER: 'ubuntu22.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'oldest' }
- { CUDA_VER: '13.0.0', ARCH: 'arm64', PY_VER: '3.12', LINUX_VER: 'ubuntu22.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '13.0.0', ARCH: 'arm64', PY_VER: '3.13', LINUX_VER: 'ubuntu22.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'latest' }
- { CUDA_VER: '13.0.0', ARCH: 'arm64', PY_VER: '3.13', LINUX_VER: 'ubuntu24.04', GPU: 'a100', DRIVER: 'latest', DEPENDENCIES: 'latest' }
2 changes: 1 addition & 1 deletion conda/recipes/numba-cuda/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ source:
path: ../../..

build:
noarch: python
script:
- {{ PYTHON }} -m pip install . -vv

Expand All @@ -26,6 +25,7 @@ requirements:
- python
- pip
- setuptools
- numpy >=2.1.0
run:
- python
- numba >=0.59.1
Expand Down
2 changes: 2 additions & 0 deletions numba_cuda/numba/cuda/cext/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# SPDX-FileCopyrightText: Copyright (c) 2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: BSD-2-Clause
Loading
Loading