Some auxilary routines, providing frequently needed common tasks.
Auxiliary subroutine to check on errors from attempting to get values from the Lua script with aot_get_val.
If a fatal error was encountered, the routine aborts the program!
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | iError |
aoterr code to interpret (returned by aot_get_val) |
||
| character(len=*), | intent(in) | :: | key |
Lua key that was attempted to be read |
||
| character(len=*), | intent(in), | optional | :: | event_string |
Optional event string to describe the circumstances |
Auxiliary subroutine to check on errors from attempting to get an array of values from the Lua script with aot_get_val.
If a fatal error was encountered, the routine aborts the program!
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | iError(:) |
aoterr code to interpret (returned by aot_get_val) |
||
| character(len=*), | intent(in) | :: | key |
Lua key that was attempted to be read |
||
| character(len=*), | intent(in), | optional | :: | event_string |
Optional event string to describe the circumstances |
Obtain the memory status from all processes (min, max, avg).
Function to create a human readable UTC date string.
Read a Lua file on the first process and distribute it to all.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(flu_State) | :: | L | ||||
| character(len=*), | intent(in) | :: | fileName | |||
| type(tem_comm_env_type), | intent(in) | :: | proc |
Process description to use. |
Open an array of Lua handles.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(flu_State) | :: | L(:) | ||||
| character(len=*), | intent(in) | :: | fileName | |||
| type(tem_comm_env_type) | :: | proc |
Wrapper around Fortran open of files to take care of errors and improve the error message in case the opening goes wrong.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | file | |||
| integer, | intent(in), | optional | :: | unit | ||
| integer, | intent(out), | optional | :: | newunit | ||
| character(len=*), | intent(in), | optional | :: | status | ||
| character(len=*), | intent(in), | optional | :: | position | ||
| character(len=*), | intent(in), | optional | :: | action | ||
| character(len=*), | intent(in), | optional | :: | form | ||
| character(len=*), | intent(in), | optional | :: | access | ||
| integer, | intent(in), | optional | :: | recl |
Abort the program with finalization of the environment
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in), | optional | :: | errorMsg |
An optional error message to print a reason for the abort. |
Check, if a unit is open, and close it
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer | :: | me |
the restart type to close |
check whether the current label is already given
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | label(:) |
holding array of labels with label(n) contains current label |
||
| integer, | intent(in) | :: | nLabels |
Number of schemes already existing in the scheme array (they are being added currently, so we only have to compare against the ones coming before the current one, up to nSchemes-1) |
Print information of the executable
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | iError | |||
| character(len=*), | intent(in) | :: | event_string |
Auxiliary subroutine to check on errors from attempting to get values from the Lua script with aot_get_val.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | iError |
aoterr code to interpret (returned by aot_get_val) |
||
| character(len=*), | intent(in) | :: | key |
Lua key that was attempted to be read |
||
| character(len=*), | intent(in), | optional | :: | event_string |
Optional event string to describe the circumstances |
Auxiliary subroutine to check on errors from attempting to get an array of values from the Lua script with aot_get_val.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | iError(:) |
aoterr code to interpret (returned by aot_get_val) |
||
| character(len=*), | intent(in) | :: | key |
Lua key that was attempted to be read |
||
| character(len=*), | intent(in), | optional | :: | event_string |
Optional event string to describe the circumstances |