12 #include <ucp/api/ucp.h>
14 #include <ucxx/component.h>
15 #include <ucxx/config.h>
16 #include <ucxx/constructors.h>
20 namespace experimental {
37 ucp_context_h _handle{
nullptr};
39 uint64_t _featureFlags{0};
40 bool _cudaSupport{
false};
56 UCP_FEATURE_TAG | UCP_FEATURE_WAKEUP | UCP_FEATURE_STREAM | UCP_FEATURE_AM |
181 [[nodiscard]] std::shared_ptr<Worker>
createWorker(
const bool enableDelayedSubmission =
false,
182 const bool enableFuture =
false);
222 const size_t size,
void* buffer,
const ucs_memory_type_t memoryType = UCS_MEMORY_TYPE_HOST);
245 #include <ucxx/experimental/context_builder.h>
A UCXX component class to prevent early destruction of parent object.
Definition: component.h:17
Component encapsulating the UCP configuration.
Definition: config.h:19
Component encapsulating the UCP context.
Definition: context.h:35
std::string getInfo()
Get information from UCP context.
friend std::shared_ptr< Context > createContext(ConfigMap ucxConfig, const uint64_t featureFlags)
Friend declaration for ucxx::createContext with parameters.
std::shared_ptr< MemoryHandle > createMemoryHandle(const size_t size, void *buffer, const ucs_memory_type_t memoryType=UCS_MEMORY_TYPE_HOST)
Create a new std::shared_ptr<ucxx::memoryHandle>.
ConfigMap getConfig()
Get the context configuration.
bool hasCudaSupport() const
Query whether CUDA support is available.
~Context()
ucxx::Context destructor
ucp_context_h getHandle()
Get the underlying ucp_context_h handle.
uint64_t getFeatureFlags() const
Get feature flags that were used to construct the UCP context.
static constexpr uint64_t defaultFeatureFlags
Suggested default context feature flags to use.
Definition: context.h:55
std::shared_ptr< Worker > createWorker(const bool enableDelayedSubmission=false, const bool enableFuture=false)
Create a new ucxx::Worker.
Builder class for constructing std::shared_ptr<ucxx::Context> objects.
Definition: context_builder.h:42
std::unordered_map< std::string, std::string > ConfigMap
A UCP configuration map.
Definition: typedefs.h:83
std::shared_ptr< Context > createContext(const ConfigMap ucxConfig, const uint64_t featureFlags)
Constructor of shared_ptr<ucxx::Context> with parameters.