darshan-bgq-log-format.h 1.96 KB
Newer Older
1 2 3 4 5 6 7 8 9
/*
 * Copyright (C) 2015 University of Chicago.
 * See COPYRIGHT notice in top-level directory.
 *
 */

#ifndef __DARSHAN_BGQ_LOG_FORMAT_H
#define __DARSHAN_BGQ_LOG_FORMAT_H

10 11
/* current BGQ log format version */
#define DARSHAN_BGQ_VER 1
12 13

#define BGQ_COUNTERS \
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
    /* control system jobid*/\
    X(BGQ_CSJOBID) \
    /* number of BGQ compute nodes */\
    X(BGQ_NNODES) \
    /* number of MPI ranks per node */\
    X(BGQ_RANKSPERNODE) \
    /* size in MB of DDR3 per node */\
    X(BGQ_DDRPERNODE) \
    /* number of i/o nodes */\
    X(BGQ_INODES) \
    /* dimension of A torus */\
    X(BGQ_ANODES) \
    /* dimension of B torus */\
    X(BGQ_BNODES) \
    /* dimension of C torus */\
    X(BGQ_CNODES) \
    /* dimension of D torus */\
    X(BGQ_DNODES) \
    /* dimension of E torus */\
    X(BGQ_ENODES) \
    /* which dimensions are torus */\
    X(BGQ_TORUSENABLED) \
    /* end of counters */\
    X(BGQ_NUM_INDICES)
38 39

#define BGQ_F_COUNTERS \
40 41 42 43
    /* timestamp when data was collected */\
    X(BGQ_F_TIMESTAMP) \
    /* end of counters */\
    X(BGQ_F_NUM_INDICES)
44

45
#define X(a) a,
46 47 48
/* integer counters for the "BGQ" example module */
enum darshan_bgq_indices
{
49
    BGQ_COUNTERS
50 51 52 53 54
};

/* floating point counters for the "BGQ" example module */
enum darshan_bgq_f_indices
{
55
    BGQ_F_COUNTERS
56
};
57
#undef X
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76

/* the darshan_bgq_record structure encompasses the high-level data/counters
 * which would actually be logged to file by Darshan for the "BGQ" example
 * module. This example implementation logs the following data for each
 * record:
 *      - a corresponding Darshan record identifier
 *      - the rank of the process responsible for the record
 *      - integer I/O counters (operation counts, I/O sizes, etc.)
 *      - floating point I/O counters (timestamps, cumulative timers, etc.)
 */
struct darshan_bgq_record
{
    darshan_record_id f_id;
    int64_t rank;
    int64_t counters[BGQ_NUM_INDICES];
    double fcounters[BGQ_F_NUM_INDICES];
};

#endif /* __DARSHAN_BGQ_LOG_FORMAT_H */