]> AND Public Git Repository - simgrid.git/blobdiff - src/smpi/include/smpi_file.hpp
Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
checks for PMPI_Type_create_subarray
[simgrid.git] / src / smpi / include / smpi_file.hpp
index 17969e59d6a255e5366d54c84b59e72603d254d6..1d7360545fa2104a7e83053ad1f1f6c3e97c895f 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2010-2020. The SimGrid Team.
+/* Copyright (c) 2010-2021. The SimGrid Team.
  * All rights reserved.                                                     */
 
 /* This program is free software; you can redistribute it and/or modify it
@@ -49,6 +49,7 @@ class File : public F2C{
   int get_view(MPI_Offset* disp, MPI_Datatype* etype, MPI_Datatype* filetype, char* datarep) const;
   MPI_Info info();
   void set_info( MPI_Info info);
+  void set_size(int size);
   static int read(MPI_File fh, void* buf, int count, const Datatype* datatype, MPI_Status* status);
   static int read_shared(MPI_File fh, void* buf, int count, const Datatype* datatype, MPI_Status* status);
   static int read_ordered(MPI_File fh, void* buf, int count, const Datatype* datatype, MPI_Status* status);
@@ -103,7 +104,8 @@ int File::op_all(void* buf, int count, const Datatype* datatype, MPI_Status* sta
   XBT_CDEBUG(smpi_pmpi, "my offsets to read : %lld:%lld, global min and max %lld:%lld", min_offset, max_offset, min,
              max);
   if (empty == 1) {
-    status->count = 0;
+    if (status != MPI_STATUS_IGNORE)
+      status->count = 0;
     return MPI_SUCCESS;
   }
   MPI_Offset total = max - min;