Skip to content

Commit eeb17fd

Browse files
committed
more log fixes
1 parent a57f653 commit eeb17fd

File tree

97 files changed

+867
-1048
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

97 files changed

+867
-1048
lines changed

src/api/pdc_analysis/include/pdc_analysis_and_transforms_common.h

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -206,27 +206,22 @@ hg_proc_analysis_ftn_in_t(hg_proc_t proc, void *data)
206206
analysis_ftn_in_t *struct_data = (analysis_ftn_in_t *)data;
207207
ret = hg_proc_hg_const_string_t(proc, &struct_data->ftn_name);
208208
if (ret != HG_SUCCESS) {
209-
// HG_LOG_ERROR("Proc error");
210209
return ret;
211210
}
212211
ret = hg_proc_hg_const_string_t(proc, &struct_data->loadpath);
213212
if (ret != HG_SUCCESS) {
214-
// HG_LOG_ERROR("Proc error");
215213
return ret;
216214
}
217215
ret = hg_proc_uint64_t(proc, &struct_data->local_obj_id);
218216
if (ret != HG_SUCCESS) {
219-
// HG_LOG_ERROR("Proc error");
220217
return ret;
221218
}
222219
ret = hg_proc_uint64_t(proc, &struct_data->iter_in);
223220
if (ret != HG_SUCCESS) {
224-
// HG_LOG_ERROR("Proc error");
225221
return ret;
226222
}
227223
ret = hg_proc_uint64_t(proc, &struct_data->iter_out);
228224
if (ret != HG_SUCCESS) {
229-
// HG_LOG_ERROR("Proc error");
230225
return ret;
231226
}
232227
return ret;
@@ -239,112 +234,90 @@ hg_proc_obj_data_iterator_in_t(hg_proc_t proc, void *data)
239234
obj_data_iterator_in_t *struct_data = (obj_data_iterator_in_t *)data;
240235
ret = hg_proc_uint64_t(proc, &struct_data->client_iter_id);
241236
if (ret != HG_SUCCESS) {
242-
// HG_LOG_ERROR("Proc error");
243237
return ret;
244238
}
245239
ret = hg_proc_uint64_t(proc, &struct_data->object_id);
246240
if (ret != HG_SUCCESS) {
247-
// HG_LOG_ERROR("Proc error");
248241
return ret;
249242
}
250243
ret = hg_proc_uint64_t(proc, &struct_data->reg_id);
251244
if (ret != HG_SUCCESS) {
252-
// HG_LOG_ERROR("Proc error");
253245
return ret;
254246
}
255247
ret = hg_proc_uint64_t(proc, &struct_data->sliceCount);
256248
if (ret != HG_SUCCESS) {
257-
// HG_LOG_ERROR("Proc error");
258249
return ret;
259250
}
260251
ret = hg_proc_uint64_t(proc, &struct_data->sliceNext);
261252
if (ret != HG_SUCCESS) {
262-
// HG_LOG_ERROR("Proc error");
263253
return ret;
264254
}
265255
ret = hg_proc_uint64_t(proc, &struct_data->sliceResetCount);
266256
if (ret != HG_SUCCESS) {
267-
// HG_LOG_ERROR("Proc error");
268257
return ret;
269258
}
270259
ret = hg_proc_uint64_t(proc, &struct_data->elementsPerSlice);
271260
if (ret != HG_SUCCESS) {
272-
// HG_LOG_ERROR("Proc error");
273261
return ret;
274262
}
275263
ret = hg_proc_uint64_t(proc, &struct_data->slicePerBlock);
276264
if (ret != HG_SUCCESS) {
277-
// HG_LOG_ERROR("Proc error");
278265
return ret;
279266
}
280267
ret = hg_proc_uint64_t(proc, &struct_data->elementsPerPlane);
281268
if (ret != HG_SUCCESS) {
282-
// HG_LOG_ERROR("Proc error");
283269
return ret;
284270
}
285271
ret = hg_proc_uint64_t(proc, &struct_data->elementsPerBlock);
286272
if (ret != HG_SUCCESS) {
287-
// HG_LOG_ERROR("Proc error");
288273
return ret;
289274
}
290275
ret = hg_proc_uint64_t(proc, &struct_data->skipCount);
291276
if (ret != HG_SUCCESS) {
292-
// HG_LOG_ERROR("Proc error");
293277
return ret;
294278
}
295279
ret = hg_proc_uint64_t(proc, &struct_data->element_size);
296280
if (ret != HG_SUCCESS) {
297-
// HG_LOG_ERROR("Proc error");
298281
return ret;
299282
}
300283
ret = hg_proc_uint64_t(proc, &struct_data->srcBlockCount);
301284
if (ret != HG_SUCCESS) {
302-
// HG_LOG_ERROR("Proc error");
303285
return ret;
304286
}
305287
ret = hg_proc_uint64_t(proc, &struct_data->contigBlockSize);
306288
if (ret != HG_SUCCESS) {
307-
// HG_LOG_ERROR("Proc error");
308289
return ret;
309290
}
310291
ret = hg_proc_uint64_t(proc, &struct_data->totalElements);
311292
if (ret != HG_SUCCESS) {
312-
// HG_LOG_ERROR("Proc error");
313293
return ret;
314294
}
315295
ret = hg_proc_uint64_t(proc, &struct_data->ndim);
316296
if (ret != HG_SUCCESS) {
317-
// HG_LOG_ERROR("Proc error");
318297
return ret;
319298
}
320299
ret = hg_proc_uint64_t(proc, &struct_data->dims_0);
321300
if (ret != HG_SUCCESS) {
322-
// HG_LOG_ERROR("Proc error");
323301
return ret;
324302
}
325303
ret = hg_proc_uint64_t(proc, &struct_data->dims_1);
326304
if (ret != HG_SUCCESS) {
327-
// HG_LOG_ERROR("Proc error");
328305
return ret;
329306
}
330307
ret = hg_proc_uint64_t(proc, &struct_data->dims_2);
331308
if (ret != HG_SUCCESS) {
332-
// HG_LOG_ERROR("Proc error");
333309
return ret;
334310
}
335311
ret = hg_proc_uint64_t(proc, &struct_data->dims_3);
336312
if (ret != HG_SUCCESS) {
337-
// HG_LOG_ERROR("Proc error");
338313
return ret;
339314
}
340315
ret = hg_proc_int32_t(proc, &struct_data->storageinfo);
341316
if (ret != HG_SUCCESS) {
342-
// HG_LOG_ERROR("Proc error");
343317
return ret;
344318
}
345319
ret = hg_proc_int32_t(proc, &struct_data->server_id);
346320
if (ret != HG_SUCCESS) {
347-
// HG_LOG_ERROR("Proc error");
348321
return ret;
349322
}
350323
return ret;
@@ -358,7 +331,6 @@ hg_proc_analysis_ftn_out_t(hg_proc_t proc, void *data)
358331

