Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
More cleanup in contexts' stop().
[simgrid.git] / src / kernel / activity / SynchroIo.cpp
index d09bd1d..7e8ea86 100644 (file)
@@ -5,8 +5,6 @@
 
 #include "src/kernel/activity/SynchroIo.hpp"
 #include "src/simix/smx_private.h"
-#include "src/surf/FileImpl.hpp"
-#include "src/surf/StorageImpl.hpp"
 #include "src/surf/surf_interface.hpp"
 
 void simgrid::kernel::activity::IoImpl::suspend()
@@ -23,36 +21,26 @@ void simgrid::kernel::activity::IoImpl::resume()
 
 void simgrid::kernel::activity::IoImpl::post()
 {
-  for (smx_simcall_t simcall : simcalls) {
+  for (smx_simcall_t const& simcall : simcalls) {
     switch (simcall->call) {
-    case SIMCALL_FILE_OPEN: {
-      surf_file_t tmp = static_cast<simgrid::surf::StorageAction*>(surf_io)->file_;
-      simcall_file_open__set__result(simcall, tmp);
-      break;
-    }
     case SIMCALL_FILE_WRITE:
       simcall_file_write__set__result(simcall, surf_io->getCost());
       break;
-
     case SIMCALL_FILE_READ:
       simcall_file_read__set__result(simcall, surf_io->getCost());
       break;
-
     default:
       break;
     }
   }
 
   switch (surf_io->getState()) {
-
     case simgrid::surf::Action::State::failed:
       state = SIMIX_FAILED;
       break;
-
     case simgrid::surf::Action::State::done:
       state = SIMIX_DONE;
       break;
-
     default:
       THROW_IMPOSSIBLE;
       break;