OpenMPI  0.1.1
pstat.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2004-2007 High Performance Computing Center Stuttgart,
3  * University of Stuttgart. All rights reserved.
4  * Copyright (c) 2004-2008 The Trustees of Indiana University.
5  * All rights reserved.
6  *
7  * $COPYRIGHT$
8  *
9  * Additional copyrights may follow
10  *
11  * $HEADER$
12  */
13 
14 /**
15  * @file
16  *
17  * pstat (process statistics) framework component interface.
18  *
19  * Intent
20  *
21  * To support the ompi-top utility.
22  *
23  */
24 
25 #ifndef OPAL_MCA_PSTAT_H
26 #define OPAL_MCA_PSTAT_H
27 
28 #include "opal_config.h"
29 
30 #include "opal/mca/mca.h"
31 #include "opal/mca/base/base.h"
32 #include "opal/dss/dss_types.h"
33 
34 BEGIN_C_DECLS
35 
36 /**
37  * Module initialization function. Should return OPAL_SUCCESS.
38  */
39 typedef int (*opal_pstat_base_module_init_fn_t)(void);
40 
41 typedef int (*opal_pstat_base_module_query_fn_t)(pid_t pid,
42  opal_pstats_t *stats,
43  opal_node_stats_t *nstats);
44 
45 typedef int (*opal_pstat_base_module_fini_fn_t)(void);
46 
47 /**
48  * Structure for pstat components.
49  */
51  /** MCA base component */
53  /** MCA base data */
55 };
56 
57 /**
58  * Convenience typedef
59  */
62 
63 /**
64  * Structure for pstat modules
65  */
68  opal_pstat_base_module_query_fn_t query;
69  opal_pstat_base_module_fini_fn_t finalize;
70 };
71 
72 /**
73  * Convenience typedef
74  */
77 
78 
79 /**
80  * Macro for use in components that are of type pstat
81  */
82 #define OPAL_PSTAT_BASE_VERSION_2_0_0 \
83  MCA_BASE_VERSION_2_0_0, \
84  "pstat", 2, 0, 0
85 
86 /* Global structure for accessing pstat functions */
87 OPAL_DECLSPEC extern opal_pstat_base_module_t opal_pstat;
88 
89 END_C_DECLS
90 
91 #endif /* OPAL_MCA_PSTAT_H */
Common type for all MCA components.
Definition: mca.h:250
BEGIN_C_DECLS typedef int(* opal_pstat_base_module_init_fn_t)(void)
Module initialization function.
Definition: pstat.h:39
Top-level interface for all MCA components.
Definition: dss_types.h:121
mca_base_component_data_t base_data
MCA base data.
Definition: pstat.h:54
Buffer management types.
Structure for pstat modules.
Definition: pstat.h:66
Meta data for MCA v2.0.0 components.
Definition: mca.h:309
mca_base_component_t base_version
MCA base component.
Definition: pstat.h:52
Definition: dss_types.h:100
Structure for pstat components.
Definition: pstat.h:50