This source file includes following definitions.
- shmem_addr_accessible
   1 
   2 
   3 
   4 
   5 
   6 
   7 
   8 
   9 
  10 #include "oshmem_config.h"
  11 
  12 #include "oshmem/constants.h"
  13 #include "oshmem/include/shmem.h"
  14 
  15 #include "oshmem/runtime/runtime.h"
  16 #include "oshmem/mca/memheap/memheap.h"
  17 #include "oshmem/mca/memheap/base/base.h"
  18 
  19 #if OSHMEM_PROFILING
  20 #include "oshmem/include/pshmem.h"
  21 #pragma weak shmem_addr_accessible = pshmem_addr_accessible
  22 #include "oshmem/shmem/c/profile/defines.h"
  23 #endif
  24 
  25 int shmem_addr_accessible(const void *addr, int pe)
  26 {
  27     void* rva;
  28     sshmem_mkey_t *mkey;
  29     int i;
  30 
  31     RUNTIME_CHECK_INIT();
  32 
  33     for (i = 0; i < mca_memheap_base_num_transports(); i++) {
  34         
  35         mkey = mca_memheap_base_get_cached_mkey(oshmem_ctx_default, pe, (void *)addr, i, &rva);
  36         if (mkey) {
  37             return 1;
  38         }
  39     }
  40 
  41     return 0;
  42 }