<html lang='en'>
<head>
<meta content='text/html; charset=utf-8' http-equiv='Content-Type'>
<title>
GitLab
</title>
</meta>
</head>
<style>
  img {
    max-width: 100%;
    height: auto;
  }
  p.details {
    font-style:italic;
    color:#777
  }
  .footer p {
    font-size:small;
    color:#777
  }
  pre.commit-message {
    white-space: pre-wrap;
  }
  .file-stats a {
    text-decoration: none;
  }
  .file-stats .new-file {
    color: #090;
  }
  .file-stats .deleted-file {
    color: #B00;
  }
</style>
<body>
<div class='content'>
<h3>Shane Snyder pushed to branch dev-modular 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/928fdff4f6dbc92f33988f09b93794d4e51c5dc8">928fdff4</a></strong>
<div>
<span>by Shane Snyder</span>
<i>at 2015-09-25T15:02:25Z</i>
</div>
<pre class='commit-message'>bug fix for modules creating more than max records</pre>
</li>
</ul>
<h4>7 changed files:</h4>
<ul>
<li class='file-stats'>
<a href='#diff-0'>
darshan-runtime/darshan-core.h
</a>
</li>
<li class='file-stats'>
<a href='#diff-1'>
darshan-runtime/lib/darshan-bgq.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-2'>
darshan-runtime/lib/darshan-core.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-3'>
darshan-runtime/lib/darshan-hdf5.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-4'>
darshan-runtime/lib/darshan-mpiio.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-5'>
darshan-runtime/lib/darshan-pnetcdf.c
</a>
</li>
<li class='file-stats'>
<a href='#diff-6'>
darshan-runtime/lib/darshan-posix.c
</a>
</li>
</ul>
<h4>Changes:</h4>
<li id='diff-0'>
<a href='https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8#diff-0'>
<strong>
darshan-runtime/darshan-core.h
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/darshan-runtime/darshan-core.h
</span><span style="color: #000000;background-color: #ddffdd">+++ b/darshan-runtime/darshan-core.h
</span><span style="color: #aaaaaa">@@ -26,7 +26,7 @@
</span> /* Environment variable to override __DARSHAN_MEM_ALIGNMENT */
 #define DARSHAN_MEM_ALIGNMENT_OVERRIDE "DARSHAN_MEMALIGN"
 
-#define DARSHAN_CORE_MAX_RECORDS 4096
<span style="color: #000000;background-color: #ddffdd">+#define DARSHAN_CORE_MAX_RECORDS 2048
</span> 
 /* TODO: revisit this default size if we change memory per module */
 #define DARSHAN_CORE_COMP_BUF_SIZE (2 * 1024 * 1024)
</code></pre>

<br>
</li>
<li id='diff-1'>
<a href='https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8#diff-1'>
<strong>
darshan-runtime/lib/darshan-bgq.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/darshan-runtime/lib/darshan-bgq.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/darshan-runtime/lib/darshan-bgq.c
</span><span style="color: #aaaaaa">@@ -122,7 +122,7 @@ void bgq_runtime_initialize()
</span>     if(bgq_runtime || instrumentation_disabled)
         return;
 
<span style="color: #000000;background-color: #ffdddd">-    /* register the "NULL" module with the darshan-core component */
</span><span style="color: #000000;background-color: #ddffdd">+    /* register the BG/Q module with the darshan-core component */
</span>     darshan_core_register_module(
         DARSHAN_BGQ_MOD,
         &bgq_mod_fns,
<span style="color: #aaaaaa">@@ -161,6 +161,18 @@ void bgq_runtime_initialize()
</span>         &bgq_runtime->record.f_id,
         &bgq_runtime->record.alignment);
 
<span style="color: #000000;background-color: #ddffdd">+    /* if record is set to 0, darshan-core is out of space and will not
+     * track this record, so we should avoid tracking it, too
+     */
+    if(bgq_runtime->record.f_id == 0)
+    {
+        instrumentation_disabled = 1;
+        free(bgq_runtime);
+        bgq_runtime = NULL;
+        BGQ_UNLOCK();
+        return;
+    }
+
</span>     capture(&bgq_runtime->record);
 
     BGQ_UNLOCK();
</code></pre>

