<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<title>
GitLab
</title>
</head>
<body>
<style type="text/css">
img {
max-width: 100%; height: auto;
}
</style>
<div class="content">
<h3>
Philip Carns pushed to branch dev-stdio
at <a href="https://xgitlab.cels.anl.gov/darshan/darshan">darshan / darshan</a>
</h3>
<h4>
Commits:
</h4>
<ul>
<li>
<strong><a href="https://xgitlab.cels.anl.gov/darshan/darshan/commit/841429de3ffaaaed5cf574d84e35e78206d62b5a">841429de</a></strong>
<div>
<span>by Phil Carns</span>
<i>at 2016-04-29T17:31:41-04:00</i>
</div>
<pre class="commit-message" style="white-space: pre-wrap">get utils working for stdio module</pre>
</li>
</ul>
<h4>3 changed files:</h4>
<ul>
<li class="file-stats">
<a href="#620f2ecad2bb6f74b2fcd0134963a841" style="text-decoration: none">
darshan-runtime/lib/darshan-stdio.c
</a>
</li>
<li class="file-stats">
<a href="#ad29afc395839758d41094872298bd0d" style="text-decoration: none">
darshan-stdio-log-format.h
</a>
</li>
<li class="file-stats">
<a href="#c0b0bf6d71bc5fc7e6d50d69c8aa2413" style="text-decoration: none">
darshan-util/darshan-stdio-logutils.c
</a>
</li>
</ul>
<h4>Changes:</h4>
<li id="620f2ecad2bb6f74b2fcd0134963a841">
<a href="https://xgitlab.cels.anl.gov/darshan/darshan/commit/841429de3ffaaaed5cf574d84e35e78206d62b5a#diff-0">
<strong>
darshan-runtime/lib/darshan-stdio.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="background: #ffdddd; color: #000000">--- a/darshan-runtime/lib/darshan-stdio.c
</span><span style="background: #ddffdd; color: #000000">+++ b/darshan-runtime/lib/darshan-stdio.c
</span><span style="color: #aaaaaa">@@ -35,7 +35,7 @@ DARSHAN_FORWARD_DECL(fopen, FILE*, (const char *path, const char *mode));
</span> DARSHAN_FORWARD_DECL(fopen64, FILE*, (const char *path, const char *mode));
/* The stdio_file_runtime structure maintains necessary runtime metadata
<span style="background: #ffdddd; color: #000000">- * for the STDIO file record (darshan_stdio_file structure, defined in
</span><span style="background: #ddffdd; color: #000000">+ * for the STDIO file record (darshan_stdio_record structure, defined in
</span> * darshan-stdio-log-format.h) pointed to by 'file_record'. This metadata
* assists with the instrumenting of specific statistics in the file record.
* 'hlink' is a hash table link structure used to add/remove this record
<span style="color: #aaaaaa">@@ -44,23 +44,23 @@ DARSHAN_FORWARD_DECL(fopen64, FILE*, (const char *path, const char *mode));
</span> * RATIONALE: the STDIO module needs to track some stateful, volatile
* information about each open file (like the current file offset, most recent
* access time, etc.) to aid in instrumentation, but this information can't be
<span style="background: #ffdddd; color: #000000">- * stored in the darshan_stdio_file struct because we don't want it to appear in
</span><span style="background: #ddffdd; color: #000000">+ * stored in the darshan_stdio_record struct because we don't want it to appear in
</span> * the final darshan log file. We therefore associate a stdio_file_runtime
<span style="background: #ffdddd; color: #000000">- * struct with each darshan_stdio_file struct in order to track this information.
</span><span style="background: #ddffdd; color: #000000">+ * struct with each darshan_stdio_record struct in order to track this information.
</span> *
* NOTE: There is a one-to-one mapping of stdio_file_runtime structs to
<span style="background: #ffdddd; color: #000000">- * darshan_stdio_file structs.
</span><span style="background: #ddffdd; color: #000000">+ * darshan_stdio_record structs.
</span> *
<span style="background: #ffdddd; color: #000000">- * NOTE: The stdio_file_runtime struct contains a pointer to a darshan_stdio_file
</span><span style="background: #ddffdd; color: #000000">+ * NOTE: The stdio_file_runtime struct contains a pointer to a darshan_stdio_record
</span> * struct (see the *file_record member) rather than simply embedding an entire
<span style="background: #ffdddd; color: #000000">- * darshan_stdio_file struct. This is done so that all of the darshan_stdio_file
</span><span style="background: #ddffdd; color: #000000">+ * darshan_stdio_record struct. This is done so that all of the darshan_stdio_record
</span> * structs can be kept contiguous in memory as a single array to simplify
* reduction, compression, and storage.
*/
struct stdio_file_runtime
{
/* TODO: make sure we need/want all of these fields */
<span style="background: #ffdddd; color: #000000">- struct darshan_stdio_file* file_record;
</span><span style="background: #ddffdd; color: #000000">+ struct darshan_stdio_record* file_record;
</span> int64_t offset;
int64_t last_byte_read;
int64_t last_byte_written;
<span style="color: #aaaaaa">@@ -108,7 +108,7 @@ struct stdio_file_runtime_ref
</span> struct stdio_runtime
{
struct stdio_file_runtime* file_runtime_array;
<span style="background: #ffdddd; color: #000000">- struct darshan_stdio_file* file_record_array;
</span><span style="background: #ddffdd; color: #000000">+ struct darshan_stdio_record* file_record_array;
</span> int file_array_size;
int file_array_ndx;
struct stdio_file_runtime* file_hash;
<span style="color: #aaaaaa">@@ -237,14 +237,14 @@ static void stdio_runtime_initialize()
</span> /* set maximum number of file records according to max memory limit */
/* NOTE: maximum number of records is based on the size of a stdio file record */
/* TODO: should we base memory usage off file record or total runtime structure sizes? */
<span style="background: #ffdddd; color: #000000">- stdio_runtime->file_array_size = mem_limit / sizeof(struct darshan_stdio_file);
</span><span style="background: #ddffdd; color: #000000">+ stdio_runtime->file_array_size = mem_limit / sizeof(struct darshan_stdio_record);
</span> stdio_runtime->file_array_ndx = 0;
/* allocate array of runtime file records */
stdio_runtime->file_runtime_array = malloc(stdio_runtime->file_array_size *
sizeof(struct stdio_file_runtime));
stdio_runtime->file_record_array = malloc(stdio_runtime->file_array_size *
<span style="background: #ffdddd; color: #000000">- sizeof(struct darshan_stdio_file));
</span><span style="background: #ddffdd; color: #000000">+ sizeof(struct darshan_stdio_record));
</span> if(!stdio_runtime->file_runtime_array || !stdio_runtime->file_record_array)
{
stdio_runtime->file_array_size = 0;
<span style="color: #aaaaaa">@@ -253,7 +253,7 @@ static void stdio_runtime_initialize()
</span> memset(stdio_runtime->file_runtime_array, 0, stdio_runtime->file_array_size *
sizeof(struct stdio_file_runtime));
memset(stdio_runtime->file_record_array, 0, stdio_runtime->file_array_size *
<span style="background: #ffdddd; color: #000000">- sizeof(struct darshan_stdio_file));
</span><span style="background: #ddffdd; color: #000000">+ sizeof(struct darshan_stdio_record));
</span>
return;
}
<span style="color: #aaaaaa">@@ -426,7 +426,7 @@ static void stdio_get_output_data(
</span> assert(stdio_runtime);
*stdio_buf = (void *)(stdio_runtime->file_record_array);
<span style="background: #ffdddd; color: #000000">- *stdio_buf_sz = stdio_runtime->file_array_ndx * sizeof(struct darshan_stdio_file);
</span><span style="background: #ddffdd; color: #000000">+ *stdio_buf_sz = stdio_runtime->file_array_ndx * sizeof(struct darshan_stdio_record);
</span>
return;
}
</code></pre>
<br>
</li>
<li id="ad29afc395839758d41094872298bd0d">
<a href="https://xgitlab.cels.anl.gov/darshan/darshan/commit/841429de3ffaaaed5cf574d84e35e78206d62b5a#diff-1">
<strong>
darshan-stdio-log-format.h
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="background: #ffdddd; color: #000000">--- a/darshan-stdio-log-format.h
</span><span style="background: #ddffdd; color: #000000">+++ b/darshan-stdio-log-format.h
</span><span style="color: #aaaaaa">@@ -93,7 +93,7 @@ enum darshan_stdio_f_indices
</span> * - integer I/O counters (operation counts, I/O sizes, etc.)
* - floating point I/O counters (timestamps, cumulative timers, etc.)
*/
<span style="background: #ffdddd; color: #000000">-struct darshan_stdio_file
</span><span style="background: #ddffdd; color: #000000">+struct darshan_stdio_record
</span> {
darshan_record_id f_id;
int64_t rank;
</code></pre>
<br>
</li>
<li id="c0b0bf6d71bc5fc7e6d50d69c8aa2413">
<a href="https://xgitlab.cels.anl.gov/darshan/darshan/commit/841429de3ffaaaed5cf574d84e35e78206d62b5a#diff-2">
<strong>
darshan-util/darshan-stdio-logutils.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="background: #ffdddd; color: #000000">--- a/darshan-util/darshan-stdio-logutils.c
</span><span style="background: #ddffdd; color: #000000">+++ b/darshan-util/darshan-stdio-logutils.c
</span><span style="color: #aaaaaa">@@ -143,10 +143,10 @@ static void darshan_log_print_stdio_record(void *file_rec, char *file_name,
</span> static void darshan_log_print_stdio_description()
{
printf("\n# description of STDIO counters:\n");
<span style="background: #ffdddd; color: #000000">- printf("# STDIO_BARS: number of 'bar' function calls.\n");
- printf("# STDIO_BAR_DAT: value set by last call to function 'bar'.\n");
- printf("# STDIO_F_BAR_TIMESTAMP: timestamp of the first call to function 'bar'.\n");
- printf("# STDIO_F_BAR_DURATION: duration of the last call to function 'bar'.\n");
</span><span style="background: #ddffdd; color: #000000">+ printf("# STDIO_FOPENS: number of 'fopen' function calls.\n");
+ printf("# STDIO_F_OPEN_START_TIMESTAMP: timestamp of the first call to function 'fopen'.\n");
+ printf("# STDIO_F_OPEN_END_TIMESTAMP: timestamp of the completion of the last call to 'fopen'.\n");
+ printf("# STDIO_F_META_TIME: cumulative time spent in metadata operations.\n");
</span>
return;
}
</code></pre>
<br>
</li>
</div>
<div class="footer" style="margin-top: 10px">
<p style="color: #777; font-size: small">
—
<br>
<a href="https://xgitlab.cels.anl.gov/darshan/darshan/commit/841429de3ffaaaed5cf574d84e35e78206d62b5a">View it on GitLab</a>.
<br>
You're receiving this email because of your account on xgitlab.cels.anl.gov.
If you'd like to receive fewer emails, you can
adjust your notification settings.
</p>
</div>
</body>
</html>