Commit 56d3b762 authored by Kevin Harms's avatar Kevin Harms
Browse files

synchronize symbol names for counter names

parent 107deef1
......@@ -179,13 +179,13 @@ enum apmpi_f_mpiop_synctime_indices
#undef V
/* aggregate (across all the ranks) per MPI op times */
#define APMPI_F_RANK_TOTAL_COUNTERS \
#define APMPI_F_MPI_GLOBAL_COUNTERS \
Y(RANK_TOTAL_MPITIME) \
Y(RANK_TOTAL_MPISYNCTIME) \
Z(APMPI_F_RANK_TOTAL_NUM_INDICES)
Z(APMPI_F_MPI_GLOBAL_NUM_INDICES)
enum apmpi_f_mpi_global_indices
{
APMPI_F_RANK_TOTAL_COUNTERS
APMPI_F_MPI_GLOBAL_COUNTERS
};
#undef Z
#undef Y
......@@ -205,7 +205,7 @@ struct darshan_apmpi_perf_record
uint64_t counters[APMPI_NUM_INDICES];
double fcounters[APMPI_F_MPIOP_TOTALTIME_NUM_INDICES];
double fsynccounters[APMPI_F_MPIOP_SYNCTIME_NUM_INDICES];
double fglobalcounters[APMPI_F_RANK_TOTAL_NUM_INDICES];
double fglobalcounters[APMPI_F_MPI_GLOBAL_NUM_INDICES];
};
struct darshan_apmpi_header_record
{
......
......@@ -41,7 +41,7 @@ char *apmpi_f_mpiop_totaltime_counter_names[] = {
#undef V
#define X F_SYNC
#define V F_SYNC
char *apmpi_f_mpiop_totalsync_counter_names[] = {
char *apmpi_f_mpiop_synctime_counter_names[] = {
APMPI_F_MPIOP_SYNCTIME_COUNTERS
};
#undef X
......@@ -147,15 +147,15 @@ static int darshan_log_get_apmpi_rec(darshan_fd fd, void** buf_p)
{
DARSHAN_BSWAP64(&prf_rec->counters[i]);
}
for (i = 0; i < APMPI_F_NUM_INDICES; i++)
for (i = 0; i < APMPI_F_MPIOP_TOTALTIME_NUM_INDICES; i++)
{
DARSHAN_BSWAP64(&prf_rec->fcounters[i]);
}
for (i = 0; i < APMPI_F_SYNC_NUM_INDICES; i++)
for (i = 0; i < APMPI_F_MPIOP_SYNCTIME_NUM_INDICES; i++)
{
DARSHAN_BSWAP64(&prf_rec->fsynccounters[i]);
}
for (i = 0; i < APMPI_F_GLOBAL_NUM_INDICES; i++)
for (i = 0; i < APMPI_F_MPI_GLOBAL_NUM_INDICES; i++)
{
DARSHAN_BSWAP64(&prf_rec->fglobalcounters[i]);
}
......@@ -237,21 +237,21 @@ static void darshan_log_print_apmpi_rec(void *rec, char *file_name,
apmpi_counter_names[i], prf_rec->counters[i],
"", "", "");
}
for(i = 0; i < APMPI_F_NUM_INDICES; i++)
for(i = 0; i < APMPI_F_MPIOP_TOTALTIME_NUM_INDICES; i++)
{
DARSHAN_F_COUNTER_PRINT(darshan_module_names[APMPI_MOD],
prf_rec->base_rec.rank, prf_rec->base_rec.id,
apmpi_f_mpiop_totaltime_counter_names[i], prf_rec->fcounters[i],
"", "", "");
}
for(i = 0; i < APMPI_F_SYNC_NUM_INDICES; i++)
for(i = 0; i < APMPI_F_MPIOP_SYNCTIME_NUM_INDICES; i++)
{
DARSHAN_F_COUNTER_PRINT(darshan_module_names[APMPI_MOD],
prf_rec->base_rec.rank, prf_rec->base_rec.id,
apmpi_f_mpiop_totalsync_counter_names[i], prf_rec->fsynccounters[i],
apmpi_f_mpiop_synctime_counter_names[i], prf_rec->fsynccounters[i],
"", "", "");
}
for(i = 0; i < APMPI_F_GLOBAL_NUM_INDICES; i++)
for(i = 0; i < APMPI_F_MPI_GLOBAL_NUM_INDICES; i++)
{
DARSHAN_F_COUNTER_PRINT(darshan_module_names[APMPI_MOD],
prf_rec->base_rec.rank, prf_rec->base_rec.id,
......@@ -408,7 +408,7 @@ static void darshan_log_print_apmpi_rec_diff(void *file_rec1, char *file_name1,
}
}
for(i = 0; i < APMPI_F_NUM_INDICES; i++)
for(i = 0; i < APMPI_F_MPIOP_TOTALTIME_NUM_INDICES; i++)
{
if (!prf_rec2)
{
......@@ -440,14 +440,14 @@ static void darshan_log_print_apmpi_rec_diff(void *file_rec1, char *file_name1,
"", "", "");
}
}
for(i = 0; i < APMPI_F_SYNC_NUM_INDICES; i++)
for(i = 0; i < APMPI_F_MPIOP_SYNCTIME_NUM_INDICES; i++)
{
if (!prf_rec2)
{
printf("- ");
DARSHAN_F_COUNTER_PRINT(darshan_module_names[APMPI_MOD],
prf_rec1->base_rec.rank, prf_rec1->base_rec.id,
apmpi_f_mpiop_totalsync_counter_names[i], prf_rec1->fsynccounters[i],
apmpi_f_mpiop_synctime_counter_names[i], prf_rec1->fsynccounters[i],
"", "", "");
}
......@@ -456,7 +456,7 @@ static void darshan_log_print_apmpi_rec_diff(void *file_rec1, char *file_name1,
printf("+ ");
DARSHAN_F_COUNTER_PRINT(darshan_module_names[APMPI_MOD],
prf_rec2->base_rec.rank, prf_rec2->base_rec.id,
apmpi_f_mpiop_totalsync_counter_names[i], prf_rec2->fsynccounters[i],
apmpi_f_mpiop_synctime_counter_names[i], prf_rec2->fsynccounters[i],
"", "", "");
}
else if (prf_rec1->fsynccounters[i] != prf_rec2->fsynccounters[i])
......@@ -464,16 +464,16 @@ static void darshan_log_print_apmpi_rec_diff(void *file_rec1, char *file_name1,
printf("- ");
DARSHAN_F_COUNTER_PRINT(darshan_module_names[APMPI_MOD],
prf_rec1->base_rec.rank, prf_rec1->base_rec.id,
apmpi_f_mpiop_totalsync_counter_names[i], prf_rec1->fsynccounters[i],
apmpi_f_mpiop_synctime_counter_names[i], prf_rec1->fsynccounters[i],
"", "", "");
printf("+ ");
DARSHAN_F_COUNTER_PRINT(darshan_module_names[APMPI_MOD],
prf_rec2->base_rec.rank, prf_rec2->base_rec.id,
apmpi_f_mpiop_totalsync_counter_names[i], prf_rec2->fsynccounters[i],
apmpi_f_mpiop_synctime_counter_names[i], prf_rec2->fsynccounters[i],
"", "", "");
}
}
for(i = 0; i < APMPI_F_GLOBAL_NUM_INDICES; i++)
for(i = 0; i < APMPI_F_MPI_GLOBAL_NUM_INDICES; i++)
{
if (!prf_rec2)
{
......
......@@ -9,7 +9,7 @@
extern char *apmpi_counter_names[];
extern char *apmpi_f_mpiop_totaltime_counter_names[];
extern char *apmpi_f_mpiop_totalsync_counter_names[];
extern char *apmpi_f_mpiop_synctime_counter_names[];
extern char *apmpi_f_mpi_global_counter_names[];
extern struct darshan_mod_logutil_funcs apmpi_logutils;
......
......@@ -5,9 +5,9 @@
int main (int argc, char **argv)
{
printf ("APMPI_NUM_INDICES = %d\n", APMPI_NUM_INDICES);
printf ("APMPI_F_NUM_INDICES = %d\n", APMPI_F_NUM_INDICES);
printf ("APMPI_F_SYNC_NUM_INDICES = %d\n", APMPI_F_SYNC_NUM_INDICES);
printf ("APMPI_F_GLOBAL_NUM_INDICES = %d\n", APMPI_F_GLOBAL_NUM_INDICES);
printf ("APMPI_F_NUM_INDICES = %d\n", APMPI_F_MPIOP_TOTALTIME_NUM_INDICES);
printf ("APMPI_F_SYNC_NUM_INDICES = %d\n", APMPI_F_MPIOP_SYNCTIME_NUM_INDICES);
printf ("APMPI_F_GLOBAL_NUM_INDICES = %d\n", APMPI_F_MPI_GLOBAL_NUM_INDICES);
printf ("sizeof darshan_apmpi_header_record = %d\n", sizeof(struct darshan_apmpi_header_record));
printf ("sizeof darshan_apmpi_perf_record = %d\n", sizeof(struct darshan_apmpi_perf_record));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment