Skip to content

Commit c3fe27a

Browse files
committed
Fix MPIR regression with extern MPIR_proctable.
The proctable was no longer queriable via gdb because it was declared as extern in a header. Shuffle some code around to fix this. Signed-off-by: Austen Lauria <awlauria@us.ibm.com>
1 parent d6b871d commit c3fe27a

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

orte/orted/orted-mpir/orted_mpir.h

+6-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,12 @@ BEGIN_C_DECLS
1818
#define MPIR_MAX_PATH_LENGTH 512
1919
#define MPIR_MAX_ARG_LENGTH 1024
2020

21-
extern struct MPIR_PROCDESC *MPIR_proctable;
21+
struct MPIR_PROCDESC {
22+
char *host_name; /* something that can be passed to inet_addr */
23+
char *executable_name; /* name of binary */
24+
int pid; /* process pid */
25+
};
26+
2227
extern int MPIR_proctable_size;
2328
extern volatile int MPIR_being_debugged;
2429
extern volatile int MPIR_debug_state;

orte/orted/orted_submit.c

+2-7
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,8 @@ static opal_pointer_array_t tool_jobs;
123123
static int timeout_seconds;
124124
static orte_timer_t *orte_memprofile_timeout;
125125

126+
127+
extern struct MPIR_PROCDESC *MPIR_proctable;
126128
int orte_debugger_attach_fd = -1;
127129
bool orte_debugger_fifo_active=false;
128130
opal_event_t *orte_debugger_attach=NULL;
@@ -2220,13 +2222,6 @@ static void complete_recv(int status, orte_process_name_t* sender,
22202222
#define DUMP_INT(X) fprintf(stderr, " %s = %d\n", # X, X);
22212223
#define FILE_MODE (S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH)
22222224

2223-
struct MPIR_PROCDESC {
2224-
char *host_name; /* something that can be passed to inet_addr */
2225-
char *executable_name; /* name of binary */
2226-
int pid; /* process pid */
2227-
};
2228-
2229-
22302225
/**
22312226
* Initialization of data structures for running under a debugger
22322227
* using the MPICH/TotalView parallel debugger interface. Before the

0 commit comments

Comments
 (0)