Skip to content

Conversation

@jhchouuu
Copy link
Collaborator

Motivation

support symmetric heap and unified memory space

Technical Details

  1. support static symmetric heap and unified memory space

    shmem support two style api:
    SymmMemObjPtr + offset:

    ShmemPutMemNbiThread(
        const application::SymmMemObjPtr dest, size_t destOffset,
        const application::RdmaMemoryRegion& source, size_t sourceOffset, size_t bytes, int pe,
        int qpId = 0) 
    

    unified memory :

    ShmemPutMemNbiThread(void* dest, const void* source, size_t bytes,
                                                int pe, int qpId = 0)
    
  2. The symmetric heap currently only supports static heaps.
    use env variable MORI_SHMEM_HEAP_SIZE to set default heap memory size

Test Result

test pass:

  • mpirun --allow-run-as-root -np 2 ./examples/concurrent_put_thread
  • mpirun --allow-run-as-root -np 2 ./examples/concurrent_put_imm_thread
  • mpirun --allow-run-as-root -np 2 ./examples/atomic_fetch_thread
  • mpirun --allow-run-as-root -np 2 ./examples/atomic_nonfetch_thread
  • mpirun --allow-run-as-root -np 2 ./examples/concurrent_put_signal_thread
  • torchrun --nnodes=2 --node_rank=0 --nproc_per_node=1 --master_addr=xxx --master_port=1236 examples/ops/dispatch_combine/test_dispatch_combine_internode.py

@jhchouuu jhchouuu force-pushed the jiahzhou/shmem_unified_mem branch from e47a2dc to 5f3d7cf Compare October 28, 2025 05:44
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.

2 participants