Nodes of different colours represent the following:
Solid arrows point from a submodule to the (sub)module which it is
descended from. Dashed arrows point from a module or program unit to
modules which it uses.
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Source Code
subroutine set_openacc_deviceuse mpiuse openaccinteger::local_rank,comm_shared,my_device,num_devices,ierrorinteger(acc_device_kind)::dev_typecall MPI_COMM_SPLIT_TYPE(MPI_COMM_WORLD,MPI_COMM_TYPE_SHARED,0,MPI_INFO_NULL,comm_shared,ierror)call MPI_COMM_RANK(comm_shared,local_rank,ierror)dev_type=ACC_DEVICE_DEFAULTnum_devices=acc_get_num_devices(dev_type)if(num_devices<1)error stop"No devices available on host"my_device=mod(local_rank,num_devices)call acc_set_device_num(my_device,dev_type)end subroutine set_openacc_device