root/ompi/mca/coll/inter/coll_inter_component.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. inter_register
  2. mca_coll_inter_module_construct
  3. mca_coll_inter_module_destruct

   1 /* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil -*- */
   2 /*
   3  * Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
   4  *                         University Research and Technology
   5  *                         Corporation.  All rights reserved.
   6  * Copyright (c) 2004-2005 The University of Tennessee and The University
   7  *                         of Tennessee Research Foundation.  All rights
   8  *                         reserved.
   9  * Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
  10  *                         University of Stuttgart.  All rights reserved.
  11  * Copyright (c) 2004-2005 The Regents of the University of California.
  12  *                         All rights reserved.
  13  * Copyright (c) 2006-2007 University of Houston. All rights reserved.
  14  * Copyright (c) 2008      Cisco Systems, Inc.  All rights reserved.
  15  * Copyright (c) 2015      Los Alamos National Security, LLC. All rights
  16  *                         reserved.
  17  * $COPYRIGHT$
  18  *
  19  * Additional copyrights may follow
  20  *
  21  * $HEADER$
  22  *
  23  * These symbols are in a file by themselves to provide nice linker
  24  * semantics.  Since linkers generally pull in symbols by object
  25  * files, keeping these symbols as the only symbols in this file
  26  * prevents utility programs such as "ompi_info" from having to import
  27  * entire components just to query their version and parameters.
  28  */
  29 
  30 #include "ompi_config.h"
  31 #include "coll_inter.h"
  32 
  33 #include "mpi.h"
  34 #include "ompi/mca/coll/coll.h"
  35 
  36 /*
  37  * Public string showing the coll ompi_inter component version number
  38  */
  39 const char *mca_coll_inter_component_version_string =
  40   "OMPI/MPI inter collective MCA component version " OMPI_VERSION;
  41 
  42 /*
  43  * Global variable
  44  */
  45 int mca_coll_inter_priority_param = 40;
  46 int mca_coll_inter_verbose_param = 0;
  47 
  48 
  49 /*
  50  * Local function
  51  */
  52 static int inter_register(void);
  53 
  54 /*
  55  * Instantiate the public struct with all of our public information
  56  * and pointers to our public functions in it
  57  */
  58 
  59 const mca_coll_base_component_2_0_0_t mca_coll_inter_component = {
  60 
  61     /* First, the mca_component_t struct containing meta information
  62        about the component itself */
  63 
  64     .collm_version = {
  65         MCA_COLL_BASE_VERSION_2_0_0,
  66 
  67         /* Component name and version */
  68         .mca_component_name = "inter",
  69         MCA_BASE_MAKE_VERSION(component, OMPI_MAJOR_VERSION, OMPI_MINOR_VERSION,
  70                               OMPI_RELEASE_VERSION),
  71 
  72         /* Component open and close functions */
  73         .mca_register_component_params = inter_register,
  74     },
  75     .collm_data = {
  76         /* This component is checkpointable */
  77         MCA_BASE_METADATA_PARAM_CHECKPOINT
  78     },
  79 
  80     /* Initialization / querying functions */
  81     .collm_init_query = mca_coll_inter_init_query,
  82     .collm_comm_query = mca_coll_inter_comm_query,
  83 };
  84 
  85 
  86 static int inter_register(void)
  87 {
  88     /* Use a high priority, but allow other components to be higher */
  89     mca_coll_inter_priority_param = 40;
  90     (void) mca_base_component_var_register(&mca_coll_inter_component.collm_version,
  91                                            "priority", "Priority of the inter coll component",
  92                                            MCA_BASE_VAR_TYPE_INT, NULL, 0, 0,
  93                                            OPAL_INFO_LVL_9,
  94                                            MCA_BASE_VAR_SCOPE_READONLY,
  95                                            &mca_coll_inter_priority_param);
  96 
  97     mca_coll_inter_verbose_param = 0;
  98     (void) mca_base_component_var_register(&mca_coll_inter_component.collm_version,
  99                                            "verbose",
 100                                            "Turn verbose message of the inter coll component on/off",
 101                                            MCA_BASE_VAR_TYPE_INT, NULL, 0, 0,
 102                                            OPAL_INFO_LVL_9,
 103                                            MCA_BASE_VAR_SCOPE_READONLY,
 104                                            &mca_coll_inter_verbose_param);
 105 
 106     return OMPI_SUCCESS;
 107 }
 108 
 109 
 110 static void
 111 mca_coll_inter_module_construct(mca_coll_inter_module_t *module)
 112 {
 113     module->inter_comm = NULL;
 114 }
 115 
 116 static void
 117 mca_coll_inter_module_destruct(mca_coll_inter_module_t *module)
 118 {
 119 
 120 }
 121 
 122 
 123 OBJ_CLASS_INSTANCE(mca_coll_inter_module_t,
 124                    mca_coll_base_module_t,
 125                    mca_coll_inter_module_construct,
 126                    mca_coll_inter_module_destruct);

/* [<][>][^][v][top][bottom][index][help] */