359332
ret = hg_proc_uint64_t(proc, &struct_data->remote_ftn_id);
360333
if (ret != HG_SUCCESS) {
361-
// HG_LOG_ERROR("Proc error");
362334
return ret;
363335
}
364336
return ret;
@@ -372,22 +344,18 @@ hg_proc_obj_data_iterator_out_t(hg_proc_t proc, void *data)
372344

373345
ret = hg_proc_uint64_t(proc, &struct_data->server_iter_id);
374346
if (ret != HG_SUCCESS) {
375-
// HG_LOG_ERROR("Proc error");
376347
return ret;
377348
}
378349
ret = hg_proc_uint64_t(proc, &struct_data->client_iter_id);
379350
if (ret != HG_SUCCESS) {
380-
// HG_LOG_ERROR("Proc error");
381351
return ret;
382352
}
383353
ret = hg_proc_uint64_t(proc, &struct_data->server_region_id);
384354
if (ret != HG_SUCCESS) {
385-
// HG_LOG_ERROR("Proc error");
386355
return ret;
387356
}
388357
ret = hg_proc_int32_t(proc, &struct_data->ret);
389358
if (ret != HG_SUCCESS) {
390-
// HG_LOG_ERROR("Proc error");
391359
return ret;
392360
}
393361
return ret;

src/api/pdc_analysis/pdc_analysis.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ iterator_init(pdcid_t objectId, pdcid_t reg_id, int blocks, struct _pdc_iterator
122122
iter->contigBlockSize = obj_elementsPerSlice * element_size;
123123
}
124124
else
125-
PGOTO_ERROR(FAIL, "Error: object (%" PRIu64 ") has not been initalized correctly!", objectId);
125+
PGOTO_ERROR(FAIL, "Error: Object (%" PRIu64 ") has not been initalized correctly", objectId);
126126

127127
iter->element_size = element_size;
128128
iter->objectId = objectId;
@@ -336,7 +336,7 @@ PDC_get_argv0_()
336336
shellcmd = fopen(procpath, "r");
337337
if (shellcmd == NULL) {
338338
procpath = (char *)PDC_free(procpath);
339-
PGOTO_ERROR(NULL, "fopen failed!");
339+
PGOTO_ERROR(NULL, "fopen failed");
340340
}
341341
else {
342342
cmdLength = fread(fullPath, 1, sizeof(fullPath), shellcmd);
@@ -371,7 +371,7 @@ PDC_get_argv0_()
371371
}
372372
}
373373
if (_argv0 == NULL)
374-
PGOTO_ERROR(NULL, "Unable to resolve user application name!");
374+
PGOTO_ERROR(NULL, "Unable to resolve user application name");
375375

