Commit c276e4c2 authored by Shane Snyder's avatar Shane Snyder

first cut at unifying mmap feature with darshan

parent 5f4e06f6
......@@ -43,7 +43,8 @@
/* default path for storing mmap log files is '/tmp' */
#define DARSHAN_DEF_MMAP_LOG_PATH "/tmp"
#define DARSHAN_RECORD_BUF_SIZE (1024 * 100) /* store 1024 records, each of at most 100 bytes */
/* default record buf can store 2048 records of size 100 bytes */
#define DARSHAN_RECORD_BUF_SIZE (2048 * 100)
/* Default runtime compression buffer size */
#define DARSHAN_COMP_BUF_SIZE DARSHAN_MOD_MEM_MAX
......@@ -51,19 +52,23 @@
/* in memory structure to keep up with job level data */
struct darshan_core_runtime
{
/* pointers to each log file component */
struct darshan_header *log_hdr_p;
struct darshan_job *log_job_p;
char *log_exemnt_p;
void *log_rec_p;
void *log_mod_p;
char mmap_log_name[PATH_MAX];
/* darshan-core internal data structures */
struct darshan_core_record_ref *rec_hash;
int rec_hash_cnt;
struct darshan_core_module* mod_array[DARSHAN_MAX_MODS];
int mod_mem_used;
char *comp_buf;
double wtime_offset;
#ifdef __DARSHAN_ENABLE_MMAP_LOGS
char mmap_log_name[PATH_MAX];
#endif
};
struct darshan_core_module
......@@ -74,8 +79,7 @@ struct darshan_core_module
struct darshan_core_record_ref
{
char *name;
darshan_record_id id;
void *rec_p; /* id & name buffer */
uint64_t mod_flags;
uint64_t global_mod_flags;
UT_hash_handle hlink;
......
......@@ -93,7 +93,7 @@ struct darshan_module_funcs
* environment, allowing the module to store I/O characterization data.
* 'funcs' is a pointer to a structure containing each of the function
* pointers required by darshan-core to shut down the module. The function
* returns the following integers passed in as pointers: 'my_rank' is the
* returns the following integers passed in as pointers: 'rank' is the
* MPI rank of the calling process, 'mod_mem_limit' is the maximum amount
* of memory the module may use, and 'sys_mem_alignment' is the configured
* memory alignment value Darshan was configured with.
......@@ -103,7 +103,7 @@ void darshan_core_register_module(
struct darshan_module_funcs *funcs,
int *inout_mod_size,
void **mod_buf,
int *my_rank,
int *rank,
int *sys_mem_alignment);
/* darshan_core_unregister_module()
......
This diff is collapsed.
......@@ -45,7 +45,9 @@ MMAP_LOG_PRE=$(basename $DARSHAN_TEST_LOG | cut -d'_' -f 1-3)
# construct full output log directory name
OUTLOG_DIR=${DARSHAN_LOG_DIR}/${OUTLOG_YEAR}/${OUTLOG_MON}/${OUTLOG_DAY}/
OUTLOG_DIR=$OUTLOG_DIR/${MMAP_LOG_PRE}_${OUTLOG_MON}-${OUTLOG_DAY}-${OUTLOG_SECS}
OUTLOG_DIR=${OUTLOG_DIR}/${MMAP_LOG_PRE}_${OUTLOG_MON}-${OUTLOG_DAY}-${OUTLOG_SECS}
# TODO: do shared reduction and skip mkdir if just one compute node?
# create the output directory for this job
mkdir -p $OUTLOG_DIR
......
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