NVIDIA / numba-cuda

BSD 2-Clause "Simplified" License
24 stars 7 forks source link

Build as a purelib by replacing the `_extras` module with a Python implementation #5

Closed gmarkall closed 2 months ago

gmarkall commented 2 months ago

The _extras module only serves to fix up the ABI for passing an IPC handle to cuIpcOpenMemHandle, which expects a structure passed by value. It seems that this requirement can be accommodated using the ctypes Structure class, so we can replace the functionality of the _extras module with it.

Some changes needed to be made to accommodate the way in which we now represent an IPC handle, in the tests and in how we serialize them.

This change makes numba-cuda a pure Python package, with no C / C++ build / extension modules needed.

The CI and build changes are aimed at building a purelib wheel / noarch Python conda package.

gmarkall commented 2 months ago

I just merged this even though CI is not running because the lack of it is making it hard for people to try out the package by building it locally.