Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
add minloc and maxloc for long_long
authorAugustin Degomme <augustin.degomme@imag.fr>
Mon, 7 Jul 2014 15:22:04 +0000 (17:22 +0200)
committerAugustin Degomme <augustin.degomme@imag.fr>
Mon, 7 Jul 2014 15:46:18 +0000 (17:46 +0200)
src/smpi/smpi_mpi_dt.c

index 90572e7..7ce041d 100644 (file)
@@ -1471,6 +1471,8 @@ static void minloc_func(void *a, void *b, int *length,
     APPLY_FUNC(a, b, length, double_int, MINLOC_OP);
   } else if (*datatype == MPI_SHORT_INT) {
     APPLY_FUNC(a, b, length, short_int, MINLOC_OP);
     APPLY_FUNC(a, b, length, double_int, MINLOC_OP);
   } else if (*datatype == MPI_SHORT_INT) {
     APPLY_FUNC(a, b, length, short_int, MINLOC_OP);
+  } else if (*datatype == MPI_2LONG) {
+    APPLY_FUNC(a, b, length, long_long, MINLOC_OP);
   } else if (*datatype == MPI_2INT) {
     APPLY_FUNC(a, b, length, int_int, MINLOC_OP);
   } else if (*datatype == MPI_LONG_DOUBLE_INT) {
   } else if (*datatype == MPI_2INT) {
     APPLY_FUNC(a, b, length, int_int, MINLOC_OP);
   } else if (*datatype == MPI_LONG_DOUBLE_INT) {
@@ -1493,6 +1495,8 @@ static void maxloc_func(void *a, void *b, int *length,
     APPLY_FUNC(a, b, length, double_int, MAXLOC_OP);
   } else if (*datatype == MPI_SHORT_INT) {
     APPLY_FUNC(a, b, length, short_int, MAXLOC_OP);
     APPLY_FUNC(a, b, length, double_int, MAXLOC_OP);
   } else if (*datatype == MPI_SHORT_INT) {
     APPLY_FUNC(a, b, length, short_int, MAXLOC_OP);
+  } else if (*datatype == MPI_2LONG) {
+    APPLY_FUNC(a, b, length, long_long, MAXLOC_OP);
   } else if (*datatype == MPI_2INT) {
     APPLY_FUNC(a, b, length, int_int, MAXLOC_OP);
   } else if (*datatype == MPI_LONG_DOUBLE_INT) {
   } else if (*datatype == MPI_2INT) {
     APPLY_FUNC(a, b, length, int_int, MAXLOC_OP);
   } else if (*datatype == MPI_LONG_DOUBLE_INT) {