Commit eb91c833 authored by Shane Snyder's avatar Shane Snyder
Browse files

apxc/apmpi log format cleanups

- use fixed size integer types rather than ints
- byteswap all record values, and match swap fn to type size
- update pydarshan backends with format changes
parent ba69643f
......@@ -133,6 +133,9 @@ static int darshan_log_get_apmpi_rec(darshan_fd fd, void** buf_p)
/* swap bytes if necessary */
DARSHAN_BSWAP64(&(hdr_rec->base_rec.id));
DARSHAN_BSWAP64(&(hdr_rec->base_rec.rank));
DARSHAN_BSWAP64(&(hdr_rec->magic));
DARSHAN_BSWAP32(&(hdr_rec->version));
DARSHAN_BSWAP32(&(hdr_rec->sync_flag));
DARSHAN_BSWAP64(&(hdr_rec->apmpi_f_variance_total_mpitime));
DARSHAN_BSWAP64(&(hdr_rec->apmpi_f_variance_total_mpisynctime));
}
......
......@@ -462,11 +462,10 @@ enum apxc_cluster_modes
struct darshan_apxc_perf_record
{
struct darshan_base_record base_rec;
int group;
int chassis;
int blade;
int node;
int marked;
int64_t group;
int64_t chassis;
int64_t blade;
int64_t node;
uint64_t counters[APXC_NUM_INDICES];
};
......@@ -474,11 +473,11 @@ struct darshan_apxc_header_record
{
struct darshan_base_record base_rec;
int64_t magic;
int nblades;
int nchassis;
int ngroups;
int memory_mode;
int cluster_mode;
int64_t nblades;
int64_t nchassis;
int64_t ngroups;
int64_t memory_mode;
int64_t cluster_mode;
uint64_t appid;
};
......
......@@ -9,22 +9,21 @@ structdefs = '''
struct darshan_apxc_perf_record
{
struct darshan_base_record base_rec;
int group;
int chassis;
int blade;
int node;
int marked;
int64_t group;
int64_t chassis;
int64_t blade;
int64_t node;
uint64_t counters[392];
};
struct darshan_apxc_header_record
{
struct darshan_base_record base_rec;
int64_t magic;
int nblades;
int nchassis;
int ngroups;
int memory_mode;
int cluster_mode;
int64_t nblades;
int64_t nchassis;
int64_t ngroups;
int64_t memory_mode;
int64_t cluster_mode;
uint64_t appid;
};
......
......@@ -111,11 +111,12 @@ static int darshan_log_get_apxc_rec(darshan_fd fd, void** buf_p)
/* swap bytes if necessary */
DARSHAN_BSWAP64(&(hdr_rec->base_rec.id));
DARSHAN_BSWAP64(&(hdr_rec->base_rec.rank));
DARSHAN_BSWAP32(&(hdr_rec->nblades));
DARSHAN_BSWAP32(&(hdr_rec->nchassis));
DARSHAN_BSWAP32(&(hdr_rec->ngroups));
DARSHAN_BSWAP32(&(hdr_rec->memory_mode));
DARSHAN_BSWAP32(&(hdr_rec->cluster_mode));
DARSHAN_BSWAP64(&(hdr_rec->magic));
DARSHAN_BSWAP64(&(hdr_rec->nblades));
DARSHAN_BSWAP64(&(hdr_rec->nchassis));
DARSHAN_BSWAP64(&(hdr_rec->ngroups));
DARSHAN_BSWAP64(&(hdr_rec->memory_mode));
DARSHAN_BSWAP64(&(hdr_rec->cluster_mode));
DARSHAN_BSWAP64(&(hdr_rec->appid));
}
else
......
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