Open the restart dump file and set file view for the input variable system
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_restart_type) | :: | me | the restart information |
subroutine tem_restart_openRead_single(me)
! -------------------------------------------------------------------- !
!> the restart information
type(tem_restart_type) :: me
! -------------------------------------------------------------------- !
! variables to catch possible MPI I/O errors
integer :: iError
! -------------------------------------------------------------------- !
! open the binary file for MPI I/O
call MPI_FILE_OPEN( me%comm%comm, &
& trim( me%header%binName ), &
& MPI_MODE_RDONLY, &
& MPI_INFO_NULL, me%binaryUnit, &
& iError )
call check_mpi_error( iError,'Open File in tem_restart_openRead_single')
! set the view of each process on the file opened above
call MPI_FILE_SET_VIEW( me%binaryUnit, me%read_file%displacement, &
& me%read_file%vectype, &
& me%read_file%ftype, "native", &
& MPI_INFO_NULL, iError )
call check_mpi_error( iError,'Set File view in tem_restart_openRead_single')
end subroutine tem_restart_openRead_single