376376
ret_value = _argv0;
377377

@@ -445,7 +445,7 @@ PDCobj_analysis_register(char *func, pdcid_t iterIn, pdcid_t iterOut)
445445
//
446446
loadpath = PDC_get_realpath(analyislibrary, applicationDir);
447447
if (PDC_get_ftnPtr_((const char *)userdefinedftn, (const char *)loadpath, &ftnHandle) < 0)
448-
PGOTO_ERROR(FAIL, "PDC_get_ftnPtr_ returned an error!");
448+
PGOTO_ERROR(FAIL, "PDC_get_ftnPtr_ returned an error");
449449

450450
if ((ftnPtr = ftnHandle) == NULL)
451451
PGOTO_ERROR(FAIL, "Analysis function lookup failed");
@@ -490,7 +490,7 @@ PDCobj_analysis_register(char *func, pdcid_t iterIn, pdcid_t iterOut)
490490

491491
// Add to our own list of analysis functions
492492
if (PDC_add_analysis_ptr_to_registry_(thisFtn) < 0)
493-
PGOTO_ERROR(FAIL, "PDC unable to register analysis function!");
493+
PGOTO_ERROR(FAIL, "PDC unable to register analysis function");
494494

495495
done:
496496
if (applicationDir)
@@ -553,7 +553,7 @@ PDCobj_data_getNextBlock(pdcid_t iter, void **nextBlock, size_t *dims)
553553
if ((thisIter->srcNext = PDC_Server_get_region_data_ptr(thisIter->objectId)) == NULL)
554554
thisIter->srcNext = PDC_malloc(thisIter->totalElements * thisIter->element_size);
555555
if ((thisIter->srcStart = thisIter->srcNext) == NULL)
556-
PGOTO_ERROR(0, "==PDC_ANALYSIS_SERVER: Unable to allocate iterator storage");
556+
PGOTO_ERROR(0, "Unable to allocate iterator storage");
557557

558558
thisIter->srcNext += thisIter->startOffset + thisIter->skipCount;
559559
}

src/api/pdc_analysis/pdc_analysis_and_transforms_connect.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ PDC_Client_send_iter_recv_id(pdcid_t iter_id, pdcid_t *meta_id)
105105
if (n_retry > 0)
106106
break;
107107
if (PDC_Client_lookup_server(server_id, 0) != SUCCEED)
108-
PGOTO_ERROR(FAIL, "==CLIENT[%d]: ERROR with PDC_Client_lookup_server", pdc_client_mpi_rank_g);
108+
PGOTO_ERROR(FAIL, "Rank[%d]: Error with PDC_Client_lookup_server", pdc_client_mpi_rank_g);
109109

110110
n_retry++;
111111
}
@@ -217,7 +217,7 @@ PDC_Client_register_obj_analysis(struct _pdc_region_analysis_ftn_info *thisFtn,
217217
if (n_retry > 0)
218218
break;
219219
if (PDC_Client_lookup_server(server_id, 0) != SUCCEED)
220-
PGOTO_ERROR(FAIL, "==CLIENT[%d]: ERROR with PDC_Client_lookup_server", pdc_client_mpi_rank_g);
220+
PGOTO_ERROR(FAIL, "Rank[%d]: Error with PDC_Client_lookup_server", pdc_client_mpi_rank_g);
221221

222222
n_retry++;
223223
}

