2004-01-12 00:26:55 +03:00
|
|
|
/*
|
2005-11-05 22:57:48 +03:00
|
|
|
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
|
|
|
* University Research and Technology
|
|
|
|
* Corporation. All rights reserved.
|
|
|
|
* Copyright (c) 2004-2005 The University of Tennessee and The University
|
|
|
|
* of Tennessee Research Foundation. 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-12 00:26:55 +03:00
|
|
|
* $HEADER$
|
|
|
|
*
|
|
|
|
* These symbols are in a file by themselves to provide nice linker
|
|
|
|
* semantics. Since linkers generally pull in symbols by object
|
|
|
|
* files, keeping these symbols as the only symbols in this file
|
2004-06-07 19:33:53 +04:00
|
|
|
* prevents utility programs such as "ompi_info" from having to import
|
2004-08-02 04:24:22 +04:00
|
|
|
* entire components just to query their version and parameters.
|
2004-01-12 00:26:55 +03:00
|
|
|
*/
|
|
|
|
|
2004-06-07 19:33:53 +04:00
|
|
|
#include "ompi_config.h"
|
2004-02-15 00:26:30 +03:00
|
|
|
#include "coll_basic.h"
|
2004-01-12 00:26:55 +03:00
|
|
|
|
|
|
|
#include "mpi.h"
|
2006-02-12 04:33:29 +03:00
|
|
|
#include "ompi/mca/coll/coll.h"
|
2004-01-12 00:26:55 +03:00
|
|
|
#include "coll_basic.h"
|
|
|
|
|
|
|
|
/*
|
2004-08-02 04:24:22 +04:00
|
|
|
* Public string showing the coll ompi_basic component version number
|
2004-01-12 00:26:55 +03:00
|
|
|
*/
|
2004-08-02 04:24:22 +04:00
|
|
|
const char *mca_coll_basic_component_version_string =
|
2005-08-10 14:51:42 +04:00
|
|
|
"Open MPI basic collective MCA component version " OMPI_VERSION;
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2004-10-12 16:38:56 +04:00
|
|
|
/*
|
2005-10-04 01:07:42 +04:00
|
|
|
* Global variables
|
2004-10-12 16:38:56 +04:00
|
|
|
*/
|
2005-10-04 01:07:42 +04:00
|
|
|
int mca_coll_basic_priority = 10;
|
|
|
|
int mca_coll_basic_crossover = 4;
|
2004-10-12 16:38:56 +04:00
|
|
|
|
|
|
|
/*
|
|
|
|
* Local function
|
|
|
|
*/
|
|
|
|
static int basic_open(void);
|
|
|
|
|
2004-01-12 00:26:55 +03:00
|
|
|
/*
|
|
|
|
* Instantiate the public struct with all of our public information
|
|
|
|
* and pointers to our public functions in it
|
|
|
|
*/
|
|
|
|
|
2004-08-02 04:24:22 +04:00
|
|
|
const mca_coll_base_component_1_0_0_t mca_coll_basic_component = {
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
/* First, the mca_component_t struct containing meta information
|
|
|
|
* about the component itself */
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
{
|
|
|
|
/* Indicate that we are a coll v1.0.0 component (which also implies a
|
|
|
|
* specific MCA version) */
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
MCA_COLL_BASE_VERSION_1_0_0,
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
/* Component name and version */
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
"basic",
|
|
|
|
OMPI_MAJOR_VERSION,
|
|
|
|
OMPI_MINOR_VERSION,
|
|
|
|
OMPI_RELEASE_VERSION,
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
/* Component open and close functions */
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
basic_open,
|
2005-10-04 01:07:42 +04:00
|
|
|
NULL
|
|
|
|
},
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
/* Next the MCA v1.0.0 component meta data */
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
{
|
|
|
|
/* Whether the component is checkpointable or not */
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-10-04 01:07:42 +04:00
|
|
|
true
|
|
|
|
},
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
/* Initialization / querying functions */
|
2004-01-12 00:26:55 +03:00
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
mca_coll_basic_init_query,
|
|
|
|
mca_coll_basic_comm_query,
|
|
|
|
NULL
|
2004-01-12 00:26:55 +03:00
|
|
|
};
|
2004-10-12 16:38:56 +04:00
|
|
|
|
|
|
|
|
2005-08-10 14:51:42 +04:00
|
|
|
static int
|
|
|
|
basic_open(void)
|
2004-10-12 16:38:56 +04:00
|
|
|
{
|
|
|
|
/* Use a low priority, but allow other components to be lower */
|
2005-08-10 14:51:42 +04:00
|
|
|
|
2005-10-04 01:07:42 +04:00
|
|
|
mca_base_param_reg_int(&mca_coll_basic_component.collm_version,
|
|
|
|
"priority",
|
|
|
|
"Priority of the basic coll component",
|
|
|
|
false, false, mca_coll_basic_priority,
|
|
|
|
&mca_coll_basic_priority);
|
|
|
|
mca_base_param_reg_int(&mca_coll_basic_component.collm_version,
|
|
|
|
"crossover",
|
|
|
|
"Minimum number of processes in a communicator before using the logarithmic algorithms",
|
|
|
|
false, false, mca_coll_basic_crossover,
|
|
|
|
&mca_coll_basic_crossover);
|
2004-10-12 16:38:56 +04:00
|
|
|
|
|
|
|
return OMPI_SUCCESS;
|
|
|
|
}
|