- Various updates
- Show modules for pml, ptl, pcm This commit was SVN r575.
Этот коммит содержится в:
родитель
5bdb66e693
Коммит
57205e4b05
@ -333,6 +333,9 @@ int main(int argc, char *argv[])
|
||||
laminfo::do_arch(cmd_line);
|
||||
laminfo::do_config(false);
|
||||
laminfo::open_modules();
|
||||
laminfo::show_module_version("pcm", module_all, ver_full, type_all);
|
||||
laminfo::show_module_version("pml", module_all, ver_full, type_all);
|
||||
laminfo::show_module_version("ptl", module_all, ver_full, type_all);
|
||||
#if 0
|
||||
laminfo::show_boot_version(mca_boot_modules, type_all, ver_full,
|
||||
ver_module);
|
||||
|
@ -44,6 +44,10 @@ namespace laminfo {
|
||||
|
||||
void do_version(bool want_all, lam_cmd_line_t *cmd_line);
|
||||
void show_lam_version(const std::string& scope);
|
||||
void show_module_version(const std::string& type_name,
|
||||
const std::string& module_name,
|
||||
const std::string& scope,
|
||||
const std::string& ver_type);
|
||||
|
||||
//
|
||||
// Parameter/configuration-related functions
|
||||
|
@ -12,6 +12,8 @@
|
||||
|
||||
#include "mca/lam/base/base.h"
|
||||
#include "mca/lam/pcm/pcm.h"
|
||||
#include "mca/mpi/pml/pml.h"
|
||||
#include "mca/mpi/ptl/ptl.h"
|
||||
#include "tools/laminfo/laminfo.h"
|
||||
|
||||
using namespace std;
|
||||
@ -70,50 +72,46 @@ void laminfo::open_modules()
|
||||
|
||||
#if 0
|
||||
// oob module opening not implemented yet
|
||||
mca_oob_open();
|
||||
module_map("oob") = mca_oob_base_module_list;
|
||||
mca_oob_base_open();
|
||||
module_map["oob"] = &mca_oob_base_modules_available;
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
// registry module opening not implemented yet
|
||||
mca_registry_open();
|
||||
module_map("registry") = mca_registry_base_module_list;
|
||||
mca_registry_base_open();
|
||||
module_map["registry"] = &mca_registry_base_modules_available;
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
// coll module opening not implemented yet
|
||||
mca_coll_open();
|
||||
module_map("coll") = mca_coll_base_module_list;
|
||||
mca_coll_base_open();
|
||||
module_map["coll"] = &mca_coll_base_modules_available;
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
// io module opening not implemented yet
|
||||
mca_io_open();
|
||||
module_map("io") = mca_io_base_module_list;
|
||||
mca_io_base_open();
|
||||
module_map["io"] = &mca_io_base_modules_available;
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
// one module opening not implemented yet
|
||||
mca_one_open();
|
||||
module_map("one") = mca_one_base_module_list;
|
||||
mca_one_base_open();
|
||||
module_map["one"] = &mca_one_base_modules_available;
|
||||
#endif
|
||||
|
||||
#if 0
|
||||
// pml module opening not implemented yet
|
||||
mca_pml_open();
|
||||
module_map("pml") = mca_pml_base_module_list;
|
||||
#endif
|
||||
mca_pml_base_open();
|
||||
module_map["pml"] = &mca_pml_base_modules_available;
|
||||
|
||||
#if 0
|
||||
// ptl module opening not implemented yet
|
||||
mca_ptl_open();
|
||||
module_map("ptl") = mca_ptl_base_module_list;
|
||||
#endif
|
||||
mca_ptl_base_open();
|
||||
module_map["ptl"] = &mca_ptl_base_modules_available;
|
||||
|
||||
#if 0
|
||||
// topo module opening not implemented yet
|
||||
mca_topo_open();
|
||||
module_map("topo") = mca_topo_base_module_list;
|
||||
mca_topo_base_open();
|
||||
module_map["topo"] = &mca_topo_base_modules_available;
|
||||
#endif
|
||||
|
||||
// All done
|
||||
@ -129,7 +127,9 @@ void laminfo::close_modules()
|
||||
#if 0
|
||||
mca_crmpi_base_close();
|
||||
mca_coll_base_close();
|
||||
#endif
|
||||
mca_pml_base_close();
|
||||
#if 0
|
||||
mca_boot_close();
|
||||
mca_base_close();
|
||||
#endif
|
||||
|
@ -4,10 +4,12 @@
|
||||
|
||||
#include "lam_config.h"
|
||||
|
||||
#include <iostream>
|
||||
#include <string>
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include "mca/lam/base/base.h"
|
||||
#include "tools/laminfo/laminfo.h"
|
||||
|
||||
using namespace std;
|
||||
@ -40,9 +42,6 @@ static const string ver_module = "module";
|
||||
// Private functions
|
||||
//
|
||||
|
||||
static void show_module_version(const string& type_name,
|
||||
const string& module_name,
|
||||
const string& scope, const string& ver_type);
|
||||
static void show_mca_version(const mca_base_module_t *module,
|
||||
const string& scope, const string& ver_type);
|
||||
static string make_version_str(const string& scope,
|
||||
@ -119,15 +118,16 @@ void laminfo::show_lam_version(const string& scope)
|
||||
// Show all the modules of a specific type/module combo (module may be
|
||||
// a wildcard)
|
||||
//
|
||||
static void show_module_version(const string& type_name,
|
||||
const string& module_name,
|
||||
const string& scope, const string& ver_type)
|
||||
void laminfo::show_module_version(const string& type_name,
|
||||
const string& module_name,
|
||||
const string& scope, const string& ver_type)
|
||||
{
|
||||
laminfo::type_list_t::size_type i;
|
||||
bool want_all_modules = (type_all == module_name);
|
||||
bool found;
|
||||
lam_list_item *item;
|
||||
mca_base_module_t *module;
|
||||
mca_base_module_list_item_t *mli;
|
||||
const mca_base_module_t *module;
|
||||
lam_list_t *modules;
|
||||
|
||||
// Check to see if the type is valid
|
||||
@ -150,9 +150,10 @@ static void show_module_version(const string& type_name,
|
||||
|
||||
modules = module_map[type_name];
|
||||
for (item = lam_list_get_first(modules);
|
||||
lam_list_get_last(modules) != item;
|
||||
item = (lam_list_item *) lam_list_get_next(item)) {
|
||||
module = (mca_base_module_t *) item;
|
||||
lam_list_get_end(modules) != item;
|
||||
item = lam_list_get_next(item)) {
|
||||
mli = (mca_base_module_list_item_t *) item;
|
||||
module = mli->mli_module;
|
||||
if (want_all_modules || module->mca_module_name == module_name) {
|
||||
show_mca_version(module, scope, ver_type);
|
||||
}
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user