cuquantum.custatevec.sv_swap_worker_set_sub_svs_p2p

cuquantum.custatevec.sv_swap_worker_set_sub_svs_p2p(intptr_t handle, intptr_t worker, dst_sub_svs, dst_sub_sv_indices, dst_events, uint32_t n_dst_sub_svs)[source]

Set P2P access for the distributed sub statevectors.

Parameters
  • handle (intptr_t) – The library handle.

  • worker (intptr_t) – The worker descriptor.

  • dst_sub_svs

    A host array of pointer addresses to sub statevectors to be accessed via GPUDirect P2P. It can be:

    • an int as the pointer address to the array

    • a Python sequence of pointer addresses

  • dst_sub_sv_indices

    A host array of sub statevector indices as specified by dst_sub_svs. It can be:

    • an int as the pointer address to the array

    • a Python sequence of indices.

  • dst_events

    A host array of CUDA events used to create peer workers. It can be:

    • an int as the pointer address to the array

    • a Python sequence of events.

  • n_dst_sub_svs (uint32_t) – The number of sub statevectors as specified by dst_sub_svs.