Semi-Lagrangian Library
Modular library for kinetic and gyrokinetic simulations of plasmas in fusion energy devices.
|
Parallelizing facility.
Selalib applies the principle of modularization throughout all levels of abstraction of the library and aims at keeping third-party library modules as what they are: separate library modules. Therefore, in its current design, even a library like MPI has a single point of entry to Selalib. The collective communications module is such point of entry. We focus thus on the functionality offered by MPI, assign wrappers to its most desirable functionalities and write wrappers around them. These are the functions that are actually used throughout the program. This allows to adjust the exposed interfaces, do additional error-checking and would even permit to completely change the means to parallelize a code, by being able to replace MPI in a single file if this were ever needed.
How to use the sll_m_collective module :
Include the line
Any use of the module's functionalities must be preceeded by calling
and to "turn off" the parallel capabilities, one should finish by a call to:
Comparaison with MPI module :
sll_m_collective | MPI |
---|---|
sll_v_world_collective | MPI_COMM_WORLD |
sll_s_boot_collective() | MPI_INIT(integer :: code) |
sll_s_halt_collective() | MPI_FINALIZE(integer :: code) |
sll_f_get_collective_rank(type(sll_t_collective_t), pointer :: col ) | MPI_COMM_RANK(integer :: comm , integer :: rank , integer :: code) |
sll_f_get_collective_size(type(sll_t_collective_t), pointer :: col ) | MPI_COMM_SIZE(integer :: comm , integer :: size , integer :: code) |
sll_get_collective_color(type(sll_t_collective_t), pointer :: col ) | |
sll_get_collective_comm(type(sll_t_collective_t), pointer :: col ) | |
sll_s_collective_barrier(type(sll_t_collective_t), pointer :: col ) | MPI_BARRIER(integer :: comm ,integer :: code) |
Derived types and interfaces | |
type | sll_t_collective_t |
Wrapper around the communicator. More... | |
interface | sll_o_collective_bcast |
Broadcasts a message from the process with rank "root" to all other processes of the communicator. More... | |
interface | sll_o_collective_gather |
Gathers together values from a group of processes. More... | |
interface | sll_o_collective_allgather |
Gathers data from all tasks and distribute the combined data to all tasks. More... | |
interface | sll_o_collective_allgatherv |
Gathers data from all tasks and deliver the combined data to all tasks. More... | |
interface | sll_collective_gatherv |
Gathers into specified locations from all processes in a group. More... | |
interface | sll_o_collective_scatter |
Sends data from one process to all other processes in a communicator. More... | |
interface | sll_collective_scatterv |
Scatters a buffer in parts to all processes in a communicator. More... | |
interface | sll_o_collective_allreduce |
Combines values from all processes and distributes the result back to all processes. More... | |
interface | sll_o_collective_reduce |
Reduces values on all processes to a single value. More... | |
interface | sll_o_collective_alltoall |
Sends data from all to all processes. More... | |
interface | sll_o_collective_alltoallv |
Sends data from all to all processes; each process may send a different amount of data and provide displacements for the input and output data. More... | |
interface | sll_o_collective_globalsum |
Performs a global sum and writes the result in the optional given node. More... | |
Functions/Subroutines | |
subroutine | sll_check_collective_ptr (ptr) |
Checks if the pointer ptr is associated to an object. More... | |
subroutine, public | sll_s_test_mpi_error (ierr, descriptor) |
Checks the good execution of collective instruction. More... | |
logical function, public | sll_f_collectives_are_same (col1, col2) |
subroutine, public | sll_s_boot_collective (required) |
Starts the paralell environment. More... | |
subroutine, public | sll_s_allocate_collective () |
subroutine, public | sll_s_set_communicator_collective (communicator_in) |
subroutine, public | sll_s_halt_collective () |
Ends the paralell environment. More... | |
type(sll_t_collective_t) function, pointer, public | sll_f_new_collective (parent, color, key) |
Creates new (wrapper around) communicators based on colors and keys. More... | |
subroutine | sll_delete_collective (col) |
Marks the communicator object for deallocation. More... | |
integer(kind=i32) function | sll_get_collective_comm (col) |
Gets the id (integer) of the communicator. More... | |
integer(kind=i32) function, public | sll_f_get_collective_rank (col) |
Determines the rank of the calling process in the communicator. More... | |
integer(kind=i32) function | sll_get_collective_color (col) |
Determines the color of the calling process in the communicator. More... | |
integer(kind=i32) function, public | sll_f_get_collective_size (col) |
Determines the size of the group associated with a communicator. More... | |
type(sll_t_collective_t) function, pointer | sll_get_collective_parent (col) |
Gets collective parent. More... | |
subroutine, public | sll_s_collective_barrier (col) |
Blocks until all processes in the communicator have reached this routine. More... | |
subroutine | sll_collective_bcast_logical (col, buffer, root) |
Broadcasts an array of type 'logical' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine | sll_collective_bcast_int32 (col, buffer, root) |
Broadcasts an array of type 'sll_int32' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine | sll_collective_bcast_int64 (col, buffer, root) |
Broadcasts an array of type 'sll_int64' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine | sll_collective_bcast_real64 (col, buffer, root) |
Broadcasts an array of type 'sll_real64' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine | sll_collective_bcast_real32 (col, buffer, size, root) |
Broadcasts an array of type 'sll_real32' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine, public | sll_s_collective_bcast_real64 (col, buffer, size, root) |
Broadcasts an array of type 'sll_real64' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine | sll_collective_bcast_comp64 (col, buffer, size, root) |
Broadcasts an array of type 'sll_comp64' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine | sll_collective_bcast_comp32 (col, buffer, size, root) |
Broadcasts an array of type 'sll_comp32' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine, public | sll_s_collective_bcast_3d_real64 (col, buffer, root) |
Broadcasts a 3d array of type 'sll_real64' from the process with rank "root" to all other processes of the communicator. More... | |
subroutine | sll_collective_gather_real32 (col, send_buf, send_sz, root, rec_buf) |
Gathers together real values from a group of processes. More... | |
subroutine | sll_collective_gather_real64 (col, send_buf, send_sz, root, rec_buf) |
subroutine | sll_collective_gather_logical (col, send_buf, root, rec_buf) |
subroutine, public | sll_s_collective_gatherv_real (col, send_buf, send_count, recvcnts, displs, root, rec_buf) |
Gathers real values into specified locations from all processes in a group. More... | |
subroutine, public | sll_s_collective_gatherv_real64 (col, send_buf, send_count, recvcnts, displs, root, rec_buf) |
Gathers real64 values into specified locations from all processes in a group. More... | |
subroutine | sll_collective_allgather_int (col, send_buf, send_sz, recv_buf, recv_sz) |
Gathers integer data from all tasks and distribute the combined data to all tasks. More... | |
subroutine | sll_collective_allgather_real64 (col, send_buf, send_sz, recv_buf, recv_sz) |
subroutine | sll_collective_allgatherv_real32 (col, send_buf, send_cnt, rec_cnt, displs, rec_buf) |
Gathers real data from all tasks and deliver the combined data to all tasks. More... | |
subroutine, public | sll_s_collective_allgatherv_real64 (col, send_buf, send_cnt, rec_cnt, displs, rec_buf) |
subroutine | sll_collective_scatter_real (col, send_buf, send_count, root, rec_buf) |
Sends data from one process to all other processes in a communicator. More... | |
subroutine | sll_collective_scatter_real64 (col, send_buf, send_count, root, rec_buf) |
Sends data from one process to all other processes in a communicator. More... | |
subroutine | sll_collective_scatter_int32 (col, send_buf, send_count, root, rec_buf) |
Sends data from one process to all other processes in a communicator. More... | |
subroutine, public | sll_s_collective_scatterv_real (col, send_buf, send_count, displs, recv_count, root, rec_buf) |
Scatters a buffer in parts to all processes in a communicator. More... | |
subroutine, public | sll_s_collective_allreduce_real32 (col, send_buf, count, op, rec_buf) |
Combines real values from all processes and distributes the result back to all processes. More... | |
subroutine | sll_collective_allreduce_real64 (col, send_buf, count, op, rec_buf) |
Combines real values from all processes and distributes the result back to all processes. More... | |
subroutine | sll_collective_allreduce_real64_2darray (col, send_buf, count, op, rec_buf) |
Combines real values from all processes and distributes the result back to all processes. More... | |
subroutine | sll_collective_allreduce_comp64 (col, send_buf, count, op, rec_buf) |
Combines complex values from all processes and distributes the result back to all processes. More... | |
subroutine | sll_collective_allreduce_comp32 (col, send_buf, count, op, rec_buf) |
subroutine | sll_collective_allreduce_int32 (col, send_buf, count, op, rec_buf) |
Combines complex values from all processes and distributes the result back to all processes. More... | |
subroutine, public | sll_s_collective_allreduce_logical (col, send_buf, count, op, rec_buf) |
Combines logical values from all processes and distributes the result back to all processes. More... | |
subroutine, public | sll_s_collective_allreduce_sum_3d_real64 (col, buffer) |
Sums real values from all processes and distributes the result back to all processes. More... | |
subroutine, public | sll_s_collective_reduce_int (col, send_buf, size, op, root_rank, rec_buf) |
Reduces integer values on all processes to a single value. More... | |
subroutine, public | sll_s_collective_reduce_real32 (col, send_buf, size, op, root_rank, rec_buf) |
Reduces real values on all processes to a single value. More... | |
subroutine, public | sll_s_collective_reduce_real64 (col, send_buf, size, op, root_rank, rec_buf) |
subroutine | sll_collective_reduce_real64_2d (col, send_buf, size, op, root_rank, rec_buf) |
subroutine | sll_collective_reduce_comp64 (col, send_buf, size, op, root_rank, rec_buf) |
Reduces complex values on all processes to a single value. More... | |
subroutine | sll_collective_reduce_comp32 (col, send_buf, size, op, root_rank, rec_buf) |
subroutine, public | sll_s_collective_reduce_logical (col, send_buf, size, op, root_rank, rec_buf) |
Reduces logical values on all processes to a single value. More... | |
subroutine, public | sll_s_collective_alltoall_int (send_buf, send_count, recv_count, recv_buf, col) |
Sends integer data from all to all processes. More... | |
subroutine | sll_collective_alltoall_double (send_buf, send_count, recv_count, recv_buf, col) |
subroutine | sll_collective_alltoall_complex_double (send_buf, send_count, recv_count, recv_buf, col) |
subroutine, public | sll_s_collective_alltoallv_real (send_buf, send_cnts, send_displs, recv_buf, recv_cnts, recv_displs, col) |
Sends real data from all to all processes; each process may send a different amount of data and provide displacements for the input and output data. More... | |
subroutine, public | sll_s_collective_alltoallv_double (send_buf, send_cnts, send_displs, recv_buf, recv_cnts, recv_displs, col) |
subroutine | sll_collective_alltoallv_complex_double (send_buf, send_cnts, send_displs, recv_buf, recv_cnts, recv_displs, col) |
subroutine, public | sll_s_collective_alltoallv_int (send_buf, send_cnts, send_displs, recv_buf, recv_cnts, recv_displs, col) |
Sends integer data from all to all processes; each process may send a different amount of data and provide displacements for the input and output data. More... | |
subroutine, public | sll_s_collective_alltoallv_int_simple (send_buf, send_cnts, recv_buf, col) |
subroutine, public | sll_s_collective_globalsum_array_real64 (col, summand, root_rank) |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes. More... | |
subroutine, public | sll_s_collective_globalsum_array_comp64 (col, summand, root_rank) |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes. More... | |
subroutine | sll_collective_globalsum_real64 (col, summand, root_rank) |
Performs a global sum and writes the result in the given node. More... | |
subroutine | sll_collective_globalsum_array_real32 (col, summand, root_rank) |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes. More... | |
subroutine | sll_collective_globalsum_array_comp32 (col, summand, root_rank) |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes. More... | |
subroutine | sll_collective_globalsum_array_int32 (col, summand, root_rank) |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes. More... | |
subroutine | sll_collective_globalsum_comp64 (col, summand, root_rank) |
Performs a global sum and writes the result in the given node. More... | |
subroutine | sll_collective_globalsum_int32 (col, summand, root_rank) |
Performs a global sum and writes the result in the given node. More... | |
subroutine | sll_collective_globalsum_comp32 (col, summand, root_rank) |
Performs a global sum and writes the result in the given node. More... | |
subroutine | sll_collective_globalsum_real32 (col, summand, root_rank) |
Performs a global sum and writes the result in the given node. More... | |
type(sll_t_collective_t) function, pointer, public | sll_f_create_collective (comm) |
Function to derive a "collective" from a plain MPI communicator,. More... | |
Variables | |
type(sll_t_collective_t), pointer, public | sll_v_world_collective |
Control of subset assignment. Processes with the same color are in the same new communicator. More... | |
|
private |
Checks if the pointer ptr is associated to an object.
[in] | ptr | pointer to sll_t_collective_t type |
Definition at line 369 of file sll_m_collective.F90.
|
private |
Gathers integer data from all tasks and distribute the combined data to all tasks.
[in] | col | Wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | send_sz | number of elements in send buffer |
[out] | rec_buf | address of receive buffer |
[in] | recv_sz | number of elements received from any process |
Definition at line 891 of file sll_m_collective.F90.
|
private |
Definition at line 908 of file sll_m_collective.F90.
|
private |
Gathers real data from all tasks and deliver the combined data to all tasks.
[in] | col | Wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | send_cnt | number of elements in send buffer |
[in] | displs | integer array. Entry i specifies the displacement |
[in] | rec_cnt | integer array containing the number of elements that are to be received from each process |
[out] | rec_buf | address of receive buffer |
Definition at line 940 of file sll_m_collective.F90.
|
private |
|
private |
Combines complex values from all processes and distributes the result back to all processes.
[in] | col | wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | count | number of elements in send buffer |
[in] | op | operation |
[out] | rec_buf | starting address of receive buffer |
Definition at line 1202 of file sll_m_collective.F90.
|
private |
Combines complex values from all processes and distributes the result back to all processes.
[in] | col | wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | count | number of elements in send buffer |
[in] | op | operation |
[out] | rec_buf | starting address of receive buffer |
Definition at line 1255 of file sll_m_collective.F90.
|
private |
Combines real values from all processes and distributes the result back to all processes.
[in] | col | wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | count | number of elements in send buffer |
[in] | op | operation |
[out] | rec_buf | starting address of receive buffer |
Definition at line 1141 of file sll_m_collective.F90.
|
private |
Combines real values from all processes and distributes the result back to all processes.
[in] | col | wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | count | number of elements in send buffer |
[in] | op | operation |
[out] | rec_buf | starting address of receive buffer |
Definition at line 1171 of file sll_m_collective.F90.
|
private |
Definition at line 1507 of file sll_m_collective.F90.
|
private |
Definition at line 1490 of file sll_m_collective.F90.
|
private |
Definition at line 1592 of file sll_m_collective.F90.
|
private |
Broadcasts an array of type 'sll_comp32' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'sll_comp32' |
[in] | size | Number of entries in buffer |
[in] | root | Rank of broadcast root |
Definition at line 709 of file sll_m_collective.F90.
|
private |
Broadcasts an array of type 'sll_comp64' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'sll_comp64' |
[in] | size | Number of entries in buffer |
[in] | root | Rank of broadcast root |
Definition at line 690 of file sll_m_collective.F90.
|
private |
Broadcasts an array of type 'sll_int32' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'sll_int32' |
[in] | root | Rank of broadcast root |
Definition at line 600 of file sll_m_collective.F90.
|
private |
Broadcasts an array of type 'sll_int64' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'sll_int64' |
[in] | root | Rank of broadcast root |
Definition at line 617 of file sll_m_collective.F90.
|
private |
Broadcasts an array of type 'logical' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'logical' |
[in] | root | Rank of broadcast root |
Definition at line 586 of file sll_m_collective.F90.
|
private |
Broadcasts an array of type 'sll_real32' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'sll_real32' |
[in] | size | Number of entries in buffer |
[in] | root | Rank of broadcast root |
Definition at line 652 of file sll_m_collective.F90.
|
private |
Broadcasts an array of type 'sll_real64' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'sll_real64' |
[in] | root | Rank of broadcast root |
Definition at line 634 of file sll_m_collective.F90.
|
private |
Definition at line 783 of file sll_m_collective.F90.
|
private |
Gathers together real values from a group of processes.
[in] | col | Wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | send_sz | number of elements in send buffer |
[in] | root | rank of broadcast root |
[out] | rec_buf | address of receive buffer |
Definition at line 745 of file sll_m_collective.F90.
|
private |
Definition at line 764 of file sll_m_collective.F90.
|
private |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1842 of file sll_m_collective.F90.
|
private |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1873 of file sll_m_collective.F90.
|
private |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1811 of file sll_m_collective.F90.
|
private |
Performs a global sum and writes the result in the given node.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1946 of file sll_m_collective.F90.
|
private |
Performs a global sum and writes the result in the given node.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1902 of file sll_m_collective.F90.
|
private |
Performs a global sum and writes the result in the given node.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1924 of file sll_m_collective.F90.
|
private |
Performs a global sum and writes the result in the given node.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1968 of file sll_m_collective.F90.
|
private |
Performs a global sum and writes the result in the given node.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1787 of file sll_m_collective.F90.
|
private |
|
private |
Reduces complex values on all processes to a single value.
[in] | col | wrapper around the communicator |
[in] | send_bu | address of send buffer |
[in] | size | number of elements in send buffer |
[in] | op | reduce operation |
[in] | root_rank | rank of root process |
[out] | rec_buf | address of receive buffer |
Definition at line 1409 of file sll_m_collective.F90.
|
private |
Definition at line 1385 of file sll_m_collective.F90.
|
private |
Sends data from one process to all other processes in a communicator.
col | Wrapper around the communicator | |
[in] | send_buf | address of send buffer |
[in] | send_count | number of elements sent to each process |
[in] | root | rank of sending process |
[in] | rec_buf | address of receive buffer |
Definition at line 1053 of file sll_m_collective.F90.
|
private |
Sends data from one process to all other processes in a communicator.
col | Wrapper around the communicator | |
[in] | send_buf | address of send buffer |
[in] | send_count | number of elements sent to each process |
[in] | root | rank of sending process |
[in] | rec_buf | address of receive buffer |
Definition at line 997 of file sll_m_collective.F90.
|
private |
Sends data from one process to all other processes in a communicator.
col | Wrapper around the communicator | |
[in] | send_buf | address of send buffer |
[in] | send_count | number of elements sent to each process |
[in] | root | rank of sending process |
[in] | rec_buf | address of receive buffer |
Definition at line 1025 of file sll_m_collective.F90.
|
private |
Marks the communicator object for deallocation.
col | a pointer to the collective object |
Definition at line 512 of file sll_m_collective.F90.
logical function, public sll_m_collective::sll_f_collectives_are_same | ( | type(sll_t_collective_t), pointer | col1, |
type(sll_t_collective_t), pointer | col2 | ||
) |
Definition at line 398 of file sll_m_collective.F90.
type(sll_t_collective_t) function, pointer, public sll_m_collective::sll_f_create_collective | ( | intent(in) | comm | ) |
Function to derive a "collective" from a plain MPI communicator,.
Definition at line 1986 of file sll_m_collective.F90.
integer(kind=i32) function, public sll_m_collective::sll_f_get_collective_rank | ( | type(sll_t_collective_t), pointer | col | ) |
Determines the rank of the calling process in the communicator.
col | Collective object |
Definition at line 532 of file sll_m_collective.F90.
integer(kind=i32) function, public sll_m_collective::sll_f_get_collective_size | ( | type(sll_t_collective_t), pointer | col | ) |
Determines the size of the group associated with a communicator.
col | Communicator |
Definition at line 552 of file sll_m_collective.F90.
type(sll_t_collective_t) function, pointer, public sll_m_collective::sll_f_new_collective | ( | type(sll_t_collective_t), pointer | parent, |
intent(in) | color, | ||
intent(in) | key | ||
) |
Creates new (wrapper around) communicators based on colors and keys.
parent | a pointer to the parent collective from which it was split | |
[in] | color | the values of color used for the splitting |
[in] | key | the values of key used for the splitting |
Definition at line 488 of file sll_m_collective.F90.
|
private |
Determines the color of the calling process in the communicator.
col | Collective object |
Definition at line 542 of file sll_m_collective.F90.
|
private |
Gets the id (integer) of the communicator.
col | Pointer to collective object |
Definition at line 522 of file sll_m_collective.F90.
|
private |
Gets collective parent.
col | Wrapper around the communicator |
Definition at line 562 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_allocate_collective |
subroutine, public sll_m_collective::sll_s_boot_collective | ( | integer(kind=i32), intent(in), optional | required | ) |
Starts the paralell environment.
Definition at line 415 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_allgatherv_real64 | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f64), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | send_cnt, | ||
integer(kind=i32), dimension(:), intent(in) | rec_cnt, | ||
integer(kind=i32), dimension(:), intent(in) | displs, | ||
real(kind=f64), dimension(:), intent(out) | rec_buf | ||
) |
Definition at line 958 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_allreduce_logical | ( | type(sll_t_collective_t), pointer | col, |
logical, dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | count, | ||
integer(kind=i32), intent(in) | op, | ||
logical, dimension(:), intent(out) | rec_buf | ||
) |
Combines logical values from all processes and distributes the result back to all processes.
[in] | col | wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | count | number of elements in send buffer |
[in] | op | operation |
[out] | rec_buf | starting address of receive buffer |
Definition at line 1285 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_allreduce_real32 | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f32), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | count, | ||
integer(kind=i32), intent(in) | op, | ||
real(kind=f32), dimension(:), intent(out) | rec_buf | ||
) |
Combines real values from all processes and distributes the result back to all processes.
[in] | col | wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | count | number of elements in send buffer |
[in] | op | operation |
[out] | rec_buf | starting address of receive buffer |
Definition at line 1111 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_allreduce_sum_3d_real64 | ( | type(sll_t_collective_t) | col, |
real(kind=f64), dimension(:, :, :), intent(inout) | buffer | ||
) |
Sums real values from all processes and distributes the result back to all processes.
[in] | col | wrapper around the communicator |
[in,out] | 3d | buffer |
Definition at line 1305 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_alltoall_int | ( | integer(kind=i32), dimension(:), intent(in) | send_buf, |
integer(kind=i32), intent(in) | send_count, | ||
integer(kind=i32), intent(in) | recv_count, | ||
integer(kind=i32), dimension(:), intent(out) | recv_buf, | ||
type(sll_t_collective_t), pointer | col | ||
) |
Sends integer data from all to all processes.
[in] | send_buf | starting address of send buffer |
[in] | send_count | number of elements to send to each process |
[in] | recv_count | number of elements received from any process |
[out] | recv_buf | address of receive buffer |
[in] | col | wrapper around the communicator |
Definition at line 1473 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_alltoallv_double | ( | intent(in) | send_buf, |
intent(in) | send_cnts, | ||
intent(in) | send_displs, | ||
intent(out) | recv_buf, | ||
intent(in) | recv_cnts, | ||
intent(in) | recv_displs, | ||
type(sll_t_collective_t), pointer | col | ||
) |
Definition at line 1568 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_alltoallv_int | ( | intent(in) | send_buf, |
intent(in) | send_cnts, | ||
intent(in) | send_displs, | ||
intent(out) | recv_buf, | ||
intent(in) | recv_cnts, | ||
intent(in) | recv_displs, | ||
type(sll_t_collective_t), pointer | col | ||
) |
Sends integer data from all to all processes; each process may send a different amount of data and provide displacements for the input and output data.
[in] | send_buf | starting address of send buffer |
[in] | send_cnts | integer array equal to the group size specifying the number of elements to send to each processor |
[in] | send_displs | integer array (of length group size). Entry j specifies the displacement (relative to send_buf) from which to take the outgoing data destined for process j |
[out] | recv_buf | address of receive buffer |
[in] | recv_cnts | integer array equal to the group size specifying the maximum number of elements that can be received from each processor |
[in] | recv_displs | integer array (of length group size). Entry i specifies the displacement (relative to recvbuf at which to place the incoming data from process i |
[in] | col | wrapper around the communicator |
Definition at line 1635 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_alltoallv_int_simple | ( | intent(in) | send_buf, |
intent(in) | send_cnts, | ||
dimension(:) | recv_buf, | ||
type(sll_t_collective_t), pointer | col | ||
) |
subroutine, public sll_m_collective::sll_s_collective_alltoallv_real | ( | intent(in) | send_buf, |
intent(in) | send_cnts, | ||
intent(in) | send_displs, | ||
intent(out) | recv_buf, | ||
intent(in) | recv_cnts, | ||
intent(in) | recv_displs, | ||
type(sll_t_collective_t), pointer | col | ||
) |
Sends real data from all to all processes; each process may send a different amount of data and provide displacements for the input and output data.
[in] | send_buf | starting address of send buffer |
[in] | send_cnts | integer array equal to the group size specifying the number of elements to send to each processor |
[in] | send_displs | integer array (of length group size). Entry j specifies the displacement (relative to send_buf) from which to take the outgoing data destined for process j |
[out] | recv_buf | address of receive buffer |
[in] | recv_cnts | integer array equal to the group size specifying the maximum number of elements that can be received from each processor |
[in] | recv_displs | integer array (of length group size). Entry i specifies the displacement (relative to recvbuf at which to place the incoming data from process i |
[in] | col | wrapper around the communicator |
Definition at line 1546 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_barrier | ( | type(sll_t_collective_t), pointer | col | ) |
Blocks until all processes in the communicator have reached this routine.
col | Communicator |
Definition at line 572 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_bcast_3d_real64 | ( | type(sll_t_collective_t) | col, |
real(kind=f64), dimension(:, :, :), intent(inout) | buffer, | ||
integer(kind=i32), intent(in) | root | ||
) |
Broadcasts a 3d array of type 'sll_real64' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | 3d array of type 'sll_real64' |
[in] | size | Number of entries in buffer |
[in] | root | Rank of broadcast root |
Definition at line 728 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_bcast_real64 | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f64), dimension(:), intent(inout) | buffer, | ||
integer(kind=i32), intent(in) | size, | ||
integer(kind=i32), intent(in) | root | ||
) |
Broadcasts an array of type 'sll_real64' from the process with rank "root" to all other processes of the communicator.
col | Wrapper around the communicator | |
[in,out] | buffer | Array of type 'sll_real64' |
[in] | size | Number of entries in buffer |
[in] | root | Rank of broadcast root |
Definition at line 671 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_gatherv_real | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f32), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | send_count, | ||
integer(kind=i32), dimension(:), intent(in) | recvcnts, | ||
integer(kind=i32), dimension(:), intent(in) | displs, | ||
integer(kind=i32), intent(in) | root, | ||
real(kind=f32), dimension(:), intent(out) | rec_buf | ||
) |
Gathers real values into specified locations from all processes in a group.
[in] | col | Wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | send_count | number of elements in send buffer |
[in] | recvcnts | integer array (of length group size) containing the number of elements that are received from each process |
[in] | displs | integer array. Entry i specifies the displacement relative to rec_buf at which to place the incoming data from process i |
[in] | root | rank of receiving process |
[out] | rec_buf | address of receive buffer |
Definition at line 817 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_gatherv_real64 | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f64), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | send_count, | ||
integer(kind=i32), dimension(:), intent(in) | recvcnts, | ||
integer(kind=i32), dimension(:), intent(in) | displs, | ||
integer(kind=i32), intent(in) | root, | ||
real(kind=f64), dimension(:), intent(out) | rec_buf | ||
) |
Gathers real64 values into specified locations from all processes in a group.
[in] | col | Wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | send_count | number of elements in send buffer |
[in] | recvcnts | integer array (of length group size) containing the number of elements that are received from each process |
[in] | displs | integer array. Entry i specifies the displacement relative to rec_buf at which to place the incoming data from process i |
[in] | root | rank of receiving process |
[out] | rec_buf | address of receive buffer |
Definition at line 860 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_globalsum_array_comp64 | ( | type(sll_t_collective_t), pointer | col, |
intent(inout) | summand, | ||
optional | root_rank | ||
) |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1758 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_globalsum_array_real64 | ( | type(sll_t_collective_t), pointer | col, |
intent(inout) | summand, | ||
optional | root_rank | ||
) |
Performs a global sum over an array and writes the result in the given node If no node in root_rank is given, perform an allreduce this means the sum is written to all nodes.
[in] | col | wrapper around the communicator |
[in] | root_rank | rank of root process, where the sum will be stored |
[in,out] | summand | summands of the sum, the result will be written |
[in,out] | in | the variable summand with rank root_rank |
Definition at line 1727 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_reduce_int | ( | type(sll_t_collective_t), pointer | col, |
integer(kind=i32), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | size, | ||
integer(kind=i32), intent(in) | op, | ||
integer(kind=i32), intent(in) | root_rank, | ||
integer(kind=i32), dimension(:), intent(in) | rec_buf | ||
) |
Reduces integer values on all processes to a single value.
[in] | col | wrapper around the communicator |
[in] | send_bu | address of send buffer |
[in] | size | number of elements in send buffer |
[in] | op | reduce operation |
[in] | root_rank | rank of root process |
[out] | rec_buf | address of receive buffer |
Definition at line 1327 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_reduce_logical | ( | type(sll_t_collective_t), pointer | col, |
logical, dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | size, | ||
integer(kind=i32), intent(in) | op, | ||
integer(kind=i32), intent(in) | root_rank, | ||
logical, dimension(:), intent(in) | rec_buf | ||
) |
Reduces logical values on all processes to a single value.
[in] | col | wrapper around the communicator |
[in] | send_bu | address of send buffer |
[in] | size | number of elements in send buffer |
[in] | op | reduce operation |
[in] | root_rank | rank of root process |
[out] | rec_buf | address of receive buffer |
Definition at line 1450 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_reduce_real32 | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f32), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | size, | ||
integer(kind=i32), intent(in) | op, | ||
integer(kind=i32), intent(in) | root_rank, | ||
real(kind=f32), dimension(:), intent(in) | rec_buf | ||
) |
Reduces real values on all processes to a single value.
[in] | col | wrapper around the communicator |
[in] | send_bu | address of send buffer |
[in] | size | number of elements in send buffer |
[in] | op | reduce operation |
[in] | root_rank | rank of root process |
[out] | rec_buf | address of receive buffer |
Definition at line 1351 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_collective_reduce_real64 | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f64), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), intent(in) | size, | ||
integer(kind=i32), intent(in) | op, | ||
integer(kind=i32), intent(in) | root_rank, | ||
real(kind=f64), dimension(:), intent(out) | rec_buf | ||
) |
subroutine, public sll_m_collective::sll_s_collective_scatterv_real | ( | type(sll_t_collective_t), pointer | col, |
real(kind=f32), dimension(:), intent(in) | send_buf, | ||
integer(kind=i32), dimension(:), intent(in) | send_count, | ||
integer(kind=i32), dimension(:), intent(in) | displs, | ||
integer(kind=i32), intent(in) | recv_count, | ||
integer(kind=i32), intent(in) | root, | ||
real(kind=f32), dimension(:), intent(out) | rec_buf | ||
) |
Scatters a buffer in parts to all processes in a communicator.
[in] | col | wrapper around the communicator |
[in] | send_buf | starting address of send buffer |
[in] | send_count | integer array (of length group size) specifying the number of elements to send to each processor |
[in] | displs | integer array (of length group size). Entry i specifies the displacement (relative to sendbuf) from which to take the outgoing data to process i |
[in] | recv_count | number of elements in receive buffer |
[in] | root | rank of sending process |
[out] | rec_buf | starting address of receive buffer |
Definition at line 1085 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_halt_collective |
Ends the paralell environment.
Definition at line 452 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_set_communicator_collective | ( | integer(kind=i32), intent(in) | communicator_in | ) |
Definition at line 438 of file sll_m_collective.F90.
subroutine, public sll_m_collective::sll_s_test_mpi_error | ( | integer(kind=i32), intent(in) | ierr, |
character(len=*), intent(in) | descriptor | ||
) |
Checks the good execution of collective instruction.
Many functions of collective library returns an error code for verify the good execution. With this function you can check the code and print the message descriptor if you encountered an error.
[in] | ierr | error's code |
[in] | descriptor | message to print in error case |
Definition at line 384 of file sll_m_collective.F90.
type(sll_t_collective_t), pointer, public sll_v_world_collective |
Control of subset assignment. Processes with the same color are in the same new communicator.
The Communicator (The same role as MPI_COMM_WORLD)
Definition at line 255 of file sll_m_collective.F90.