2004-01-18 02:07:40 +03:00
|
|
|
/*
|
2004-11-22 04:38:40 +03:00
|
|
|
* Copyright (c) 2004-2005 The Trustees of Indiana University.
|
|
|
|
* All rights reserved.
|
|
|
|
* Copyright (c) 2004-2005 The Trustees of the University of Tennessee.
|
|
|
|
* All rights reserved.
|
2004-11-28 23:09:25 +03:00
|
|
|
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
|
|
* University of Stuttgart. All rights reserved.
|
2005-03-24 15:43:37 +03:00
|
|
|
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
|
|
* All rights reserved.
|
2004-11-22 04:38:40 +03:00
|
|
|
* $COPYRIGHT$
|
|
|
|
*
|
|
|
|
* Additional copyrights may follow
|
|
|
|
*
|
2004-01-18 02:07:40 +03:00
|
|
|
* $HEADER$
|
|
|
|
*/
|
|
|
|
|
2004-03-17 22:03:26 +03:00
|
|
|
#ifndef MCA_BASE_H
|
|
|
|
#define MCA_BASE_H
|
2004-01-18 02:07:40 +03:00
|
|
|
|
2005-03-14 23:57:21 +03:00
|
|
|
#include "ompi_config.h"
|
|
|
|
|
2004-03-17 22:14:14 +03:00
|
|
|
#include "libltdl/ltdl.h"
|
2004-01-18 02:07:40 +03:00
|
|
|
|
2004-06-29 04:02:25 +04:00
|
|
|
#include "class/ompi_object.h"
|
2004-03-17 22:27:02 +03:00
|
|
|
|
2004-01-18 02:07:40 +03:00
|
|
|
/*
|
|
|
|
* These units are large enough to warrant their own .h files
|
|
|
|
*/
|
2004-03-17 21:45:16 +03:00
|
|
|
#include "mca/base/mca_base_param.h"
|
|
|
|
#include "mca/base/mca_base_module_exchange.h"
|
2004-06-16 00:35:30 +04:00
|
|
|
#include "mca/base/mca_base_msgbuf.h"
|
2004-01-18 02:07:40 +03:00
|
|
|
|
2004-10-21 02:31:03 +04:00
|
|
|
#if defined(c_plusplus) || defined(__cplusplus)
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
2004-01-18 02:07:40 +03:00
|
|
|
|
2004-01-22 03:37:58 +03:00
|
|
|
/*
|
2004-08-02 04:24:22 +04:00
|
|
|
* Structure for making plain lists of components
|
2004-01-22 03:37:58 +03:00
|
|
|
*/
|
2004-08-02 04:24:22 +04:00
|
|
|
struct mca_base_component_list_item_t {
|
2004-06-07 19:33:53 +04:00
|
|
|
ompi_list_item_t super;
|
2004-08-02 04:24:22 +04:00
|
|
|
const mca_base_component_t *cli_component;
|
2004-01-22 03:37:58 +03:00
|
|
|
};
|
2004-08-02 04:24:22 +04:00
|
|
|
typedef struct mca_base_component_list_item_t mca_base_component_list_item_t;
|
|
|
|
OBJ_CLASS_DECLARATION(mca_base_component_list_item_t);
|
2004-01-22 03:37:58 +03:00
|
|
|
|
|
|
|
|
2004-03-17 22:27:02 +03:00
|
|
|
/*
|
2004-06-29 04:02:25 +04:00
|
|
|
* Structure for making priority lists of components
|
2004-03-17 22:27:02 +03:00
|
|
|
*/
|
2004-06-29 04:02:25 +04:00
|
|
|
struct mca_base_component_priority_list_item_t {
|
2004-11-12 19:55:41 +03:00
|
|
|
mca_base_component_list_item_t super;
|
2004-06-29 04:02:25 +04:00
|
|
|
|
|
|
|
int cpli_priority;
|
|
|
|
};
|
|
|
|
typedef struct mca_base_component_priority_list_item_t
|
|
|
|
mca_base_component_priority_list_item_t;
|
|
|
|
OBJ_CLASS_DECLARATION(mca_base_component_priority_list_item_t);
|
|
|
|
|
2004-03-17 22:27:02 +03:00
|
|
|
|
2004-01-18 02:07:40 +03:00
|
|
|
/*
|
|
|
|
* Public variables
|
|
|
|
*/
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC extern int mca_base_param_component_path;
|
2004-01-18 02:07:40 +03:00
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Public functions
|
|
|
|
*/
|
|
|
|
|
2004-06-29 04:02:25 +04:00
|
|
|
/**
|
|
|
|
* First function called in the MCA.
|
|
|
|
*
|
|
|
|
* @return OMPI_SUCCESS Upon success
|
|
|
|
* @return OMPI_ERROR Upon failure
|
|
|
|
*
|
|
|
|
* This function starts up the entire MCA. It initializes a bunch
|
2004-08-02 04:24:22 +04:00
|
|
|
* of built-in MCA parameters, and initialized the MCA component
|
2004-06-29 04:02:25 +04:00
|
|
|
* repository.
|
|
|
|
*
|
|
|
|
* It must be the first MCA function invoked. It is normally
|
|
|
|
* invoked during ompi_mpi_init() and specifically invoked in the
|
|
|
|
* special case of the laminfo command.
|
|
|
|
*/
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_open(void);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Last function called in the MCA
|
|
|
|
*
|
|
|
|
* @return OMPI_SUCCESS Upon success
|
|
|
|
* @return OMPI_ERROR Upon failure
|
|
|
|
*
|
|
|
|
* This function closes down the entire MCA. It clears all MCA
|
2004-08-02 04:24:22 +04:00
|
|
|
* parameters and closes down the MCA component respository.
|
2004-06-29 04:02:25 +04:00
|
|
|
*
|
|
|
|
* It must be the last MCA function invoked. It is normally invoked
|
|
|
|
* during ompi_mpi_finalize() and specifically invoked during the
|
|
|
|
* special case of the laminfo command.
|
|
|
|
*/
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_close(void);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
|
|
|
/* mca_base_cmd_line.c */
|
|
|
|
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_cmd_line_setup(ompi_cmd_line_t *cmd);
|
|
|
|
OMPI_DECLSPEC int mca_base_cmd_line_process_args(ompi_cmd_line_t *cmd);
|
|
|
|
OMPI_DECLSPEC int mca_base_cmd_line_process_arg(const char *param, const char *value);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-08-02 04:24:22 +04:00
|
|
|
/* mca_base_component_compare.c */
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_component_compare_priority(mca_base_component_priority_list_item_t *a,
|
2004-08-02 04:24:22 +04:00
|
|
|
mca_base_component_priority_list_item_t *b);
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_component_compare(const mca_base_component_t *a,
|
2004-08-02 04:24:22 +04:00
|
|
|
const mca_base_component_t *b);
|
2004-10-15 00:50:06 +04:00
|
|
|
int mca_base_component_compatible(const mca_base_component_t *a,
|
|
|
|
const mca_base_component_t *b);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-08-02 04:24:22 +04:00
|
|
|
/* mca_base_component_find.c */
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_component_find(const char *directory, const char *type,
|
2004-08-02 04:24:22 +04:00
|
|
|
const mca_base_component_t *static_components[],
|
|
|
|
ompi_list_t *found_components);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-08-02 04:24:22 +04:00
|
|
|
/* mca_base_component_register.c */
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_component_repository_initialize(void);
|
|
|
|
OMPI_DECLSPEC int mca_base_component_repository_retain(char *type,
|
2004-08-02 04:24:22 +04:00
|
|
|
lt_dlhandle component_handle,
|
|
|
|
const mca_base_component_t *component_struct);
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_component_repository_link(const char *src_type,
|
2004-06-29 04:02:25 +04:00
|
|
|
const char *src_name,
|
|
|
|
const char *depend_type,
|
|
|
|
const char *depend_name);
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC void mca_base_component_repository_release(const mca_base_component_t *component);
|
|
|
|
OMPI_DECLSPEC void mca_base_component_repository_finalize(void);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-08-02 04:24:22 +04:00
|
|
|
/* mca_base_components_open.c */
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_components_open(const char *type_name, int output_id,
|
2004-08-02 04:24:22 +04:00
|
|
|
const mca_base_component_t **static_components,
|
|
|
|
ompi_list_t *components_available);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-08-02 04:24:22 +04:00
|
|
|
/* mca_base_components_close.c */
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-10-22 20:06:05 +04:00
|
|
|
OMPI_DECLSPEC int mca_base_components_close(int output_id, ompi_list_t *components_available,
|
2004-08-02 04:24:22 +04:00
|
|
|
const mca_base_component_t *skip);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
2004-03-17 22:03:26 +03:00
|
|
|
#if 0
|
2004-06-29 04:02:25 +04:00
|
|
|
/* JMS Not implemented yet */
|
|
|
|
int mca_base_init_callback(mca_base_init_cb_t func);
|
|
|
|
int mca_base_init_callbacks_invoke(void);
|
2004-08-02 04:24:22 +04:00
|
|
|
int mca_base_component_select(int requested);
|
2004-06-29 04:02:25 +04:00
|
|
|
|
|
|
|
int mca_base_param_associate(int index, int keyval);
|
|
|
|
int mca_base_param_lookup_int(int index, MPI_Comm comm);
|
|
|
|
char *mca_base_param_lookup_string(int index, MPI_Comm comm);
|
2004-03-17 22:03:26 +03:00
|
|
|
#endif
|
2004-01-22 03:37:58 +03:00
|
|
|
|
2004-01-18 02:07:40 +03:00
|
|
|
#if defined(c_plusplus) || defined(__cplusplus)
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2004-03-17 22:03:26 +03:00
|
|
|
#endif /* MCA_BASE_H */
|