root/ompi/mca/fbtl/ime/fbtl_ime_component.c

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

DEFINITIONS

This source file includes following definitions.
  1. register_component

   1 /* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil -*- */
   2 /*
   3  * Copyright (c) 2018      DataDirect Networks. All rights reserved.
   4  * $COPYRIGHT$
   5  *
   6  * Additional copyrights may follow
   7  *
   8  * $HEADER$
   9  */
  10 
  11 #include "ompi_config.h"
  12 #include "fbtl_ime.h"
  13 #include "mpi.h"
  14 
  15 int mca_fbtl_ime_priority = FBTL_IME_BASE_PRIORITY;
  16 int mca_fbtl_ime_iov_max = FBTL_IME_IOV_MAX;
  17 int mca_fbtl_ime_aio_reqs_max = FBTL_IME_AIO_REQS_MAX;
  18 
  19 /*
  20  * Private functions
  21  */
  22 static int register_component(void);
  23 
  24 /*
  25  * Public string showing the fbtl ime component version number
  26  */
  27 const char *mca_fbtl_ime_component_version_string =
  28   "OMPI/MPI IME FBTL MCA component version " OMPI_VERSION;
  29 
  30 
  31 /*
  32  * Instantiate the public struct with all of our public information
  33  * and pointers to our public functions in it
  34  */
  35 mca_fbtl_base_component_2_0_0_t mca_fbtl_ime_component = {
  36 
  37     /* First, the mca_component_t struct containing meta information
  38        about the component itself */
  39 
  40     .fbtlm_version = {
  41         MCA_FBTL_BASE_VERSION_2_0_0,
  42 
  43         /* Component name and version */
  44         .mca_component_name = "ime",
  45         MCA_BASE_MAKE_VERSION(component, OMPI_MAJOR_VERSION, OMPI_MINOR_VERSION,
  46                               OMPI_RELEASE_VERSION),
  47         .mca_register_component_params = register_component,
  48     },
  49     .fbtlm_data = {
  50         /* This component is checkpointable */
  51       MCA_BASE_METADATA_PARAM_CHECKPOINT
  52     },
  53     .fbtlm_init_query = mca_fbtl_ime_component_init_query,      /* get thread level */
  54     .fbtlm_file_query = mca_fbtl_ime_component_file_query,      /* get priority and actions */
  55     .fbtlm_file_unquery = mca_fbtl_ime_component_file_unquery,  /* undo what was done by previous function */
  56 };
  57 
  58 static int register_component(void)
  59 {
  60     mca_fbtl_ime_iov_max = FBTL_IME_IOV_MAX;
  61     (void) mca_base_component_var_register(&mca_fbtl_ime_component.fbtlm_version,
  62                                            "iov_max", "Maximum iov count that should be used when "
  63                                            "calling an IME native function",
  64                                            MCA_BASE_VAR_TYPE_INT, NULL, 0, 0,
  65                                            OPAL_INFO_LVL_9,
  66                                            MCA_BASE_VAR_SCOPE_READONLY,
  67                                            &mca_fbtl_ime_iov_max);
  68 
  69     mca_fbtl_ime_aio_reqs_max = FBTL_IME_AIO_REQS_MAX;
  70     (void) mca_base_component_var_register(&mca_fbtl_ime_component.fbtlm_version,
  71                                            "aio_reqs_max", "Maximum number of aiocb requests that should "
  72                                            "be sent simultaneously when calling an IME native function",
  73                                            MCA_BASE_VAR_TYPE_INT, NULL, 0, 0,
  74                                            OPAL_INFO_LVL_9,
  75                                            MCA_BASE_VAR_SCOPE_READONLY,
  76                                            &mca_fbtl_ime_aio_reqs_max );
  77 
  78     return OMPI_SUCCESS;
  79 }

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