NVIDIA / NVIDIA/cudf

Responsibility for null count updating on in-place operations

Open
#20,956 1 comment 0 reactions 0 assignees View on GitHub
improvement libcudf
Dominant language
C++
Stars
9.8k
Forks
1.1k
Avg merge
3d 6m
Merged PRs (30d)
278

Description

libcudf supports in-place operations in a very limited set of cases. A couple of them such as [`fill_in_place`](https://github.com/rapidsai/cudf/blob/d9b3a14a9d7cfb319ebbc2222c5e6762ee1a8f48/cpp/include/cudf/filling.hpp#L49) and [`copy_range_in_place`](https://github.com/rapidsai/cudf/blob/d9b3a14a9d7cfb319ebbc2222c5e6762ee1a8f48/cpp/include/cudf/copying.hpp#L327) can modify the number of nulls in the target column. However, because `(mutable_)column_view` can be constructed from any object by providing pointers to data and is not tied to libcudf columns, and due to the standard mode of operation with views being that they are constructed at the call site to libcudf calls (often as arguments via e.g. `col->view()` or similar), these in-place operations set null counts on views that users can easily forget to propagate to the their proper permanent storage locations. One possible solution for this is to change mutable_column_view's null_count to be a pointer instead of a value. I am open to other solutions as well. The current behavior violates the principle of least surprise for users, so it would be nice to come up with an alternative to the status quo, which is not really buggy per se but is definitely an unexpectedly sharp edge.

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.