mpi_bcast_real_dp_array Subroutine

public subroutine mpi_bcast_real_dp_array(ctx, values, root)

root rankの倍精度配列を全rankへbroadcastする。

Arguments

Type IntentOptional Attributes Name
type(mpi_context), intent(in) :: ctx
real(kind=dp), intent(inout) :: values(:)
integer(kind=i32), intent(in) :: root

Called by

proc~~mpi_bcast_real_dp_array~~CalledByGraph proc~mpi_bcast_real_dp_array mpi_bcast_real_dp_array proc~load_restart_checkpoint load_restart_checkpoint proc~load_restart_checkpoint->proc~mpi_bcast_real_dp_array proc~precompute_periodic_root_operator precompute_periodic_root_operator proc~precompute_periodic_root_operator->proc~mpi_bcast_real_dp_array proc~solve_matching_implicit_zero_mode solve_matching_implicit_zero_mode proc~solve_matching_implicit_zero_mode->proc~mpi_bcast_real_dp_array proc~core_build_panel_plan_impl core_build_panel_plan_impl proc~core_build_panel_plan_impl->proc~precompute_periodic_root_operator proc~core_build_plan_impl core_build_plan_impl proc~core_build_plan_impl->proc~precompute_periodic_root_operator proc~load_or_init_run_state load_or_init_run_state proc~load_or_init_run_state->proc~load_restart_checkpoint program~main main program~main->proc~load_or_init_run_state

Source Code

  subroutine mpi_bcast_real_dp_array(ctx, values, root)
    type(mpi_context), intent(in) :: ctx
    real(dp), intent(inout) :: values(:)
    integer(i32), intent(in) :: root
#ifdef USE_MPI
    integer :: ierr
#endif

    if (root < 0_i32 .or. root >= max(1_i32, ctx%size)) then
      error stop 'mpi_bcast_real_dp_array root out of range.'
    end if
#ifdef USE_MPI
    if (.not. ctx%enabled) return
    call MPI_Bcast(values, size(values), MPI_DOUBLE_PRECISION, int(root), MPI_COMM_WORLD, ierr)
#endif
  end subroutine mpi_bcast_real_dp_array