<br>
</li>
<li id='diff-2'>
<a href='https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8#diff-2'>
<strong>
darshan-runtime/lib/darshan-core.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/darshan-runtime/lib/darshan-core.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/darshan-runtime/lib/darshan-core.c
</span><span style="color: #aaaaaa">@@ -1549,6 +1549,8 @@ void darshan_core_register_record(
</span>     darshan_record_id tmp_rec_id;
     struct darshan_core_record_ref *ref;
 
<span style="color: #000000;background-color: #ddffdd">+    *rec_id = 0;
+
</span>     if(!darshan_core)
         return;
 
</code></pre>

<br>
</li>
<li id='diff-3'>
<a href='https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8#diff-3'>
<strong>
darshan-runtime/lib/darshan-hdf5.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/darshan-runtime/lib/darshan-hdf5.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/darshan-runtime/lib/darshan-hdf5.c
</span><span style="color: #aaaaaa">@@ -273,6 +273,16 @@ static struct hdf5_file_runtime* hdf5_file_by_name(const char *name)
</span>         &file_id,
         NULL);
 
<span style="color: #000000;background-color: #ddffdd">+    /* if record is set to 0, darshan-core is out of space and will not
+     * track this record, so we should avoid tracking it, too
+     */
+    if(file_id == 0)
+    {
+        if(newname != name)
+            free(newname);
+        return(NULL);
+    }
+
</span>     /* search the hash table for this file record, and return if found */
     HASH_FIND(hlink, hdf5_runtime->file_hash, &file_id, sizeof(darshan_record_id), file);
     if(file)
</code></pre>

<br>
</li>
<li id='diff-4'>
<a href='https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8#diff-4'>
<strong>
darshan-runtime/lib/darshan-mpiio.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/darshan-runtime/lib/darshan-mpiio.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/darshan-runtime/lib/darshan-mpiio.c
</span><span style="color: #aaaaaa">@@ -895,6 +895,16 @@ static struct mpiio_file_runtime* mpiio_file_by_name(const char *name)
</span>         &file_id,
         NULL);
 
<span style="color: #000000;background-color: #ddffdd">+    /* if record is set to 0, darshan-core is out of space and will not
+     * track this record, so we should avoid tracking it, too
+     */
+    if(file_id == 0)
+    {
+        if(newname != name)
+            free(newname);
+        return(NULL);
+    }
+
</span>     /* search the hash table for this file record, and return if found */
     HASH_FIND(hlink, mpiio_runtime->file_hash, &file_id, sizeof(darshan_record_id), file);
     if(file)
</code></pre>

<br>
</li>
<li id='diff-5'>
<a href='https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8#diff-5'>
<strong>
darshan-runtime/lib/darshan-pnetcdf.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/darshan-runtime/lib/darshan-pnetcdf.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/darshan-runtime/lib/darshan-pnetcdf.c
</span><span style="color: #aaaaaa">@@ -285,6 +285,16 @@ static struct pnetcdf_file_runtime* pnetcdf_file_by_name(const char *name)
</span>         &file_id,
         NULL);
 
<span style="color: #000000;background-color: #ddffdd">+    /* if record is set to 0, darshan-core is out of space and will not
+     * track this record, so we should avoid tracking it, too
+     */
+    if(file_id == 0)
+    {
+        if(newname != name)
+            free(newname);
+        return(NULL);
+    }
+
</span>     /* search the hash table for this file record, and return if found */
     HASH_FIND(hlink, pnetcdf_runtime->file_hash, &file_id, sizeof(darshan_record_id), file);
     if(file)
</code></pre>

<br>
</li>
<li id='diff-6'>
<a href='https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8#diff-6'>
<strong>
darshan-runtime/lib/darshan-posix.c
</strong>
</a>
<hr>
<pre class="highlight"><code><span style="color: #000000;background-color: #ffdddd">--- a/darshan-runtime/lib/darshan-posix.c
</span><span style="color: #000000;background-color: #ddffdd">+++ b/darshan-runtime/lib/darshan-posix.c
</span><span style="color: #aaaaaa">@@ -1526,6 +1526,16 @@ static struct posix_file_runtime* posix_file_by_name(const char *name)
</span>         &file_id,
         &file_alignment);
 
<span style="color: #000000;background-color: #ddffdd">+    /* if record is set to 0, darshan-core is out of space and will not
+     * track this record, so we should avoid tracking it, too
+     */
+    if(file_id == 0)
+    {
+        if(newname != name)
+            free(newname);
+        return(NULL);
+    }
+
</span>     /* search the hash table for this file record, and return if found */
     HASH_FIND(hlink, posix_runtime->file_hash, &file_id, sizeof(darshan_record_id), file);
     if(file)
</code></pre>

<br>
</li>

</div>
<div class='footer' style='margin-top: 10px;'>
<p>

<br>
<a href="https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8">View it on GitLab</a>
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Commit","url":"https://xgitlab.cels.anl.gov/darshan/darshan/commit/928fdff4f6dbc92f33988f09b93794d4e51c5dc8"}}</script>
</p>
</div>
</body>
</html>