NVIDIA / NVIDIA/cudf

[FEA] Enable on-disk caching for UDF Kernels

Open
#19,094 0 comments 0 reactions 0 assignees View on GitHub
feature request numba Python
Dominant language
C++
Stars
9.8k
Forks
1.1k
Avg merge
3d 6m
Merged PRs (30d)
278

Description

`numba-cuda` supports caching to disk through [cuda.jit](https://nvidia.github.io/numba-cuda/reference/kernel.html#numba.cuda.jit). Enabling this would make it so that we only have JIT overhead for the first run of the workflow in question instead of once per individual python session. Similar support is provided through jitify.

However naively flipping it on for our UDFs runs us into a wall because of the way we string exec UDF kernels to get around numba's `*args` limitations:

```
RuntimeError: cannot cache function '_kernel': no locator available for file ''
```

We should figure out a way around this problem as it would open up the possibility of providing some warmup mechanism, something like this in a dockerfile for instance

```
RUN python "import custom_cudf_warm_up; custom_cudf_warm_up.warm_up_kernels()"
```

This type of capability might allow advanced users to totally move all JIT overhead to container build time.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.