2005-03-26 21:49:16 +03:00
|
|
|
/*
|
2007-03-17 02:11:45 +03:00
|
|
|
* Copyright (c) 2006-2007 The Trustees of Indiana University and Indiana
|
|
|
|
* University Research and Technology
|
|
|
|
* Corporation. All rights reserved.
|
2007-07-11 02:16:38 +04:00
|
|
|
* Copyright (c) 2004-2007 The University of Tennessee and The University
|
2005-11-05 22:57:48 +03:00
|
|
|
* of Tennessee Research Foundation. All rights
|
|
|
|
* reserved.
|
2005-03-26 21:49:16 +03:00
|
|
|
* $COPYRIGHT$
|
|
|
|
*
|
|
|
|
* Additional copyrights may follow
|
|
|
|
*
|
|
|
|
* $HEADER$
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef PML_EXAMPLE_H_HAS_BEEN_INCLUDED
|
|
|
|
#define PML_EXAMPLE_H_HAS_BEEN_INCLUDED
|
|
|
|
|
2006-02-12 04:33:29 +03:00
|
|
|
#include "ompi/request/request.h"
|
|
|
|
#include "ompi/mca/pml/pml.h"
|
|
|
|
#include "ompi/mca/ptl/ptl.h"
|
2005-03-26 21:49:16 +03:00
|
|
|
|
2009-08-20 15:42:18 +04:00
|
|
|
BEGIN_C_DECLS
|
2005-03-26 21:49:16 +03:00
|
|
|
|
|
|
|
struct mca_pml_example_t {
|
|
|
|
mca_pml_base_module_t super;
|
|
|
|
|
|
|
|
mca_ptl_base_component_t **example_ptl_components;
|
|
|
|
size_t example_num_ptl_components;
|
|
|
|
|
|
|
|
mca_ptl_base_module_t** example_ptl_modules;
|
|
|
|
size_t example_num_ptl_modules;
|
|
|
|
|
2005-07-03 20:22:16 +04:00
|
|
|
opal_list_t example_procs;
|
2005-07-04 02:45:48 +04:00
|
|
|
opal_mutex_t example_lock;
|
2005-03-26 21:49:16 +03:00
|
|
|
|
|
|
|
/* list of pending send requests */
|
2005-07-03 20:22:16 +04:00
|
|
|
opal_list_t example_send_pending;
|
2005-03-26 21:49:16 +03:00
|
|
|
};
|
|
|
|
typedef struct mca_pml_example_t mca_pml_example_t;
|
|
|
|
|
|
|
|
extern mca_pml_example_t mca_pml_example;
|
|
|
|
|
|
|
|
/*
|
|
|
|
* PML interface functions.
|
|
|
|
*/
|
|
|
|
extern int mca_pml_example_add_comm( struct ompi_communicator_t* comm );
|
|
|
|
extern int mca_pml_example_del_comm( struct ompi_communicator_t* comm );
|
|
|
|
|
|
|
|
extern int mca_pml_example_add_procs( struct ompi_proc_t **procs, size_t nprocs );
|
|
|
|
extern int mca_pml_example_del_procs( struct ompi_proc_t **procs, size_t nprocs );
|
|
|
|
|
2005-07-03 20:22:16 +04:00
|
|
|
extern int mca_pml_example_add_ptls( opal_list_t *ptls );
|
2005-03-26 21:49:16 +03:00
|
|
|
|
|
|
|
extern int mca_pml_example_control( int param, void *size, size_t value );
|
|
|
|
|
|
|
|
extern int mca_pml_example_iprobe( int dst,
|
|
|
|
int tag,
|
|
|
|
struct ompi_communicator_t* comm,
|
|
|
|
int *matched,
|
|
|
|
ompi_status_public_t* status );
|
|
|
|
|
|
|
|
extern int mca_pml_example_probe( int dst,
|
|
|
|
int tag,
|
|
|
|
struct ompi_communicator_t* comm,
|
|
|
|
ompi_status_public_t* status );
|
|
|
|
|
|
|
|
extern int mca_pml_example_cancel( ompi_request_t* request );
|
|
|
|
extern int mca_pml_example_cancelled( ompi_request_t* request, int *flag );
|
|
|
|
|
|
|
|
extern int mca_pml_example_isend_init( void *buf,
|
|
|
|
size_t count,
|
|
|
|
ompi_datatype_t *datatype,
|
|
|
|
int dst,
|
|
|
|
int tag,
|
|
|
|
mca_pml_base_send_mode_t mode,
|
|
|
|
struct ompi_communicator_t* comm,
|
|
|
|
struct ompi_request_t **request );
|
|
|
|
|
|
|
|
extern int mca_pml_example_isend( void *buf,
|
|
|
|
size_t count,
|
|
|
|
ompi_datatype_t *datatype,
|
|
|
|
int dst,
|
|
|
|
int tag,
|
|
|
|
mca_pml_base_send_mode_t mode,
|
|
|
|
struct ompi_communicator_t* comm,
|
|
|
|
struct ompi_request_t **request );
|
|
|
|
|
|
|
|
extern int mca_pml_example_send( void *buf,
|
|
|
|
size_t count,
|
|
|
|
ompi_datatype_t *datatype,
|
|
|
|
int dst,
|
|
|
|
int tag,
|
|
|
|
mca_pml_base_send_mode_t mode,
|
|
|
|
struct ompi_communicator_t* comm );
|
|
|
|
|
|
|
|
extern int mca_pml_example_irecv_init( void *buf,
|
|
|
|
size_t count,
|
|
|
|
ompi_datatype_t *datatype,
|
|
|
|
int src,
|
|
|
|
int tag,
|
|
|
|
struct ompi_communicator_t* comm,
|
|
|
|
struct ompi_request_t **request );
|
|
|
|
|
|
|
|
extern int mca_pml_example_irecv( void *buf,
|
|
|
|
size_t count,
|
|
|
|
ompi_datatype_t *datatype,
|
|
|
|
int src,
|
|
|
|
int tag,
|
|
|
|
struct ompi_communicator_t* comm,
|
|
|
|
struct ompi_request_t **request );
|
|
|
|
|
|
|
|
extern int mca_pml_example_recv( void *buf,
|
|
|
|
size_t count,
|
|
|
|
ompi_datatype_t *datatype,
|
|
|
|
int src,
|
|
|
|
int tag,
|
|
|
|
struct ompi_communicator_t* comm,
|
|
|
|
ompi_status_public_t* status );
|
|
|
|
|
|
|
|
extern int mca_pml_example_progress(void);
|
|
|
|
|
|
|
|
extern int mca_pml_example_start( size_t count, ompi_request_t** requests );
|
|
|
|
|
2007-03-17 02:11:45 +03:00
|
|
|
extern int mca_pml_example_ft_event(int state);
|
|
|
|
|
|
|
|
|
2009-08-20 15:42:18 +04:00
|
|
|
END_C_DECLS
|
2005-03-26 21:49:16 +03:00
|
|
|
|
|
|
|
#endif /* PML_EXAMPLE_H_HAS_BEEN_INCLUDED */
|