53 character(len=6),
public,
parameter ::
io_stdout =
"STDOUT" 59 logical,
public ::
io_l = .false.
73 integer,
private,
parameter :: io_minfid = 10
74 integer,
private,
parameter :: io_maxfid = 99
86 namelist / param_io / &
94 character(len=H_MID),
intent(in) :: MODELNAME
95 logical,
intent(in) :: call_from_launcher
96 character(len=H_LONG),
intent(in),
optional :: fname_in
98 character(len=H_LONG) :: fname
102 if ( call_from_launcher )
then 103 if (
present(fname_in) )
then 106 write(*,*)
' xxx Not imported name of config file! STOP.' 118 h_libname =
'SCALE Library ver. '//trim(libversion)
125 write(*,*)
' xxx Not appropriate names in namelist PARAM_IO . Check!' 139 integer,
intent(in) :: myrank
140 logical,
intent(in) :: is_master
142 character(len=H_LONG) :: fname
147 if ( is_master )
then 169 file = trim(fname), &
170 form =
'formatted', &
172 if ( ierr /= 0 )
then 173 write(*,*)
'xxx File open error! :', trim(fname)
183 write(
io_fid_log,*)
' .+++++++++++++++++++++++ ' 184 write(
io_fid_log,*)
' +++++++++++++++++++++++++ ' 185 write(
io_fid_log,*)
' +++++++++++++++++++++++++++ ' 186 write(
io_fid_log,*)
' =++++++=x######+++++++++++++; ' 187 write(
io_fid_log,*)
' .++++++X####XX####++++++++++++ ' 188 write(
io_fid_log,*)
' =+xxx=, ++++ +++++=##+ .###++++++++++- ' 189 write(
io_fid_log,*)
' ,xxxxxxxxxx- +++++.+++++=## .##++++++++++ ' 190 write(
io_fid_log,*)
' xxxxxxxxxxxxx -+++x#;+++++#+ ##+++++++++. ' 191 write(
io_fid_log,*)
' xxxxxxxx##xxxx, ++++# +++++XX #+++++++++- ' 192 write(
io_fid_log,*)
' xxxxxxx####+xx+x ++++#.++++++# #+++++++++ ' 193 write(
io_fid_log,*)
' +xxxxxX#X #Xx#= =+++#x=++++=#. x=++++++++ ' 194 write(
io_fid_log,*)
' xxxxxx#, x### .++++#,+++++#= x++++++++ ' 195 write(
io_fid_log,*)
' xxxxxx#. ++++# +++++x# #++++++++ ' 196 write(
io_fid_log,*)
' xxxxxx+ ++++#-+++++=# #++++++++ ' 197 write(
io_fid_log,*)
',xxxxxX -+++XX-+++++#, +++++++++ ' 198 write(
io_fid_log,*)
'=xxxxxX .++++#.+++++#x -++++++++ ' 199 write(
io_fid_log,*)
'+xxxxx= ++++#.++++++# ++++++++# ' 200 write(
io_fid_log,*)
'xxxxxx; ++++#+=++++=# ++++++++# ' 201 write(
io_fid_log,*)
'xxxxxxx ,+++x#,+++++#- ;++++++++- ' 202 write(
io_fid_log,*)
'#xxxxxx +++=# +++++xX ++++++++# ' 203 write(
io_fid_log,*)
'xxxxxxxx ++++#-+++++=# +++++++++X ' 204 write(
io_fid_log,*)
'-+xxxxxx+ ++++X#-++++=#. -++; =++++++++# ' 205 write(
io_fid_log,*)
' #xxxxxxxx. .+++++# +++++#x =++++- +++++++++XX ' 206 write(
io_fid_log,*)
' #xxxxxxxxxx=--=++++++#.++++++# ++++++ -+++++++++x# ' 207 write(
io_fid_log,*)
' #+xxxxxxxxxx+++++++#x=++++=# ++++++;=+++++++++++x# ' 208 write(
io_fid_log,*)
' =#+xxxxxxxx+++++++##,+++++#= =++++++++++++++++++##. ' 209 write(
io_fid_log,*)
' X#xxxxxxxx++++++## +++++x# ;x++++++++++++++++##. ' 210 write(
io_fid_log,*)
' x##+xxxx+++++x## +++++=# ##++++++++++++x##X ' 211 write(
io_fid_log,*)
' ,###Xx+++x###x -++++=#, .####x+++++X####. ' 212 write(
io_fid_log,*)
' -########+ -#####x .X#########+. ' 215 write(
io_fid_log,*)
' .X####### +###- =###+ ###x x######## ' 216 write(
io_fid_log,*)
' .######### ######X ####### #### .#########x ' 217 write(
io_fid_log,*)
' ####+++++= X#######. -#######x .###; ####x+++++. ' 218 write(
io_fid_log,*)
' ### ###= #### #### x### #### -###. ' 219 write(
io_fid_log,*)
' .### #### ###+ X### ###X =###. #### ' 220 write(
io_fid_log,*)
' ###- ;###, .###+ -### #### x##########+ ' 221 write(
io_fid_log,*)
' +####x #### #### #### #### ###########. ' 222 write(
io_fid_log,*)
' x######. =### ###, .###- ###+ x###-------- ' 223 write(
io_fid_log,*)
' =##### X### -### #### ,### #### ' 224 write(
io_fid_log,*)
' .###=x###; .###+ ###X ###X ####. ' 225 write(
io_fid_log,*)
' ###########; ###########+ ########### ########### ,##########. ' 226 write(
io_fid_log,*)
'-########### ,##########, #########X ########## +######### ' 227 write(
io_fid_log,*)
',,,,,,,,,,. ,,,,,,,,, .,,,,,,,. .,,,,,,,, ,,,,,,,, ' 229 write(
io_fid_log,*)
' SCALE : Scalable Computing by Advanced Library and Environment ' 234 write(
io_fid_log,*)
'++++++ Module[STDIO] / Categ[IO] / Origin[SCALElib]' 242 if( is_master )
write(*,*)
'*** Log report is suppressed.' 258 do fid = io_minfid, io_maxfid
259 inquire(fid,opened=i_opened)
260 if ( .NOT. i_opened )
return 275 character(len=*),
intent(out) :: outstr
276 character(len=*),
intent(in) :: instr
277 character(len=*),
intent(in) :: ext
278 integer,
intent(in) :: rank
279 logical,
intent(in),
optional :: isrgn
281 character(len=H_SHORT) :: srank
284 write(srank,
'(I6.6)') rank
286 if (
present(isrgn) )
then 287 if(isrgn)
write(srank,
'(I8.8)') rank-1
290 outstr = trim(instr)//
'.'//trim(ext)//trim(srank)
301 logical,
intent(in) :: is_master
302 character(len=H_LONG) :: fname
305 if ( command_argument_count() < 1 )
then 306 if(is_master)
write(*,*)
'xxx Program needs config file from argument! STOP.' 309 call get_command_argument(1,fname)
323 character(len=*),
intent(in) :: fname
324 logical,
intent(in) :: is_master
333 file = trim(fname), &
334 form =
'formatted', &
338 if ( ierr /= 0 )
then 339 if(is_master)
write(*,*)
'xxx Failed to open config file! STOP.' 340 if(is_master)
write(*,*)
'xxx filename : ', trim(fname)
logical, public io_l
output log or not? (this process)
integer, parameter, public h_long
Character length (short=256)
integer, parameter, public io_fid_stdout
subroutine, public io_make_idstr(outstr, instr, ext, rank, isrgn)
generate process specific filename
character(len=h_long) function, public io_arg_getfname(is_master)
get config filename from argument
character(len=h_mid), public h_modelname
name and version of the model
subroutine, public io_log_setup(myrank, is_master)
Setup LOG.
character(len=6), parameter, public io_stdout
logical, public io_log_suppress
suppress all of log output?
character(len=h_mid), public h_source
for file header
integer function, public io_get_available_fid()
search & get available file ID
subroutine, public io_setup(MODELNAME, call_from_launcher, fname_in)
Setup.
logical, public io_log_allnode
output log for each node?
integer, parameter, public h_short
Character length (short=16)
character(len=h_mid), public h_institute
for file header
logical, public io_lnml
output log or not? (for namelist, this process)
integer, public io_fid_conf
Config file ID.
character(len=h_mid), public h_libname
name and version of the library
integer, parameter, public h_mid
Character length (short=64)
integer, public io_fid_log
Log file ID.
character(len=h_long), public io_log_basename
basename of logfile
logical, public io_log_nml_suppress
suppress all of log output?
integer function, public io_cnf_open(fname, is_master)
open config file