From: degomme Date: Sun, 29 May 2016 15:50:59 +0000 (+0200) Subject: fix stupid mistake, and stop inserting thousands of sleep(0.0). X-Git-Tag: v3_14~1123 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/a2342f4eeb6b0c4139bdc7258e4397c297992bf0 fix stupid mistake, and stop inserting thousands of sleep(0.0). --- diff --git a/examples/smpi/replay/replay.tesh b/examples/smpi/replay/replay.tesh index 2ef38c6a71..2948da8677 100644 --- a/examples/smpi/replay/replay.tesh +++ b/examples/smpi/replay/replay.tesh @@ -231,8 +231,8 @@ $ ../../smpi_script/bin/smpirun -ext smpi_replay --log=replay.thresh:critical -- > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/model' to 'SMPI' > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/TCP-gamma' to '4194304' > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'smpi/cpu-threshold' to '-1' -> [Jupiter:1:(2) 0.164463] [smpi_replay/VERBOSE] 1 recv 0 1e6 0.164463 > [Tremblay:0:(1) 0.164463] [smpi_replay/VERBOSE] 0 send 1 1e6 0.164463 +> [Jupiter:1:(2) 0.164463] [smpi_replay/VERBOSE] 1 recv 0 1e6 0.164463 > [Jupiter:1:(2) 13.271310] [smpi_replay/VERBOSE] 1 compute 1e9 13.106847 > [Jupiter:1:(2) 13.271310] [smpi_replay/VERBOSE] 1 Isend 0 1e6 0.000000 > [Jupiter:1:(2) 13.271310] [smpi_replay/VERBOSE] 1 Irecv 0 1e6 0.000000 @@ -253,8 +253,8 @@ $ ../../smpi_script/bin/smpirun -ext smpi_replay --log=replay.thresh:critical -- > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/model' to 'SMPI' > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/TCP-gamma' to '4194304' > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'smpi/cpu-threshold' to '-1' -> [Jupiter:1:(2) 1.491472] [smpi_replay/VERBOSE] 1 recv 0 1e7 1.491472 > [Tremblay:0:(1) 1.491472] [smpi_replay/VERBOSE] 0 send 1 1e7 1.491472 +> [Jupiter:1:(2) 1.491472] [smpi_replay/VERBOSE] 1 recv 0 1e7 1.491472 > [Tremblay:0:(1) 1.493448] [smpi_replay/VERBOSE] 0 barrier 0.001976 > [Jupiter:1:(2) 1.494910] [smpi_replay/VERBOSE] 1 barrier 0.003438 > [Fafard:2:(3) 1.495424] [smpi_replay/VERBOSE] 2 barrier 1.495424 @@ -327,9 +327,10 @@ $ ../../smpi_script/bin/smpirun -ext smpi_replay --log=replay.thresh:critical -- > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'network/TCP-gamma' to '4194304' > [0.000000] [xbt_cfg/INFO] Configuration change: Set 'smpi/cpu-threshold' to '-1' > [Tremblay:0:(1) 0.004041] [smpi_replay/VERBOSE] 0 allToAll 500 500 0.004041 -> [Jupiter:1:(2) 0.006920] [smpi_replay/VERBOSE] 1 allToAll 500 500 0.006920 > [Fafard:2:(3) 0.006920] [smpi_replay/VERBOSE] 2 allToAll 500 500 0.006920 -> [Fafard:2:(3) 0.006920] [smpi_replay/INFO] Simulation time 0.006920 +> [Jupiter:1:(2) 0.006920] [smpi_replay/VERBOSE] 1 allToAll 500 500 0.006920 +> [Jupiter:1:(2) 0.006920] [smpi_replay/INFO] Simulation time 0.006920 + $ rm -f replay/one_trace diff --git a/examples/smpi/replay_multiple/replay_multiple.tesh b/examples/smpi/replay_multiple/replay_multiple.tesh index 568cdd6971..2ef20e5c73 100644 --- a/examples/smpi/replay_multiple/replay_multiple.tesh +++ b/examples/smpi/replay_multiple/replay_multiple.tesh @@ -8,8 +8,9 @@ $ ./replay_multiple description_file ${srcdir:=.}/../../platforms/small_platform > [0.000000] [msg_test/INFO] Initializing instance 1 of size 32 > [0.000000] [msg_test/INFO] Initializing instance 2 of size 32 > [0.000000] [smpi_kernel/INFO] You did not set the power of the host running the simulation. The timings will certainly not be accurate. Use the option "--cfg=smpi/running-power:" to set its value.Check http://simgrid.org/simgrid/latest/doc/options.html#options_smpi_bench for more information. -> [Jupiter:2:(52) 1140688.585057] [smpi_replay/INFO] Simulation time 1124371.232395 -> [1140688.585057] [msg_test/INFO] Simulation time 1.14069e+06 +> [Jupiter:2:(52) 1140688.493796] [smpi_replay/INFO] Simulation time 1124371.141124 +> [1140688.493796] [msg_test/INFO] Simulation time 1.14069e+06 + diff --git a/src/smpi/smpi_base.cpp b/src/smpi/smpi_base.cpp index f2f102b0f4..3c01325d1f 100644 --- a/src/smpi/smpi_base.cpp +++ b/src/smpi/smpi_base.cpp @@ -390,7 +390,7 @@ void smpi_mpi_start(MPI_Request request) //integrate pseudo-timing for buffering of small messages, do not bother to execute the simcall if 0 double sleeptime = (request->detached != 0) ? smpi_or(request->size) : 0.0; - if(sleeptime >= 0.0){ + if(sleeptime > 0.0){ simcall_process_sleep(sleeptime); XBT_DEBUG("receiving size of %zu : sleep %f ", request->size, smpi_or(request->size)); } @@ -420,7 +420,7 @@ void smpi_mpi_start(MPI_Request request) sleeptime = ((request->flags & ISEND) != 0)? smpi_ois(request->size) : smpi_os(request->size); } - if(sleeptime >= 0.0){ + if(sleeptime > 0.0){ simcall_process_sleep(sleeptime); XBT_DEBUG("sending size of %zu : sleep %f ", request->size, smpi_os(request->size)); }