new(lct): Lightweight Communication Tools #52
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR splits the original LCI library into two libraries: LCI and LCT (Lightweight Communication Tools).
I moved part of the non-communication-related functionality into the LCT library, with the hope that we can reuse the code in other libraries/benchmarks without rewriting them (just including
lct.h
). In addition, this makes it possible to benchmark individual parts of the LCI library (such as the completion queue).Currently, the functionalities in the LCT library include:
I choose to implement LCT in C++ since it is more convenient. LCT still has a C API.
Regarding performance overheads: we lost some opportunities for compiler optimizations across function calls (unless we do link-time optimizations), but since most of the functionalities here are not on the critical path (except thread id and queues), I think it should be fine. I did not notice any visible performance loss with HPX microbenchmarks and Octo-Tiger.
Eventually, we can gradually move all the code from LCI to LCT and make LCI a C++ library (with a C API).
Other changes:
LCM_LOG_LEVEL
toLCI_LOG_LEVEL
.LCI_CQ_TYPE
to switch to another implementation or the cmake optionLCI_USE_INLINE_CQ
to switch back to the C implementation.