Remove the filter framework - the xml support will have to be provided in a different manner that will be implemented shortly
This commit was SVN r18572.
Этот коммит содержится в:
родитель
c73ed2b256
Коммит
9927b2445c
@ -53,8 +53,6 @@
|
|||||||
#endif
|
#endif
|
||||||
#include "opal/runtime/opal.h"
|
#include "opal/runtime/opal.h"
|
||||||
#include "opal/dss/dss.h"
|
#include "opal/dss/dss.h"
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
#include "opal/mca/filter/base/base.h"
|
|
||||||
|
|
||||||
#include "ompi/mca/allocator/allocator.h"
|
#include "ompi/mca/allocator/allocator.h"
|
||||||
#include "ompi/mca/allocator/base/base.h"
|
#include "ompi/mca/allocator/base/base.h"
|
||||||
@ -203,9 +201,6 @@ void ompi_info::open_components()
|
|||||||
|
|
||||||
// OPAL frameworks
|
// OPAL frameworks
|
||||||
|
|
||||||
opal_filter_base_open();
|
|
||||||
component_map["filter"] = &opal_filter_base_components_available;
|
|
||||||
|
|
||||||
opal_backtrace_base_open();
|
opal_backtrace_base_open();
|
||||||
component_map["backtrace"] = &opal_backtrace_base_components_opened;
|
component_map["backtrace"] = &opal_backtrace_base_components_opened;
|
||||||
|
|
||||||
|
@ -1,41 +0,0 @@
|
|||||||
#
|
|
||||||
# Copyright (c) 2004-2007 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.
|
|
||||||
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
# University of Stuttgart. All rights reserved.
|
|
||||||
# Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
# All rights reserved.
|
|
||||||
# $COPYRIGHT$
|
|
||||||
#
|
|
||||||
# Additional copyrights may follow
|
|
||||||
#
|
|
||||||
# $HEADER$
|
|
||||||
#
|
|
||||||
|
|
||||||
# main library setup
|
|
||||||
noinst_LTLIBRARIES = libmca_filter.la
|
|
||||||
libmca_filter_la_SOURCES =
|
|
||||||
|
|
||||||
# header setup
|
|
||||||
nobase_opal_HEADERS =
|
|
||||||
|
|
||||||
# local files
|
|
||||||
headers = filter.h
|
|
||||||
libmca_filter_la_SOURCES += $(headers)
|
|
||||||
|
|
||||||
# Conditionally install the header files
|
|
||||||
if WANT_INSTALL_HEADERS
|
|
||||||
nobase_opal_HEADERS += $(headers)
|
|
||||||
opaldir = $(includedir)/openmpi/opal/mca/filter
|
|
||||||
else
|
|
||||||
opaldir = $(includedir)
|
|
||||||
endif
|
|
||||||
|
|
||||||
include base/Makefile.am
|
|
||||||
|
|
||||||
distclean-local:
|
|
||||||
rm -f base/static-components.h
|
|
@ -1,27 +0,0 @@
|
|||||||
#
|
|
||||||
# Copyright (c) 2004-2007 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.
|
|
||||||
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
# University of Stuttgart. All rights reserved.
|
|
||||||
# Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
# All rights reserved.
|
|
||||||
# $COPYRIGHT$
|
|
||||||
#
|
|
||||||
# Additional copyrights may follow
|
|
||||||
#
|
|
||||||
# $HEADER$
|
|
||||||
#
|
|
||||||
|
|
||||||
headers += \
|
|
||||||
base/base.h
|
|
||||||
|
|
||||||
libmca_filter_la_SOURCES += \
|
|
||||||
base/filter_base_open.c \
|
|
||||||
base/filter_base_close.c \
|
|
||||||
base/filter_base_select.c \
|
|
||||||
base/filter_base_fns.c
|
|
||||||
|
|
@ -1,76 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2008 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.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2007 Evergrid, Inc. All rights reserved.
|
|
||||||
* Copyright (c) 2008 Cisco Systems, Inc. All rights reserved.
|
|
||||||
*
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
#ifndef OPAL_FILTER_BASE_H
|
|
||||||
#define OPAL_FILTER_BASE_H
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
|
|
||||||
#include "opal/class/opal_list.h"
|
|
||||||
|
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Global functions for MCA overall CRS
|
|
||||||
*/
|
|
||||||
|
|
||||||
BEGIN_C_DECLS
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Initialize the FILTER MCA framework
|
|
||||||
*
|
|
||||||
* @retval OPAL_SUCCESS Upon success
|
|
||||||
* @retval OPAL_ERROR Upon failures
|
|
||||||
*
|
|
||||||
* This function is invoked during opal_init();
|
|
||||||
*/
|
|
||||||
OPAL_DECLSPEC int opal_filter_base_open(void);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Select an available component.
|
|
||||||
*
|
|
||||||
* @retval OPAL_SUCCESS Upon Success
|
|
||||||
* @retval OPAL_NOT_FOUND If no component can be selected
|
|
||||||
* @retval OPAL_ERROR Upon other failure
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
OPAL_DECLSPEC int opal_filter_base_select(void);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Finalize the FILTER MCA framework
|
|
||||||
*
|
|
||||||
* @retval OPAL_SUCCESS Upon success
|
|
||||||
* @retval OPAL_ERROR Upon failures
|
|
||||||
*
|
|
||||||
* This function is invoked during opal_finalize();
|
|
||||||
*/
|
|
||||||
OPAL_DECLSPEC int opal_filter_base_close(void);
|
|
||||||
|
|
||||||
|
|
||||||
/**** No-op base functions ****/
|
|
||||||
OPAL_DECLSPEC char* opal_filter_base_process(char *str, int major_id, int minor_id, int num_tags, char **tags);
|
|
||||||
|
|
||||||
OPAL_DECLSPEC extern int opal_filter_base_output;
|
|
||||||
OPAL_DECLSPEC extern opal_list_t opal_filter_base_components_available;
|
|
||||||
OPAL_DECLSPEC extern opal_filter_base_component_t opal_filter_base_selected_component;
|
|
||||||
|
|
||||||
END_C_DECLS
|
|
||||||
|
|
||||||
#endif /* OPAL_FILTER_BASE_H */
|
|
@ -1,38 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2007 The Trustees of Indiana University.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Trustees of the University of Tennessee.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
|
|
||||||
#include "opal/mca/mca.h"
|
|
||||||
#include "opal/mca/base/base.h"
|
|
||||||
#include "opal/include/opal/constants.h"
|
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
#include "opal/mca/filter/base/base.h"
|
|
||||||
|
|
||||||
int opal_filter_base_close(void)
|
|
||||||
{
|
|
||||||
/* Call the component's finalize routine */
|
|
||||||
if( NULL != opal_filter.finalize ) {
|
|
||||||
opal_filter.finalize();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Close all available modules that are open */
|
|
||||||
mca_base_components_close(opal_filter_base_output,
|
|
||||||
&opal_filter_base_components_available,
|
|
||||||
NULL);
|
|
||||||
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
@ -1,28 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2008 The Trustees of Indiana University.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Trustees of the University of Tennessee.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2007 Evergrid, Inc. All rights reserved.
|
|
||||||
*
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
#include "opal/include/opal/constants.h"
|
|
||||||
|
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
#include "opal/mca/filter/base/base.h"
|
|
||||||
|
|
||||||
char* opal_filter_base_process(char *str, int major_id, int minor_id, int num_tags, char **tags)
|
|
||||||
{
|
|
||||||
return NULL;
|
|
||||||
}
|
|
@ -1,63 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2007 The Trustees of Indiana University.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Trustees of the University of Tennessee.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2007 Evergrid, Inc. All rights reserved.
|
|
||||||
*
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
|
|
||||||
#include "opal/mca/mca.h"
|
|
||||||
#include "opal/mca/base/base.h"
|
|
||||||
#include "opal/include/opal/constants.h"
|
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
#include "opal/mca/filter/base/base.h"
|
|
||||||
#include "opal/util/output.h"
|
|
||||||
|
|
||||||
#include "opal/mca/filter/base/static-components.h"
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Globals
|
|
||||||
*/
|
|
||||||
int opal_filter_base_output;
|
|
||||||
opal_filter_base_module_t opal_filter = {
|
|
||||||
NULL,
|
|
||||||
NULL,
|
|
||||||
opal_filter_base_process
|
|
||||||
};
|
|
||||||
|
|
||||||
opal_list_t opal_filter_base_components_available;
|
|
||||||
opal_filter_base_component_t opal_filter_base_selected_component;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Function for finding and opening either all MCA components,
|
|
||||||
* or the one that was specifically requested via a MCA parameter.
|
|
||||||
*/
|
|
||||||
int opal_filter_base_open(void)
|
|
||||||
{
|
|
||||||
opal_filter_base_output = opal_output_open(NULL);
|
|
||||||
|
|
||||||
/* Open up all available components */
|
|
||||||
if (OPAL_SUCCESS !=
|
|
||||||
mca_base_components_open("filter",
|
|
||||||
opal_filter_base_output,
|
|
||||||
mca_filter_base_static_components,
|
|
||||||
&opal_filter_base_components_available,
|
|
||||||
true)) {
|
|
||||||
return OPAL_ERROR;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
@ -1,63 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2008 The Trustees of Indiana University.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Trustees of the University of Tennessee.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2007 Evergrid, Inc. All rights reserved.
|
|
||||||
*
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
|
|
||||||
#ifdef HAVE_UNISTD_H
|
|
||||||
#include "unistd.h"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "opal/include/opal/constants.h"
|
|
||||||
#include "opal/util/output.h"
|
|
||||||
#include "opal/mca/mca.h"
|
|
||||||
#include "opal/mca/base/base.h"
|
|
||||||
#include "opal/mca/base/mca_base_param.h"
|
|
||||||
|
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
#include "opal/mca/filter/base/base.h"
|
|
||||||
|
|
||||||
int opal_filter_base_select(void)
|
|
||||||
{
|
|
||||||
int exit_status = OPAL_SUCCESS;
|
|
||||||
opal_filter_base_component_t *best_component = NULL;
|
|
||||||
opal_filter_base_module_t *best_module = NULL;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Select the best component - it is okay if there are NO
|
|
||||||
* components in this framework!
|
|
||||||
*/
|
|
||||||
if( OPAL_SUCCESS == mca_base_select("filter", opal_filter_base_output,
|
|
||||||
&opal_filter_base_components_available,
|
|
||||||
(mca_base_module_t **) &best_module,
|
|
||||||
(mca_base_component_t **) &best_component)) {
|
|
||||||
/* Save the winner - otherwise, we will just use the
|
|
||||||
* default module defined in opal_filter_base_open
|
|
||||||
*/
|
|
||||||
opal_filter_base_selected_component = *best_component;
|
|
||||||
opal_filter = *best_module;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Initialize the module */
|
|
||||||
if (NULL != opal_filter.init) {
|
|
||||||
if (OPAL_SUCCESS != opal_filter.init()) {
|
|
||||||
exit_status = OPAL_ERROR;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return exit_status;
|
|
||||||
}
|
|
@ -1,100 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2008 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.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* Copyright (c) 2007 Evergrid, Inc. All rights reserved.
|
|
||||||
*
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
/**
|
|
||||||
* @file
|
|
||||||
*
|
|
||||||
* Filter output to format it for specific purposes
|
|
||||||
* such as XML or just do a no-op!
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef MCA_FILTER_H
|
|
||||||
#define MCA_FILTER_H
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
#include "opal/mca/mca.h"
|
|
||||||
#include "opal/mca/base/base.h"
|
|
||||||
#include "opal/class/opal_object.h"
|
|
||||||
|
|
||||||
BEGIN_C_DECLS
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Module initialization function.
|
|
||||||
* Returns OPAL_SUCCESS
|
|
||||||
*/
|
|
||||||
typedef int (*opal_filter_base_module_init_fn_t)(void);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Module finalization function.
|
|
||||||
* Returns OPAL_SUCCESS
|
|
||||||
*/
|
|
||||||
typedef int (*opal_filter_base_module_finalize_fn_t)(void);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Process a string through the selected filter - returns
|
|
||||||
* filtered string that can be free'd by caller, or returns
|
|
||||||
* NULL if no filtering was done
|
|
||||||
*/
|
|
||||||
typedef char* (*opal_filter_base_module_process_fn_t)(char *str, int major_id, int minor_id, int num_tags, char **tags);
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Structure for FILTER v1.0.0 components.
|
|
||||||
*/
|
|
||||||
struct opal_filter_base_component_1_0_0_t {
|
|
||||||
/** MCA base component */
|
|
||||||
mca_base_component_t base_version;
|
|
||||||
/** MCA base data */
|
|
||||||
mca_base_component_data_1_0_0_t base_data;
|
|
||||||
};
|
|
||||||
typedef struct opal_filter_base_component_1_0_0_t opal_filter_base_component_1_0_0_t;
|
|
||||||
typedef struct opal_filter_base_component_1_0_0_t opal_filter_base_component_t;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Structure for FILTER v1.0.0 modules
|
|
||||||
*/
|
|
||||||
struct opal_filter_base_module_1_0_0_t {
|
|
||||||
/** Initialization Function */
|
|
||||||
opal_filter_base_module_init_fn_t init;
|
|
||||||
/** Finalization Function */
|
|
||||||
opal_filter_base_module_finalize_fn_t finalize;
|
|
||||||
|
|
||||||
/** Filter processing interface */
|
|
||||||
opal_filter_base_module_process_fn_t process;
|
|
||||||
|
|
||||||
};
|
|
||||||
typedef struct opal_filter_base_module_1_0_0_t opal_filter_base_module_1_0_0_t;
|
|
||||||
typedef struct opal_filter_base_module_1_0_0_t opal_filter_base_module_t;
|
|
||||||
|
|
||||||
OPAL_DECLSPEC extern opal_filter_base_module_t opal_filter;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Macro for use in components that are of type FILTER v1.0.0
|
|
||||||
*/
|
|
||||||
#define OPAL_FILTER_BASE_VERSION_1_0_0 \
|
|
||||||
/* FILTER v1.0 is chained to MCA v1.0 */ \
|
|
||||||
MCA_BASE_VERSION_1_0_0, \
|
|
||||||
/* FILTER v1.0 */ \
|
|
||||||
"filter", 1, 0, 0
|
|
||||||
|
|
||||||
END_C_DECLS
|
|
||||||
|
|
||||||
#endif /* OPAL_FILTER_H */
|
|
||||||
|
|
@ -1,47 +0,0 @@
|
|||||||
#
|
|
||||||
# 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.
|
|
||||||
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
# University of Stuttgart. All rights reserved.
|
|
||||||
# Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
# All rights reserved.
|
|
||||||
# $COPYRIGHT$
|
|
||||||
#
|
|
||||||
# Additional copyrights may follow
|
|
||||||
#
|
|
||||||
# $HEADER$
|
|
||||||
#
|
|
||||||
|
|
||||||
AM_CPPFLAGS = $(filter_xml_CPPFLAGS)
|
|
||||||
|
|
||||||
sources = \
|
|
||||||
filter_xml.h \
|
|
||||||
filter_xml_component.c \
|
|
||||||
filter_xml_module.c
|
|
||||||
|
|
||||||
# Make the output library in this directory, and name it either
|
|
||||||
# mca_<type>_<name>.la (for DSO builds) or libmca_<type>_<name>.la
|
|
||||||
# (for static builds).
|
|
||||||
|
|
||||||
if OMPI_BUILD_filter_xml_DSO
|
|
||||||
component_noinst =
|
|
||||||
component_install = mca_filter_xml.la
|
|
||||||
else
|
|
||||||
component_noinst = libmca_filter_xml.la
|
|
||||||
component_install =
|
|
||||||
endif
|
|
||||||
|
|
||||||
mcacomponentdir = $(pkglibdir)
|
|
||||||
mcacomponent_LTLIBRARIES = $(component_install)
|
|
||||||
mca_filter_xml_la_SOURCES = $(sources)
|
|
||||||
mca_filter_xml_la_LDFLAGS = -module -avoid-version $(filter_xml_LDFLAGS)
|
|
||||||
mca_filter_xml_la_LIBADD = $(filter_xml_LIBS)
|
|
||||||
|
|
||||||
noinst_LTLIBRARIES = $(component_noinst)
|
|
||||||
libmca_filter_xml_la_SOURCES =$(sources)
|
|
||||||
libmca_filter_xml_la_LIBADD = $(filter_xml_LIBS)
|
|
||||||
libmca_filter_xml_la_LDFLAGS = -module -avoid-version $(filter_xml_LDFLAGS)
|
|
@ -1,22 +0,0 @@
|
|||||||
# -*- shell-script -*-
|
|
||||||
#
|
|
||||||
# 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.
|
|
||||||
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
# University of Stuttgart. All rights reserved.
|
|
||||||
# Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
# All rights reserved.
|
|
||||||
# Copyright (c) 2007 Los Alamos National Security, LLC. All rights
|
|
||||||
# reserved.
|
|
||||||
# $COPYRIGHT$
|
|
||||||
#
|
|
||||||
# Additional copyrights may follow
|
|
||||||
#
|
|
||||||
# $HEADER$
|
|
||||||
#
|
|
||||||
|
|
||||||
PARAM_CONFIG_FILES="Makefile"
|
|
@ -1,46 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2008 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.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @file
|
|
||||||
*
|
|
||||||
* Processor affinity for libnuma.
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
#ifndef MCA_FILTER_XML_H
|
|
||||||
#define MCA_FILTER_XML_H
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
|
|
||||||
#include "opal/mca/mca.h"
|
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
|
|
||||||
|
|
||||||
BEGIN_C_DECLS
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Globally exported variable
|
|
||||||
*/
|
|
||||||
OPAL_DECLSPEC extern const opal_filter_base_component_t mca_filter_xml_component;
|
|
||||||
|
|
||||||
OPAL_DECLSPEC extern opal_filter_base_module_t opal_filter_xml_module;
|
|
||||||
|
|
||||||
END_C_DECLS
|
|
||||||
|
|
||||||
#endif /* MCA_FILTER_XML_H */
|
|
@ -1,116 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2008 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.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
|
|
||||||
#include "opal/constants.h"
|
|
||||||
|
|
||||||
#include "opal/mca/base/mca_base_param.h"
|
|
||||||
|
|
||||||
#include "opal/mca/filter/filter.h"
|
|
||||||
#include "filter_xml.h"
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Public string showing the filter ompi_filter component version number
|
|
||||||
*/
|
|
||||||
const char *opal_filter_xml_component_version_string =
|
|
||||||
"OPAL filter xml MCA component version " OPAL_VERSION;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Local function
|
|
||||||
*/
|
|
||||||
static int xml_open(void);
|
|
||||||
static int xml_component_query(mca_base_module_t **module, int *priority);
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Instantiate the public struct with all of our public information
|
|
||||||
* and pointers to our public functions in it
|
|
||||||
*/
|
|
||||||
|
|
||||||
const opal_filter_base_component_t mca_filter_xml_component = {
|
|
||||||
|
|
||||||
/* First, the mca_component_t struct containing meta information
|
|
||||||
about the component itself */
|
|
||||||
|
|
||||||
{
|
|
||||||
/* Indicate that we are a filter v1.0.0 component (which also
|
|
||||||
implies a specific MCA version) */
|
|
||||||
|
|
||||||
OPAL_FILTER_BASE_VERSION_1_0_0,
|
|
||||||
|
|
||||||
/* Component name and version */
|
|
||||||
|
|
||||||
"xml",
|
|
||||||
OPAL_MAJOR_VERSION,
|
|
||||||
OPAL_MINOR_VERSION,
|
|
||||||
OPAL_RELEASE_VERSION,
|
|
||||||
|
|
||||||
/* Component open and close functions */
|
|
||||||
|
|
||||||
xml_open,
|
|
||||||
NULL,
|
|
||||||
xml_component_query
|
|
||||||
},
|
|
||||||
|
|
||||||
/* Next the MCA v1.0.0 component meta data */
|
|
||||||
|
|
||||||
{
|
|
||||||
/* The component is checkpoint ready */
|
|
||||||
MCA_BASE_METADATA_PARAM_CHECKPOINT
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
static int xml_open(void)
|
|
||||||
{
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
int xml_component_query(mca_base_module_t **module, int *priority)
|
|
||||||
{
|
|
||||||
int index;
|
|
||||||
char *param;
|
|
||||||
|
|
||||||
/* we can't currently handle this framework correctly, so we have
|
|
||||||
* to "hack" this to ensure this component is only selected
|
|
||||||
* when the user specifically requests it
|
|
||||||
*/
|
|
||||||
|
|
||||||
index = mca_base_param_find("filter", NULL, NULL);
|
|
||||||
if (0 > index) {
|
|
||||||
/* wasn't specified - we can't be selected */
|
|
||||||
*module = NULL;
|
|
||||||
*priority = -1;
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* see if it was us */
|
|
||||||
mca_base_param_lookup_string(index, ¶m);
|
|
||||||
if (NULL == param || 0 != strcmp(param, "xml")) {
|
|
||||||
/* not us */
|
|
||||||
*module = NULL;
|
|
||||||
*priority = -1;
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* was us! */
|
|
||||||
*priority = 100; /* only selectable upon demand */
|
|
||||||
*module = (mca_base_module_t *)&opal_filter_xml_module;
|
|
||||||
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
@ -1,99 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2004-2008 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.
|
|
||||||
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
||||||
* University of Stuttgart. All rights reserved.
|
|
||||||
* Copyright (c) 2004-2005 The Regents of the University of California.
|
|
||||||
* All rights reserved.
|
|
||||||
* $COPYRIGHT$
|
|
||||||
*
|
|
||||||
* Additional copyrights may follow
|
|
||||||
*
|
|
||||||
* $HEADER$
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "opal_config.h"
|
|
||||||
|
|
||||||
#include <stdio.h>
|
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
#include "opal/constants.h"
|
|
||||||
|
|
||||||
#include "opal/util/printf.h"
|
|
||||||
|
|
||||||
#include "filter_xml.h"
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Local functions
|
|
||||||
*/
|
|
||||||
static int xml_init(void);
|
|
||||||
static int xml_finalize(void);
|
|
||||||
static char* xml_process(char *str, int major_id, int minor_id, int num_tags, char **tags);
|
|
||||||
|
|
||||||
/*
|
|
||||||
* module
|
|
||||||
*/
|
|
||||||
opal_filter_base_module_t opal_filter_xml_module = {
|
|
||||||
/* Initialization function */
|
|
||||||
xml_init,
|
|
||||||
/* Finalize function */
|
|
||||||
xml_finalize,
|
|
||||||
/* Process function */
|
|
||||||
xml_process
|
|
||||||
};
|
|
||||||
|
|
||||||
static int xml_init(void)
|
|
||||||
{
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int xml_finalize(void)
|
|
||||||
{
|
|
||||||
return OPAL_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
static char* xml_process(char *str, int major_id, int minor_id, int num_tags, char **tags)
|
|
||||||
{
|
|
||||||
char *tmp, *tmp2;
|
|
||||||
int i, len;
|
|
||||||
uint16_t major_up, major_dn;
|
|
||||||
|
|
||||||
/* strip trailing newlines from the data */
|
|
||||||
len = strlen(str)-1;
|
|
||||||
if (str[len] == '\n' || str[len] == '\r') {
|
|
||||||
str[len] = '\0';
|
|
||||||
}
|
|
||||||
|
|
||||||
/* convert internal newlines */
|
|
||||||
for (i=0; i < len; i++) {
|
|
||||||
if (str[i] == '\n' || str[i] == '\r') {
|
|
||||||
str[i] = ';';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/* convert major-id */
|
|
||||||
major_up = (0xffff0000 & major_id) >> 16;
|
|
||||||
major_dn = 0x0000ffff & major_id;
|
|
||||||
|
|
||||||
tmp = NULL;
|
|
||||||
if (1 < num_tags) {
|
|
||||||
asprintf(&tmp, " | %s", (NULL == tags[1]) ? "UNKNOWN" : tags[1]);
|
|
||||||
for (i=2; i < num_tags; i++) {
|
|
||||||
asprintf(&tmp2, "%s | %s", tmp, (NULL == tags[i]) ? "UNKNOWN" : tags[i]);
|
|
||||||
free(tmp);
|
|
||||||
tmp = tmp2;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
asprintf(&tmp2, "<xml| [[%d,%d],%d] | %s%s | %s |xml>",
|
|
||||||
major_up, major_dn, minor_id,
|
|
||||||
(NULL == tags[0]) ? "UNKNOWN" : tags[0],
|
|
||||||
(NULL == tmp) ? "" : tmp, str);
|
|
||||||
|
|
||||||
return tmp2;
|
|
||||||
}
|
|
@ -40,7 +40,6 @@
|
|||||||
#include "opal/mca/backtrace/base/base.h"
|
#include "opal/mca/backtrace/base/base.h"
|
||||||
#include "opal/mca/timer/base/base.h"
|
#include "opal/mca/timer/base/base.h"
|
||||||
#include "opal/mca/paffinity/base/base.h"
|
#include "opal/mca/paffinity/base/base.h"
|
||||||
#include "opal/mca/filter/base/base.h"
|
|
||||||
#include "opal/event/event.h"
|
#include "opal/event/event.h"
|
||||||
#include "opal/runtime/opal_progress.h"
|
#include "opal/runtime/opal_progress.h"
|
||||||
#include "opal/mca/carto/base/base.h"
|
#include "opal/mca/carto/base/base.h"
|
||||||
@ -138,9 +137,6 @@ opal_finalize(void)
|
|||||||
/* close the processor affinity base */
|
/* close the processor affinity base */
|
||||||
opal_paffinity_base_close();
|
opal_paffinity_base_close();
|
||||||
|
|
||||||
/* finalize the filter system */
|
|
||||||
opal_filter_base_close();
|
|
||||||
|
|
||||||
/* close the memcpy base */
|
/* close the memcpy base */
|
||||||
opal_memcpy_base_close();
|
opal_memcpy_base_close();
|
||||||
|
|
||||||
|
@ -36,7 +36,6 @@
|
|||||||
#include "opal/mca/paffinity/base/base.h"
|
#include "opal/mca/paffinity/base/base.h"
|
||||||
#include "opal/mca/timer/base/base.h"
|
#include "opal/mca/timer/base/base.h"
|
||||||
#include "opal/mca/memchecker/base/base.h"
|
#include "opal/mca/memchecker/base/base.h"
|
||||||
#include "opal/mca/filter/base/base.h"
|
|
||||||
#include "opal/dss/dss.h"
|
#include "opal/dss/dss.h"
|
||||||
#include "opal/mca/carto/base/base.h"
|
#include "opal/mca/carto/base/base.h"
|
||||||
|
|
||||||
@ -288,16 +287,6 @@ opal_init(void)
|
|||||||
goto return_error;
|
goto return_error;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* initialize the filter system */
|
|
||||||
if (OPAL_SUCCESS != (ret = opal_filter_base_open())) {
|
|
||||||
error = "opal_filter_open";
|
|
||||||
goto return_error;
|
|
||||||
}
|
|
||||||
if (OPAL_SUCCESS != (ret = opal_filter_base_select())) {
|
|
||||||
error = "opal_filter_select";
|
|
||||||
goto return_error;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* open the processor affinity base */
|
/* open the processor affinity base */
|
||||||
opal_paffinity_base_open();
|
opal_paffinity_base_open();
|
||||||
opal_paffinity_base_select();
|
opal_paffinity_base_select();
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user