Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEA]: Implement cccl.c.parallel version of merge sort #2547

Closed
1 task done
gevtushenko opened this issue Oct 10, 2024 · 0 comments · Fixed by #3636
Closed
1 task done

[FEA]: Implement cccl.c.parallel version of merge sort #2547

gevtushenko opened this issue Oct 10, 2024 · 0 comments · Fixed by #3636
Assignees
Labels
2.8.0 target for 2.8.0 release feature request New feature or request.

Comments

@gevtushenko
Copy link
Collaborator

Is this a duplicate?

Area

Not sure

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

To implement cuda.parallel.merge_sort algorithms, we need a C version of cub::DeviceMergeSort first.

Describe the solution you'd like

We need a version of C API for merge sort, similar to what we have for reduction:

struct cccl_device_reduce_build_result_t
{
int cc;
void* cubin;
size_t cubin_size;
CUlibrary library;
CUkernel single_tile_kernel;
CUkernel single_tile_second_kernel;
CUkernel reduction_kernel;
};
// TODO return a union of nvtx/cuda/nvrtc errors or a string?
extern "C" CCCL_C_API CUresult cccl_device_reduce_build(
cccl_device_reduce_build_result_t* build,
cccl_iterator_t d_in,
cccl_iterator_t d_out,
cccl_op_t op,
cccl_value_t init,
int cc_major,
int cc_minor,
const char* cub_path,
const char* thrust_path,
const char* libcudacxx_path,
const char* ctk_path) noexcept;
extern "C" CCCL_C_API CUresult cccl_device_reduce(
cccl_device_reduce_build_result_t build,
void* d_temp_storage,
size_t* temp_storage_bytes,
cccl_iterator_t d_in,
cccl_iterator_t d_out,
unsigned long long num_items,
cccl_op_t op,
cccl_value_t init,
CUstream stream) noexcept;
extern "C" CCCL_C_API CUresult cccl_device_reduce_cleanup(cccl_device_reduce_build_result_t* bld_ptr);

Describe alternatives you've considered

No response

Additional context

No response

@gevtushenko gevtushenko added the feature request New feature or request. label Oct 10, 2024
@github-project-automation github-project-automation bot moved this to Todo in CCCL Oct 10, 2024
@jollylili jollylili added the 2.8.0 target for 2.8.0 release label Nov 15, 2024
@NaderAlAwar NaderAlAwar self-assigned this Jan 15, 2025
@cccl-authenticator-app cccl-authenticator-app bot moved this from Todo to In Review in CCCL Jan 31, 2025
@cccl-authenticator-app cccl-authenticator-app bot moved this from In Review to In Progress in CCCL Jan 31, 2025
@cccl-authenticator-app cccl-authenticator-app bot moved this from In Progress to In Review in CCCL Feb 6, 2025
@github-project-automation github-project-automation bot moved this from In Review to Done in CCCL Feb 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2.8.0 target for 2.8.0 release feature request New feature or request.
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants