@@ -64,19 +64,15 @@ static void op_callbk(pmix_status_t status, void *cbdata)
64
64
{
65
65
mylock_t * lock = (mylock_t * ) cbdata ;
66
66
67
- fprintf (stderr , "Client %s:%d OP CALLBACK CALLED WITH STATUS %d\n" , myproc .nspace , myproc .rank ,
68
- status );
69
67
lock -> status = status ;
70
68
DEBUG_WAKEUP_THREAD (lock );
71
69
}
72
70
73
71
static void errhandler_reg_callbk (pmix_status_t status , size_t errhandler_ref , void * cbdata )
74
72
{
75
73
mylock_t * lock = (mylock_t * ) cbdata ;
76
-
77
- fprintf (stderr ,
78
- "Client %s:%d ERRHANDLER REGISTRATION CALLBACK CALLED WITH STATUS %d, ref=%lu\n" ,
79
- myproc .nspace , myproc .rank , status , (unsigned long ) errhandler_ref );
74
+ EXAMPLES_HIDE_UNUSED_PARAMS (errhandler_ref );
75
+
80
76
lock -> status = status ;
81
77
DEBUG_WAKEUP_THREAD (lock );
82
78
}
@@ -114,15 +110,6 @@ int main(int argc, char **argv)
114
110
}
115
111
nprocs = val -> data .uint32 ;
116
112
PMIX_VALUE_RELEASE (val );
117
- /* and our context ID */
118
- if (PMIX_SUCCESS != (rc = PMIx_Get (& proc , PMIX_GROUP_CONTEXT_ID , NULL , 0 , & val ))) {
119
- fprintf (stderr , "Client ns %s rank %d: PMIx_Get job context ID failed: %s\n" , myproc .nspace ,
120
- myproc .rank , PMIx_Error_string (rc ));
121
- goto done ;
122
- }
123
- cid = 0 ;
124
- PMIX_VALUE_GET_NUMBER (rc , val , cid , size_t );
125
- fprintf (stderr , "Client %s:%d job size %d CID %u\n" , myproc .nspace , myproc .rank , nprocs , (unsigned )cid );
126
113
127
114
/* register our default errhandler */
128
115
DEBUG_CONSTRUCT_LOCK (& lock );
@@ -201,11 +188,10 @@ int main(int argc, char **argv)
201
188
if (NULL != results ) {
202
189
cid = 0 ;
203
190
PMIX_VALUE_GET_NUMBER (rc , & results [0 ].value , cid , size_t );
204
- fprintf (stderr , "%d Group construct complete with status %s KEY %s CID %ld \n" ,
205
- myproc .rank , PMIx_Error_string (rc ), results [0 ].key , cid );
191
+ fprintf (stderr , "%d Group construct complete with status %s KEY %s CID %lu \n" ,
192
+ myproc .rank , PMIx_Error_string (rc ), results [0 ].key , ( unsigned long ) cid );
206
193
} else {
207
194
fprintf (stderr , "%d Group construct complete, but no CID returned\n" , myproc .rank );
208
- goto done ;
209
195
}
210
196
PMIX_PROC_FREE (procs , nprocs );
211
197
@@ -221,6 +207,7 @@ int main(int argc, char **argv)
221
207
222
208
PMIX_INFO_CONSTRUCT (& tinfo [0 ]);
223
209
PMIX_INFO_LOAD (& tinfo [0 ], PMIX_GROUP_CONTEXT_ID , & cid , PMIX_SIZE );
210
+ PMIX_INFO_SET_QUALIFIER (& tinfo [0 ]);
224
211
PMIX_INFO_CONSTRUCT (& tinfo [1 ]);
225
212
PMIX_INFO_LOAD (& tinfo [1 ], PMIX_TIMEOUT , & get_timeout , PMIX_UINT32 );
226
213
@@ -231,18 +218,20 @@ int main(int argc, char **argv)
231
218
myproc .nspace , myproc .rank , n , PMIx_Error_string (rc ));
232
219
continue ;
233
220
}
234
- if (PMIX_UINT64 != val -> type ) {
221
+ if (PMIX_SIZE != val -> type ) {
235
222
fprintf (stderr , "%s:%d: PMIx_Get LOCAL CID for rank %d returned wrong type: %s\n" , myproc .nspace ,
236
223
myproc .rank , n , PMIx_Data_type_string (val -> type ));
237
224
PMIX_VALUE_RELEASE (val );
238
225
continue ;
239
226
}
240
- if ((1234UL + (unsigned long )n ) != val -> data .uint64 ) {
241
- fprintf (stderr , "%s:%d: PMIx_Get LOCAL CID for rank %d returned wrong value: %lu \n" ,
242
- myproc .nspace , myproc .rank , n , ( unsigned long ) val -> data . uint64 );
227
+ if ((1234UL + (unsigned long )n ) != val -> data .size ) {
228
+ fprintf (stderr , "%s:%d: PMIx_Get LOCAL CID for rank %d returned wrong value: %s \n" ,
229
+ myproc .nspace , myproc .rank , n , PMIx_Value_string ( val ) );
243
230
PMIX_VALUE_RELEASE (val );
244
231
continue ;
245
232
}
233
+ fprintf (stderr , "%s:%d: PMIx_Get LOCAL CID for rank %u SUCCESS value: %s\n" ,
234
+ myproc .nspace , myproc .rank , n , PMIx_Value_string (val ));
246
235
PMIX_VALUE_RELEASE (val );
247
236
}
248
237
0 commit comments