[mpich-commits] [mpich] MPICH primary repository branch, master, updated. v3.2-444-g8e35251

Service Account noreply at mpich.org
Tue Sep 13 21:49:12 CDT 2016


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "MPICH primary repository".

The branch, master has been updated
       via  8e35251dc2f5e54bb91e80c62d385631c8202213 (commit)
      from  3bb6c6c330d92087813c55de6379d5c8b30a9075 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.mpich.org/mpich.git/commitdiff/8e35251dc2f5e54bb91e80c62d385631c8202213

commit 8e35251dc2f5e54bb91e80c62d385631c8202213
Author: Pavan Balaji <balaji at anl.gov>
Date:   Thu Oct 15 00:29:57 2015 -0500

    Added a pack_external test file from Intel.
    
    Test only exercises the code path.  Futrue improvement should validate
    the packed buffer is actually in external32 format.
    
    Signed-off-by: Rob Latham <robl at mcs.anl.gov>

diff --git a/test/mpi/datatype/Makefile.am b/test/mpi/datatype/Makefile.am
index ee6d9c1..ab787c1 100644
--- a/test/mpi/datatype/Makefile.am
+++ b/test/mpi/datatype/Makefile.am
@@ -51,6 +51,7 @@ noinst_PROGRAMS =           \
     simple-commit           \
     simple-pack             \
     simple-pack-external    \
+    simple-pack-external2   \
     simple-resized          \
     simple-size-extent      \
     sizedtypes              \
diff --git a/test/mpi/datatype/simple-pack-external2.c b/test/mpi/datatype/simple-pack-external2.c
new file mode 100644
index 0000000..1730e02
--- /dev/null
+++ b/test/mpi/datatype/simple-pack-external2.c
@@ -0,0 +1,40 @@
+#include <mpi.h>
+#include <stdlib.h>
+
+char *datarep = "external32";
+
+#define UINT_COUNT (2)
+#define DBLE_COUNT (24)
+
+int main(void)
+{
+    unsigned *uint_data = calloc(UINT_COUNT, sizeof(unsigned));
+    double *dble_data = calloc(DBLE_COUNT, sizeof(double));
+    MPI_Aint uint_pack_size, dble_pack_size;
+    MPI_Aint pack_size;
+    void *pack_buffer;
+    MPI_Aint position = 0;
+
+    MPI_Init(NULL, NULL);
+
+    MPI_Pack_external_size(datarep, UINT_COUNT, MPI_UNSIGNED, &uint_pack_size);
+    MPI_Pack_external_size(datarep, DBLE_COUNT, MPI_DOUBLE, &dble_pack_size);
+
+    pack_size = uint_pack_size + dble_pack_size;
+    pack_buffer = malloc(pack_size);
+
+    MPI_Pack_external(datarep, uint_data, UINT_COUNT, MPI_UNSIGNED, pack_buffer, pack_size,
+                      &position);
+    MPI_Pack_external(datarep, dble_data, DBLE_COUNT, MPI_DOUBLE, pack_buffer, pack_size,
+                      &position);
+
+    free(pack_buffer);
+    free(dble_data);
+    free(uint_data);
+
+    MPI_Finalize();
+
+    printf(" No Errors\n");
+
+    return 0;
+}
diff --git a/test/mpi/datatype/testlist.in b/test/mpi/datatype/testlist.in
index 0e53faf..a3a3271 100644
--- a/test/mpi/datatype/testlist.in
+++ b/test/mpi/datatype/testlist.in
@@ -4,6 +4,7 @@ lbub 1
 localpack 1
 simple-pack 1
 simple-pack-external 1
+simple-pack-external2 1
 transpose-pack 1
 slice-pack 1
 struct-pack 1

-----------------------------------------------------------------------

Summary of changes:
 test/mpi/datatype/Makefile.am             |    1 +
 test/mpi/datatype/simple-pack-external2.c |   40 +++++++++++++++++++++++++++++
 test/mpi/datatype/testlist.in             |    1 +
 3 files changed, 42 insertions(+), 0 deletions(-)
 create mode 100644 test/mpi/datatype/simple-pack-external2.c


hooks/post-receive
-- 
MPICH primary repository


More information about the commits mailing list