Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
smx: synchro->suspend() and synchro->resume() as proper methods
[simgrid.git] / src / simix / SynchroComm.cpp
1 /* Copyright (c) 2007-2016. The SimGrid Team. All rights reserved.          */
2
3 /* This program is free software; you can redistribute it and/or modify it
4  * under the terms of the license (GNU LGPL) which comes with this package. */
5
6 #include "src/simix/SynchroComm.hpp"
7 #include "src/surf/surf_interface.hpp"
8
9 void simgrid::simix::Comm::suspend() {
10   /* FIXME: shall we suspend also the timeout synchro? */
11   if (surf_comm)
12     surf_comm->suspend();
13   /* in the other case, the action will be suspended on creation, in SIMIX_comm_start() */
14
15 }
16
17 void simgrid::simix::Comm::resume() {
18   /*FIXME: check what happen with the timeouts */
19   if (surf_comm)
20     surf_comm->resume();
21   /* in the other case, the synchro were not really suspended yet, see SIMIX_comm_suspend() and SIMIX_comm_start() */
22 }