Add host APIs for querying device ctx and remote heap pointer (#200)
* Add host APIs for querying device ctx and remote heap pointer * Host API to query device pointer for ROCSHMEM_DEFAULT_CONTEXT, this is needed to support dynamic module initialization via device kernel library bitcode. * Host API to query remote symmetric heap pointer that can be used in custom device kernel for RMA operations. * Added rocshmem_ptr implementation within the Host Context class * Enables pointer retrieval functionality for symmetric data objects * Copy IPC pointers to host memory in RO host context --------- Co-authored-by: avinashkethineedi <avinash.kethineedi@amd.com>
This commit is contained in:
zatwierdzone przez
GitHub
rodzic
42e28835ad
commit
87f99e7ec6
@@ -31,7 +31,11 @@ namespace rocshmem {
|
||||
__host__ Context::Context(Backend* handle, bool shareable)
|
||||
: num_pes(handle->getNumPEs()),
|
||||
my_pe(handle->getMyPE()),
|
||||
fence_(shareable) {}
|
||||
fence_(shareable) {
|
||||
}
|
||||
|
||||
__host__ Context::~Context() {
|
||||
}
|
||||
|
||||
/******************************************************************************
|
||||
********************** CONTEXT DISPATCH IMPLEMENTATIONS **********************
|
||||
@@ -93,6 +97,12 @@ __host__ void Context::quiet() {
|
||||
HOST_DISPATCH(quiet());
|
||||
}
|
||||
|
||||
__host__ void* Context::shmem_ptr(const void* dest, int pe) {
|
||||
ctxHostStats.incStat(NUM_HOST_SHMEM_PTR);
|
||||
|
||||
HOST_DISPATCH_RET_PTR(shmem_ptr(dest, pe));
|
||||
}
|
||||
|
||||
__host__ void Context::sync_all() {
|
||||
ctxHostStats.incStat(NUM_HOST_SYNC_ALL);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user