[Darshan-commits] [Git][darshan/darshan][dev-dxt-mpiio-offset] log version changes for dxt-mpiio offsets

Shane Snyder xgitlab at cels.anl.gov
Sun Apr 26 21:50:08 CDT 2020



Shane Snyder pushed to branch dev-dxt-mpiio-offset at darshan / darshan


Commits:
dccca36f by Shane Snyder at 2020-04-26T21:49:16-05:00
log version changes for dxt-mpiio offsets

- - - - -


2 changed files:

- darshan-dxt-log-format.h
- darshan-util/darshan-dxt-logutils.c


Changes:

=====================================
darshan-dxt-log-format.h
=====================================
@@ -8,7 +8,7 @@
 
 /* current DXT log format version */
 #define DXT_POSIX_VER 1
-#define DXT_MPIIO_VER 1
+#define DXT_MPIIO_VER 2
 
 #define HOSTNAME_SIZE 64
 


=====================================
darshan-util/darshan-dxt-logutils.c
=====================================
@@ -150,6 +150,7 @@ static int dxt_log_get_mpiio_file(darshan_fd fd, void** dxt_mpiio_buf_p)
 {
     struct dxt_file_record *rec = *((struct dxt_file_record **)dxt_mpiio_buf_p);
     struct dxt_file_record tmp_rec;
+    int i;
     int ret;
     int64_t io_trace_size;
 
@@ -196,6 +197,15 @@ static int dxt_log_get_mpiio_file(darshan_fd fd, void** dxt_mpiio_buf_p)
                 /* byte swap trace data if necessary */
                 dxt_swap_segments(rec);
             }
+
+            if(fd->mod_ver[DXT_MPIIO_MOD] == 1)
+            {
+                /* make sure to indicate offsets are invalid in version 1 */
+                for(i = 0; i < (tmp_rec.write_count + tmp_rec.read_count); i++)
+                {
+                    ((segment_info *)tmp_p)[i].offset = -1;
+                }
+            }
         }
     }
     else



View it on GitLab: https://xgitlab.cels.anl.gov/darshan/darshan/commit/dccca36fbd53f8a77d1db53b3bb555faf20720ff

-- 
View it on GitLab: https://xgitlab.cels.anl.gov/darshan/darshan/commit/dccca36fbd53f8a77d1db53b3bb555faf20720ff
You're receiving this email because of your account on xgitlab.cels.anl.gov.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/darshan-commits/attachments/20200426/ba1ce1cc/attachment-0001.html>


More information about the Darshan-commits mailing list