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

add REDSET_ENCODE to select encoding method at runtime #54

Merged
merged 1 commit into from
Dec 16, 2023

Conversation

adammoody
Copy link
Contributor

@adammoody adammoody commented Dec 16, 2023

This modifies redset_init() to read a REDSET_ENCODE environment variable, whose value is used during encode/decode operations to select the acceleration method. This allows one to compile multiple methods and select one at runtime.

Valid options are:

  • CPU - main process executes encoding
  • OPENMP - main process with OpenMP parallelized for loops
  • PTHREADS - use pthreads, where an implementation is available, otherwise fallback to use CPU/OPENMP
  • CUDA - use CUDA kernels, requires MPI with GPUDirect RDMA support

The CPU and OPENMP options call the same function. To disable OpenMP threads, one must either build with -DENABLE_OPENMP=OFF or set an OpenMP variable like OMP_NUM_THREADS=1.

@adammoody adammoody merged commit dec4668 into main Dec 16, 2023
8 checks passed
@adammoody adammoody deleted the encode_select branch December 16, 2023 20:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant