2004-01-10 01:09:51 +03:00
|
|
|
/*
|
|
|
|
* $HEADER$
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef LAM_PROC
|
|
|
|
#define LAM_PROC
|
|
|
|
|
2004-03-19 00:35:28 +03:00
|
|
|
#include "include/types.h"
|
2004-03-17 21:45:16 +03:00
|
|
|
#include "lfc/lam_list.h"
|
2004-03-26 17:15:20 +03:00
|
|
|
#include "datatype/datatype.h"
|
2004-01-10 01:09:51 +03:00
|
|
|
|
|
|
|
|
2004-02-13 01:42:39 +03:00
|
|
|
extern lam_class_t lam_proc_t_class;
|
2004-01-10 01:09:51 +03:00
|
|
|
|
|
|
|
|
|
|
|
struct lam_proc_t {
|
2004-02-14 01:16:39 +03:00
|
|
|
lam_list_item_t super; /* allow proc to be placed on a list */
|
|
|
|
lam_job_handle_t proc_job; /* identifies a unique job */
|
|
|
|
uint32_t proc_vpid; /* process identifier w/in the job */
|
|
|
|
struct mca_pml_proc_t* proc_pml; /* PML specific proc data */
|
|
|
|
struct mca_base_modex_t* proc_modex; /* MCA module exchange data */
|
2004-03-26 17:15:20 +03:00
|
|
|
int proc_arch;
|
|
|
|
lam_convertor_t* proc_convertor;
|
2004-01-10 01:09:51 +03:00
|
|
|
|
|
|
|
/* JMS: need to have the following information:
|
|
|
|
|
|
|
|
- endian info
|
|
|
|
- type size info
|
|
|
|
- peer parallel job id
|
|
|
|
- how am i [mpi] connected (bitmap): spawn (parent/child),
|
|
|
|
connect, accept, joint
|
|
|
|
*/
|
|
|
|
};
|
|
|
|
typedef struct lam_proc_t lam_proc_t;
|
|
|
|
|
|
|
|
|
2004-02-13 16:56:55 +03:00
|
|
|
/**
|
|
|
|
* Query the run-time environment and build list of available proc instances.
|
|
|
|
*/
|
|
|
|
int lam_proc_init(void);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the list of proc instances associated with this job.
|
|
|
|
*/
|
|
|
|
lam_proc_t** lam_proc_world(size_t* size);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the list of all known proc instances.
|
|
|
|
*/
|
|
|
|
lam_proc_t** lam_proc_all(size_t* size);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns a list (of one) proc instances.
|
|
|
|
*/
|
|
|
|
lam_proc_t** lam_proc_self(size_t* size);
|
2004-01-29 18:34:47 +03:00
|
|
|
|
2004-02-13 16:56:55 +03:00
|
|
|
/**
|
|
|
|
* Returns the proc instance corresponding to the local proc.
|
|
|
|
*/
|
2004-01-29 18:34:47 +03:00
|
|
|
static inline lam_proc_t* lam_proc_local(void)
|
|
|
|
{
|
2004-02-13 16:56:55 +03:00
|
|
|
extern lam_proc_t* lam_proc_local_proc;
|
|
|
|
return lam_proc_local_proc;
|
2004-01-29 18:34:47 +03:00
|
|
|
}
|
2004-01-10 01:09:51 +03:00
|
|
|
|
|
|
|
#endif /* LAM_PROC */
|
|
|
|
|