src/api/pdc_analysis/pdc_analysis_common.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ PDC_add_analysis_ptr_to_registry_(struct _pdc_region_analysis_ftn_info *ftn_info
209209

210210
if (analysis_registry_size == 0) {
211211
if (pdc_analysis_registry_init_(initial_registry_size) == 0) {
212-
perror("Unable to initialize analysis registry!");
212+
perror("Unable to initialize analysis registry");
213213
PGOTO_DONE(-1);
214214
}
215215
}
@@ -345,7 +345,7 @@ PDC_add_transform_ptr_to_registry_(struct _pdc_region_transform_ftn_info *ftn_in
345345

346346
if (transform_registry_size == 0) {
347347
if (pdc_transform_registry_init_(initial_registry_size) == 0)
348-
PGOTO_ERROR(FAIL, "Unable to initialize transform registry!");
348+
PGOTO_ERROR(FAIL, "Unable to initialize transform registry");
349349
}
350350
currentCount = (size_t)hg_atomic_get32(&registered_transform_ftn_count_g);
351351
if (currentCount == transform_registry_size) {
@@ -462,7 +462,7 @@ HG_TEST_RPC_CB(analysis_ftn, handle)
462462
HG_Get_input(handle, &in);
463463

464464
if (PDC_get_ftnPtr_(in.ftn_name, in.loadpath, &ftnHandle) < 0)
465-
PGOTO_ERROR(FAIL, "PDC_get_ftnPtr_ returned an error!");
465+
PGOTO_ERROR(FAIL, "PDC_get_ftnPtr_ returned an error");
466466

467467
if ((ftnPtr = ftnHandle) == NULL)
468468
PGOTO_ERROR(FAIL, "Transforms function lookup failed");
@@ -545,7 +545,7 @@ HG_TEST_RPC_CB(obj_data_iterator, handle)
545545
memset(&in, 0, sizeof(in));
546546
// Decode input
547547
HG_Get_input(handle, &in);
548-
// LOG_INFO("obj_data_iterator_cb entered!\n");
548+
// LOG_INFO("obj_data_iterator_cb entered\n");
549549
ret_value = PDC_Server_instantiate_data_iterator(&in, &out);
550550

551551
HG_Respond(handle, NULL, NULL, &out);

src/api/pdc_analysis/pdc_hist_pkg.c

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ PDC_sample_min_max(pdc_var_type_t dtype, uint64_t n, void *data, double sample_p
4343
else if (PDC_UINT == dtype)
4444
MACRO_SAMPLE_MIN_MAX(uint32_t, n, data, sample_pct, *min, *max);
4545
else {
46-
PGOTO_ERROR(FAIL, "Datatype %d not supported!", dtype);
46+
PGOTO_ERROR(FAIL, "Datatype %d not supported", dtype);
4747
}
4848

4949
done:
@@ -233,7 +233,7 @@ PDC_hist_incr_all(pdc_histogram_t *hist, pdc_var_type_t dtype, uint64_t n, void
233233
else if (PDC_UINT == dtype)
234234
MACRO_HIST_INCR_ALL(uint32_t, hist, n, data);
235235
else
236-
PGOTO_ERROR(FAIL, "Datatype %d not supported!", dtype);
236+
PGOTO_ERROR(FAIL, "Datatype %d not supported", dtype);
237237

238238
done:
239239
FUNC_LEAVE(ret_value);
@@ -264,15 +264,14 @@ PDC_gen_hist(pdc_var_type_t dtype, uint64_t n, void *data)
264264

265265
hist = PDC_create_hist(dtype, 50, min, max);
266266
if (NULL == hist)
267-
PGOTO_ERROR(NULL, "Error with PDC_create_hist!");
267+
PGOTO_ERROR(NULL, "Error with PDC_create_hist");
268268

269269
PDC_hist_incr_all(hist, dtype, n, data);
270270

271271
#ifdef ENABLE_TIMING
272272
gettimeofday(&pdc_timer_end, 0);
273273
gen_hist_time = PDC_get_elapsed_time_double(&pdc_timer_start, &pdc_timer_end);
274-
LOG_INFO("== generate histogram of %lu elements with %d bins takes %.2fs\n", n, hist->nbin,
275-
gen_hist_time);
274+
LOG_INFO("Generate histogram of %lu elements with %d bins takes %.2fs\n", n, hist->nbin, gen_hist_time);
276275
#endif
277276

278277
ret_value = hist;
@@ -367,7 +366,7 @@ PDC_merge_hist(int n, pdc_histogram_t **hists)
367366

368367
for (i = 1; i < n; i++) {
369368
if (hists[i]->dtype != hists[i - 1]->dtype) {
370-
PGOTO_ERROR(NULL, "Cannot merge histograms of different types!");
369+
PGOTO_ERROR(NULL, "Cannot merge histograms of different types");
371370
}
372371
if (hists[i]->incr > incr_max) {
373372
incr_max = hists[i]->incr;
@@ -385,7 +384,7 @@ PDC_merge_hist(int n, pdc_histogram_t **hists)
385384
// Duplicate the base hist to result
386385
res = PDC_dup_hist(hists[incr_max_idx]);
387386
if (NULL == res)
388-
PGOTO_ERROR(NULL, "Error with PDC_dup_hist!");
387+
PGOTO_ERROR(NULL, "Error with PDC_dup_hist");
389388

390389
res->range[0] = tot_min;
391390
res->range[(res->nbin) * 2 - 1] = tot_max;

0 commit comments

Comments
 (0)