ParallelIO
|
PIO async message handling. More...
Functions | |
int | inq_type_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to handle nc_inq_type*() functions. More... | |
int | inq_format_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to find netCDF file format. More... | |
int | create_file_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to create a netCDF file. More... | |
int | close_file_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to close a netCDF file. More... | |
int | inq_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to inq a netCDF file. More... | |
int | inq_dim_handler (iosystem_desc_t *ios, int msg) |
Do an inq_dim on a netCDF dimension. More... | |
int | inq_dimid_handler (iosystem_desc_t *ios) |
Do an inq_dimid on a netCDF dimension name. More... | |
int | inq_att_handler (iosystem_desc_t *ios) |
Handle attribute inquiry operations. More... | |
int | inq_attname_handler (iosystem_desc_t *ios) |
Handle attribute inquiry operations. More... | |
int | inq_attid_handler (iosystem_desc_t *ios) |
Handle attribute inquiry operations. More... | |
int | att_put_handler (iosystem_desc_t *ios) |
Handle attribute operations. More... | |
int | att_get_handler (iosystem_desc_t *ios) |
Handle attribute operations. More... | |
int | put_vars_handler (iosystem_desc_t *ios) |
Handle var put operations. More... | |
int | get_vars_handler (iosystem_desc_t *ios) |
Handle var get operations. More... | |
int | inq_var_handler (iosystem_desc_t *ios) |
Do an inq_var on a netCDF variable. More... | |
int | inq_varid_handler (iosystem_desc_t *ios) |
Do an inq_varid on a netCDF variable name. More... | |
int | sync_file_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to sync a netCDF file. More... | |
int | change_def_file_handler (iosystem_desc_t *ios, int msg) |
This function is run on the IO tasks to enddef a netCDF file. More... | |
int | def_var_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to define a netCDF variable. More... | |
int | def_dim_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to define a netCDF dimension. More... | |
int | rename_dim_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to rename a netCDF dimension. More... | |
int | rename_var_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to rename a netCDF dimension. More... | |
int | rename_att_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to rename a netCDF attribute. More... | |
int | delete_att_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to delete a netCDF attribute. More... | |
int | open_file_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to open a netCDF file. More... | |
int | delete_file_handler (iosystem_desc_t *ios) |
This function is run on the IO tasks to delete a netCDF file. More... | |
int | initdecomp_dof_handler (iosystem_desc_t *ios) |
int | writedarray_handler (iosystem_desc_t *ios) |
int | readdarray_handler (iosystem_desc_t *ios) |
int | seterrorhandling_handler (iosystem_desc_t *ios) |
int | var_handler (iosystem_desc_t *ios, int msg) |
int | freedecomp_handler (iosystem_desc_t *ios) |
int | PIOc_noop_finalize (const int iosysid) |
int | finalize_handler (iosystem_desc_t *ios, int index) |
int | pio_callback_handler (iosystem_desc_t *ios, int msg) |
int | pio_msg_handler2 (int io_rank, int component_count, iosystem_desc_t **iosys, MPI_Comm io_comm) |
This function is called by the IO tasks. More... | |
int | PIOc_Init_Async (MPI_Comm world, int num_io_procs, int *io_proc_list, int component_count, int *num_procs_per_comp, int **proc_list, int *iosysidp) |
Library initialization used when IO tasks are distinct from compute tasks. More... | |
PIO async message handling.
This file contains the code which runs on the IO nodes when async is in use. This code waits for messages from the computation nodes, and responds to messages by running the appropriate netCDF function.
int att_get_handler | ( | iosystem_desc_t * | ios | ) |
Handle attribute operations.
This code only runs on IO tasks.
ios | pointer to the iosystem_desc_t. |
msg | the message sent my the comp root task. |
int att_put_handler | ( | iosystem_desc_t * | ios | ) |
Handle attribute operations.
This code only runs on IO tasks.
ios | pointer to the iosystem_desc_t. |
msg | the message sent my the comp root task. |
int change_def_file_handler | ( | iosystem_desc_t * | ios, |
int | msg | ||
) |
This function is run on the IO tasks to enddef a netCDF file.
ios | pointer to the iosystem_desc_t. |
int close_file_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to close a netCDF file.
It is only ever run on the IO tasks.
ios | pointer to the iosystem_desc_t. |
int create_file_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to create a netCDF file.
int def_dim_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to define a netCDF dimension.
int def_var_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to define a netCDF variable.
int delete_att_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to delete a netCDF attribute.
int delete_file_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to delete a netCDF file.
ios | pointer to the iosystem_desc_t data. |
int get_vars_handler | ( | iosystem_desc_t * | ios | ) |
Handle var get operations.
This code only runs on IO tasks.
ios | pointer to the iosystem_desc_t. |
Length (in bytes) of this type.
Type of the data being written.
Number of dimensions.
Buffer for data storage.
Number of data elements in the buffer.
int inq_att_handler | ( | iosystem_desc_t * | ios | ) |
Handle attribute inquiry operations.
This code only runs on IO tasks.
ios | pointer to the iosystem_desc_t. |
msg | the message sent my the comp root task. |
int inq_attid_handler | ( | iosystem_desc_t * | ios | ) |
Handle attribute inquiry operations.
This code only runs on IO tasks.
ios | pointer to the iosystem_desc_t. |
msg | the message sent my the comp root task. |
int inq_attname_handler | ( | iosystem_desc_t * | ios | ) |
Handle attribute inquiry operations.
This code only runs on IO tasks.
ios | pointer to the iosystem_desc_t. |
msg | the message sent my the comp root task. |
int inq_dim_handler | ( | iosystem_desc_t * | ios, |
int | msg | ||
) |
Do an inq_dim on a netCDF dimension.
This function is only run on IO tasks.
ios | pointer to the iosystem_desc_t. |
msg | the message sent my the comp root task. |
int inq_dimid_handler | ( | iosystem_desc_t * | ios | ) |
Do an inq_dimid on a netCDF dimension name.
This function is only run on IO tasks.
ios | pointer to the iosystem_desc_t. |
int inq_format_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to find netCDF file format.
int inq_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to inq a netCDF file.
It is only ever run on the IO tasks.
ios | pointer to the iosystem_desc_t. |
int inq_type_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to handle nc_inq_type*() functions.
int inq_var_handler | ( | iosystem_desc_t * | ios | ) |
Do an inq_var on a netCDF variable.
This function is only run on IO tasks.
ios | pointer to the iosystem_desc_t. |
msg | the message sent my the comp root task. |
int inq_varid_handler | ( | iosystem_desc_t * | ios | ) |
Do an inq_varid on a netCDF variable name.
This function is only run on IO tasks.
ios | pointer to the iosystem_desc_t. |
int open_file_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to open a netCDF file.
ios | pointer to the iosystem_desc_t data. |
int pio_msg_handler2 | ( | int | io_rank, |
int | component_count, | ||
iosystem_desc_t ** | iosys, | ||
MPI_Comm | io_comm | ||
) |
This function is called by the IO tasks.
This function will not return, unless there is an error.
int PIOc_Init_Async | ( | MPI_Comm | world, |
int | num_io_procs, | ||
int * | io_proc_list, | ||
int | component_count, | ||
int * | num_procs_per_comp, | ||
int ** | proc_list, | ||
int * | iosysidp | ||
) |
Library initialization used when IO tasks are distinct from compute tasks.
This is a collective call. Input parameters are read on comp_rank=0 values on other tasks are ignored. This variation of PIO_init sets up a distinct set of tasks to handle IO, these tasks do not return from this call. Instead they go to an internal loop and wait to receive further instructions from the computational tasks.
Here is the sequence of events that needs to occur when an IO operation is called from the collection of compute tasks. I'm going to use pio_put_var because write_darray has some special characteristics that make it a bit more complicated...
Compute tasks call pio_put_var with an integer argument
The MPI_Send sends a message from comp_rank=0 to io_rank=0 on union_comm (a comm defined as the union of io and compute tasks) msg is an integer which indicates the function being called, in this case the msg is PIO_MSG_PUT_VAR_INT
The iotasks now know what additional arguments they should expect to receive from the compute tasks, in this case a file handle, a variable id, the length of the array and the array itself.
The iotasks now have the information they need to complete the operation and they call the pio_put_var routine. (In pio1 this bit of code is in pio_get_put_callbacks.F90.in)
After the netcdf operation is completed (in the case of an inq or get operation) the result is communicated back to the compute tasks.
world | the communicator containing all the available tasks. |
num_io_procs | the number of processes for the IO component. |
io_proc_list | an array of lenth num_io_procs with the processor number for each IO processor. If NULL then the IO processes are assigned starting at processes 0. |
component_count | number of computational components |
num_procs_per_comp | an array of int, of length component_count, with the number of processors in each computation component. |
proc_list | an array of arrays containing the processor numbers for each computation component. If NULL then the computation components are assigned processors sequentially starting with processor num_io_procs. |
iosysidp | pointer to array of length component_count that gets the iosysid for each component. |
int put_vars_handler | ( | iosystem_desc_t * | ios | ) |
Handle var put operations.
This code only runs on IO tasks.
ios | pointer to the iosystem_desc_t. |
Length (in bytes) of this type.
Type of the data being written.
Number of dimensions.
Buffer for data storage.
Number of data elements in the buffer.
int rename_att_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to rename a netCDF attribute.
int rename_dim_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to rename a netCDF dimension.
int rename_var_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to rename a netCDF dimension.
int sync_file_handler | ( | iosystem_desc_t * | ios | ) |
This function is run on the IO tasks to sync a netCDF file.
ios | pointer to the iosystem_desc_t. |