Moving the pml_v_output global variable inside the pml_v structure. This should avoid one of the missing symbols when visibility is enabled.
This commit was SVN r18627.
Этот коммит содержится в:
родитель
03ab4f5c64
Коммит
ebe6df4c06
@ -13,6 +13,7 @@
|
||||
#include "opal/mca/mca.h"
|
||||
#include "opal/mca/base/base.h"
|
||||
#include "ompi/mca/pml/v/mca/vprotocol/base/static-components.h"
|
||||
#include "ompi/mca/pml/v/pml_v.h"
|
||||
|
||||
opal_list_t mca_vprotocol_base_components_available;
|
||||
char *mca_vprotocol_base_include_list;
|
||||
@ -37,7 +38,7 @@ int mca_vprotocol_base_open(char *vprotocol_include_list)
|
||||
int mca_vprotocol_base_close(void)
|
||||
{
|
||||
int ret;
|
||||
ret = mca_base_components_close(pml_v_output,
|
||||
ret = mca_base_components_close(mca_pml_v.output,
|
||||
&mca_vprotocol_base_components_available,
|
||||
NULL);
|
||||
OBJ_DESTRUCT(&mca_vprotocol_base_components_available);
|
||||
|
@ -10,6 +10,7 @@
|
||||
|
||||
#include "ompi_config.h"
|
||||
#include "vprotocol_base_request.h"
|
||||
#include "ompi/mca/pml/v/pml_v_output.h"
|
||||
|
||||
int mca_vprotocol_base_request_parasite(void)
|
||||
{
|
||||
|
@ -12,6 +12,7 @@
|
||||
#include "base.h"
|
||||
#include "opal/mca/mca.h"
|
||||
#include "opal/mca/base/base.h"
|
||||
#include "ompi/mca/pml/v/pml_v_output.h"
|
||||
|
||||
mca_vprotocol_base_module_t mca_vprotocol;
|
||||
mca_vprotocol_base_component_t mca_vprotocol_component = {
|
||||
@ -116,7 +117,7 @@ int mca_vprotocol_base_select(bool enable_progress_threads,
|
||||
free(om);
|
||||
}
|
||||
|
||||
mca_base_components_close(pml_v_output,
|
||||
mca_base_components_close(mca_pml_v.output,
|
||||
&mca_vprotocol_base_components_available,
|
||||
(mca_base_component_t *) best_component);
|
||||
|
||||
|
@ -13,6 +13,7 @@
|
||||
|
||||
#include "ompi_config.h"
|
||||
#include "ompi/mca/pml/base/pml_base_sendreq.h"
|
||||
#include "ompi/mca/pml/v/pml_v_output.h"
|
||||
#include "vprotocol_pessimist_sender_based_types.h"
|
||||
#include "vprotocol_pessimist_request.h"
|
||||
#include "vprotocol_pessimist.h"
|
||||
|
@ -11,4 +11,4 @@
|
||||
#include "ompi_config.h"
|
||||
#include "pml_v.h"
|
||||
|
||||
mca_pml_v_t mca_pml_v = {0, 0};
|
||||
mca_pml_v_t mca_pml_v = {-1, 0, 0};
|
||||
|
@ -18,6 +18,7 @@
|
||||
BEGIN_C_DECLS
|
||||
|
||||
struct mca_pml_v_t {
|
||||
int output;
|
||||
size_t host_pml_req_recv_size;
|
||||
size_t host_pml_req_send_size;
|
||||
mca_pml_base_component_t host_pml_component;
|
||||
@ -31,6 +32,4 @@ OMPI_MODULE_DECLSPEC extern mca_pml_base_component_1_0_0_t mca_pml_v_component;
|
||||
|
||||
END_C_DECLS
|
||||
|
||||
#include "pml_v_output.h"
|
||||
|
||||
#endif /* PML_V_H_HAS_BEEN_INCLUDED */
|
||||
|
@ -15,6 +15,7 @@
|
||||
#include "opal/mca/base/mca_base_component_repository.h"
|
||||
#include "ompi/constants.h"
|
||||
#include "ompi/mca/pml/base/base.h"
|
||||
#include "pml_v_output.h"
|
||||
#include "pml_v.h"
|
||||
#include "mca/vprotocol/vprotocol.h"
|
||||
#include "mca/vprotocol/base/base.h"
|
||||
|
@ -21,15 +21,13 @@
|
||||
#include <string.h>
|
||||
#endif
|
||||
|
||||
int pml_v_output = -1;
|
||||
|
||||
int pml_v_output_open(char *output, int verbosity) {
|
||||
opal_output_stream_t lds;
|
||||
char hostname[32] = "NA";
|
||||
|
||||
OBJ_CONSTRUCT(&lds, opal_output_stream_t);
|
||||
if(!output) {
|
||||
pml_v_output = 0;
|
||||
mca_pml_v.output = 0;
|
||||
}
|
||||
else {
|
||||
if(!strcmp(output, "stdout")) {
|
||||
@ -47,12 +45,12 @@ int pml_v_output_open(char *output, int verbosity) {
|
||||
gethostname(hostname, 32);
|
||||
asprintf(&lds.lds_prefix, "[%s:%05d] pml_v: ", hostname, getpid());
|
||||
lds.lds_verbose_level = verbosity;
|
||||
pml_v_output = opal_output_open(&lds);
|
||||
mca_pml_v.output = opal_output_open(&lds);
|
||||
free(lds.lds_prefix);
|
||||
}
|
||||
return pml_v_output;
|
||||
return mca_pml_v.output;
|
||||
}
|
||||
|
||||
void pml_v_output_close(void) {
|
||||
opal_output_close(pml_v_output);
|
||||
opal_output_close(mca_pml_v.output);
|
||||
}
|
||||
|
@ -14,13 +14,12 @@
|
||||
#include "orte/util/show_help.h"
|
||||
#include "opal_stdint.h"
|
||||
#include <stdio.h>
|
||||
#include "pml_v.h"
|
||||
|
||||
#if defined(c_plusplus) || defined(__cplusplus)
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
OMPI_MODULE_DECLSPEC extern int pml_v_output;
|
||||
|
||||
int pml_v_output_open(char *output, int verbosity);
|
||||
void pml_v_output_close(void);
|
||||
|
||||
@ -44,13 +43,13 @@ static inline void V_OUTPUT_ERR(const char *fmt, ... )
|
||||
# define V_OUTPUT(ARGS...) \
|
||||
OPAL_OUTPUT((pml_v_output, __VA_ARGS__))
|
||||
# define V_OUTPUT_VERBOSE(V, ARGS...) \
|
||||
OPAL_OUTPUT_VERBOSE((V, pml_v_output, __VA_ARGS__))
|
||||
OPAL_OUTPUT_VERBOSE((V, mca_pml_v.output, __VA_ARGS__))
|
||||
|
||||
#elif defined(__GNUC__) && !defined(__STDC__)
|
||||
# define V_OUTPUT(ARGS...) \
|
||||
OPAL_OUTPUT((pml_v_output, ARGS))
|
||||
# define V_OUTPUT_VERBOSE(V, ARGS...) \
|
||||
OPAL_OUTPUT_VERBOSE((V, pml_v_output, ARGS))
|
||||
OPAL_OUTPUT_VERBOSE((V, mca_pml_v.output, ARGS))
|
||||
|
||||
#elif OMPI_ENABLE_DEBUG
|
||||
/* No variadic macros available... So sad */
|
||||
@ -63,7 +62,7 @@ static inline void V_OUTPUT(const char* fmt, ... )
|
||||
va_start(list, fmt);
|
||||
ret = vasprintf(&str, fmt, list);
|
||||
assert(-1 != ret);
|
||||
opal_output(pml_v_output, str);
|
||||
opal_output(mca_pml_v.output, str);
|
||||
free(str);
|
||||
va_end(list);
|
||||
}
|
||||
@ -75,7 +74,7 @@ static inline void V_OUTPUT_VERBOSE(int V, const char* fmt, ... ) {
|
||||
va_start(list, fmt);
|
||||
ret = vasprintf(&str, fmt, list);
|
||||
assert(-1 != ret);
|
||||
opal_output_verbose(V, pml_v_output, str);
|
||||
opal_output_verbose(V, mca_pml_v.output, str);
|
||||
free(str);
|
||||
va_end(list);
|
||||
}
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user