Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Add MPI_Comm_*keyval and MPI_Comm*attr functions
authordegomme <degomme@localhost.localdomain>
Fri, 3 Oct 2014 23:12:39 +0000 (01:12 +0200)
committerdegomme <degomme@localhost.localdomain>
Fri, 3 Oct 2014 23:12:39 +0000 (01:12 +0200)
These are just aliases for MPI*keyval and MPI*attr deprecated functions

src/smpi/smpi_pmpi.c
teshsuite/smpi/mpich3-test/attr/CMakeLists.txt
teshsuite/smpi/mpich3-test/attr/testlist

index 2c7ec2c..a40bccb 100644 (file)
@@ -3001,6 +3001,31 @@ int PMPI_Attr_put(MPI_Comm comm, int keyval, void* attr_value) {
   return smpi_attr_put(comm, keyval, attr_value);
 }
 
+
+int PMPI_Comm_get_attr (MPI_Comm comm, int comm_keyval, void *attribute_val, int *flag)
+{
+  return PMPI_Attr_get(comm, comm_keyval, attribute_val,flag);
+}
+
+int PMPI_Comm_set_attr (MPI_Comm comm, int comm_keyval, void *attribute_val)
+{
+  return PMPI_Attr_put(comm, comm_keyval, attribute_val);
+}
+
+int PMPI_Comm_delete_attr (MPI_Comm comm, int comm_keyval)
+{
+  return PMPI_Attr_delete(comm, comm_keyval);
+}
+
+int PMPI_Comm_create_keyval(MPI_Comm_copy_attr_function* copy_fn, MPI_Comm_delete_attr_function* delete_fn, int* keyval, void* extra_state)
+{
+  return PMPI_Keyval_create(copy_fn, delete_fn, keyval, extra_state);
+}
+
+int PMPI_Comm_free_keyval(int* keyval) {
+  return PMPI_Keyval_free(keyval);
+}
+
 /* The following calls are not yet implemented and will fail at runtime. */
 /* Once implemented, please move them above this notice. */
 
@@ -3112,30 +3137,6 @@ int PMPI_Comm_test_inter(MPI_Comm comm, int* flag) {
   NOT_YET_IMPLEMENTED
 }
 
-int PMPI_Comm_get_attr (MPI_Comm comm, int comm_keyval, void *attribute_val, int *flag)
-{
-  NOT_YET_IMPLEMENTED
-}
-
-int PMPI_Comm_set_attr (MPI_Comm comm, int comm_keyval, void *attribute_val)
-{
-  NOT_YET_IMPLEMENTED
-}
-
-int PMPI_Comm_delete_attr (MPI_Comm comm, int comm_keyval)
-{
-  NOT_YET_IMPLEMENTED
-}
-
-int PMPI_Comm_create_keyval(MPI_Comm_copy_attr_function* copy_fn, MPI_Comm_delete_attr_function* delete_fn, int* keyval, void* extra_state)
-{
-  NOT_YET_IMPLEMENTED
-}
-
-int PMPI_Comm_free_keyval(int* keyval) {
-  NOT_YET_IMPLEMENTED
-}
-
 int PMPI_Pcontrol(const int level )
 {
   NOT_YET_IMPLEMENTED
index a6bd72b..c477207 100644 (file)
@@ -17,15 +17,15 @@ if(enable_smpi AND enable_smpi_MPICH3_testsuite)
   add_executable(attrend2 attrend2.c)
   add_executable(attrend attrend.c)
   add_executable(attrerr attrerr.c)
-#  add_executable(attrerrcomm attrerrcomm.c)
+  add_executable(attrerrcomm attrerrcomm.c)
 #  add_executable(attrerrtype attrerrtype.c)
 #  add_executable(attric attric.c)
   add_executable(attrorder attrorder.c)
-#  add_executable(attrordercomm attrordercomm.c)
+  add_executable(attrordercomm attrordercomm.c)
 #  add_executable(attrordertype attrordertype.c)
   add_executable(attrt attrt.c)
   add_executable(baseattr2 baseattr2.c)
-#  add_executable(baseattrcomm baseattrcomm.c)
+  add_executable(baseattrcomm baseattrcomm.c)
   add_executable(fkeyval fkeyval.c)
 #  add_executable(fkeyvalcomm fkeyvalcomm.c)
 #  add_executable(fkeyvaltype fkeyvaltype.c)
@@ -35,15 +35,15 @@ if(enable_smpi AND enable_smpi_MPICH3_testsuite)
   target_link_libraries(attrend2 simgrid mtest_c)
   target_link_libraries(attrend simgrid mtest_c)
   target_link_libraries(attrerr simgrid mtest_c)
-#  target_link_libraries(attrerrcomm simgrid mtest_c)
+  target_link_libraries(attrerrcomm simgrid mtest_c)
 #  target_link_libraries(attrerrtype simgrid mtest_c)
 #  target_link_libraries(attric simgrid mtest_c)
   target_link_libraries(attrorder simgrid mtest_c)
-#  target_link_libraries(attrordercomm simgrid mtest_c)
+  target_link_libraries(attrordercomm simgrid mtest_c)
 #  target_link_libraries(attrordertype simgrid mtest_c)
   target_link_libraries(attrt simgrid mtest_c)
   target_link_libraries(baseattr2 simgrid mtest_c)
-#  target_link_libraries(baseattrcomm simgrid mtest_c)
+  target_link_libraries(baseattrcomm simgrid mtest_c)
   target_link_libraries(fkeyval simgrid mtest_c)
 #  target_link_libraries(fkeyvalcomm simgrid mtest_c)
 #  target_link_libraries(fkeyvaltype simgrid mtest_c)
index 480ea27..c687935 100644 (file)
@@ -11,20 +11,17 @@ attrerr 1
 #attrend 4
 attrend2 1
 attrend2 5
-#needs MPI_Errhandler_set, MPI_Comm_create_keyval, MPI_Comm_free_keyval, MPI_Comm_set_attr, MPI_Comm_delete_attr
-#attrerrcomm 1
+attrerrcomm 1
 #needs MPI_Errhandler_set, MPI_Type_create_keyval, MPI_Type_dup, MPI_Type_set_attr, MPI_Type_delete_attr
 #attrerrtype 1
 #needs MPI_Type_create_keyval, MPI_Type_dup, MPI_Type_set_attr
 #attr2type 1
 attrorder 1
-#needs MPI_Comm_create_keyval, MPI_Comm_free_keyval, MPI_Comm_get_attr, MPI_Comm_set_attr, MPI_Comm_delete_attr
-#attrordercomm 1
+attrordercomm 1
 #needs MPI_Type_create_keyval, MPI_Type_delete_keyval, MPI_Type_set_attr, MPI_Type_delete_attr
 #attrordertype 1
 baseattr2 1
-#needs MPI_Comm_get_attr
-#baseattrcomm 1
+baseattrcomm 1
 #MPI_Keyval_create, MPI_Keyval_free for type and comm also
 #fkeyval 1
 #fkeyvalcomm 1