cuCollections icon indicating copy to clipboard operation
cuCollections copied to clipboard

[ENHANCEMENT]: Improve `make_window_extent` in the case of linear probing

Open PointKernel opened this issue 6 months ago • 0 comments

Is your feature request related to a problem? Please describe.

The current make_window_extent function always calculates prime capacity, regardless of the probing scheme used. This approach is suboptimal for linear probing, where the capacity does not need to be a prime number.

Describe the solution you'd like

If it's linear probing, return the window extent based on CG size and window size without the prime table lookup.

template <typename T>
struct is_double_hashing : cuda::std::false_type {};

template <int32_t CGSize, typename Hash1, typename Hash2>
struct is_double_hashing<cuco::double_hashing<CGSize, Hash1, Hash2>> : cuda::std::true_type {};

A trait similar to the above idea is needed to dispatch between linear probing and double hashing

Describe alternatives you've considered

No response

Additional context

No response

PointKernel avatar Aug 19 '24 23:08 PointKernel