From: Martin Quinson Date: Mon, 15 May 2017 08:43:10 +0000 (+0200) Subject: LOOPAFTER is a better name for profile periodicity X-Git-Tag: v3.16~274^2~12^2 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/493bed9137a39c3f003dc66605fc264d9532c336 LOOPAFTER is a better name for profile periodicity --- diff --git a/doc/doxygen/howtos.doc b/doc/doxygen/howtos.doc index 42d1459bf0..a764b7af8f 100644 --- a/doc/doxygen/howtos.doc +++ b/doc/doxygen/howtos.doc @@ -35,7 +35,7 @@ the form "date value". Example: ~~~{.py} 1 0 2 1 - WAITFOR 8 + LOOPAFTER 8 ~~~ - At time t=1, the host is turned off (value 0 means OFF) @@ -43,7 +43,7 @@ the form "date value". Example: - At time t=10, the history is reset (because that's 8 seconds after the last event). So the host will be turned off again at t=11. -If your trace does not contain a WAITFOR line, then your profile is +If your trace does not contain a LOOPAFTER line, then your profile is only executed once and not repetitively. @section howto_multicore How to model multicore machines diff --git a/examples/platforms/trace/link1_avail.trace b/examples/platforms/trace/link1_avail.trace index 86c68acb7f..fd47a867c8 100644 --- a/examples/platforms/trace/link1_avail.trace +++ b/examples/platforms/trace/link1_avail.trace @@ -1,3 +1,3 @@ 2 62500000 4 31250000 -WAITFOR 6 +LOOPAFTER 6 diff --git a/examples/platforms/trace/linkBandwidth7.bw b/examples/platforms/trace/linkBandwidth7.bw index 25ccce53e2..5320d5d753 100644 --- a/examples/platforms/trace/linkBandwidth7.bw +++ b/examples/platforms/trace/linkBandwidth7.bw @@ -2,5 +2,5 @@ 4.199387092709633 1.0335587797993976E8 5.319464737378834 1.0591433767387845E7 7.237437222882919 7.037797434537312E7 -WAITFOR 0.76256277712 +LOOPAFTER 0.76256277712 # Wait until t=8 diff --git a/examples/platforms/trace/trace_A.txt b/examples/platforms/trace/trace_A.txt index 9487874709..78c04c4973 100644 --- a/examples/platforms/trace/trace_A.txt +++ b/examples/platforms/trace/trace_A.txt @@ -1,4 +1,4 @@ 0 1.0 11 0.5 20 0.9 -WAITFOR 1 +LOOPAFTER 1 diff --git a/examples/platforms/trace/trace_A_failure.txt b/examples/platforms/trace/trace_A_failure.txt index a32f277fec..417b7c651c 100644 --- a/examples/platforms/trace/trace_A_failure.txt +++ b/examples/platforms/trace/trace_A_failure.txt @@ -1,3 +1,3 @@ 1 -1.0 2 1.0 -WAITFOR 8 +LOOPAFTER 8 diff --git a/examples/platforms/trace/trace_B.txt b/examples/platforms/trace/trace_B.txt index ba0b41d85d..38da833473 100644 --- a/examples/platforms/trace/trace_B.txt +++ b/examples/platforms/trace/trace_B.txt @@ -1,4 +1,4 @@ 0 1.0 10 0.8 20 0.4 -WAITFOR 10 +LOOPAFTER 10 diff --git a/src/surf/surf_c_bindings.cpp b/src/surf/surf_c_bindings.cpp index 82071001ec..85582c57e4 100644 --- a/src/surf/surf_c_bindings.cpp +++ b/src/surf/surf_c_bindings.cpp @@ -28,9 +28,8 @@ void surf_presolve() break; while ((event = future_evt_set->pop_leq(next_event_date, &value, &resource))) { - if (value >= 0){ + if (value >= 0) resource->apply_event(event, value); - } } } diff --git a/src/surf/trace_mgr.cpp b/src/surf/trace_mgr.cpp index a67c7d437c..d8ea885173 100644 --- a/src/surf/trace_mgr.cpp +++ b/src/surf/trace_mgr.cpp @@ -77,7 +77,7 @@ tmgr_trace_t tmgr_trace_new_from_string(const char* name, std::string input, dou continue; if (sscanf(val.c_str(), "PERIODICITY %lg\n", &periodicity) == 1) continue; - if (sscanf(val.c_str(), "WAITFOR %lg\n", &periodicity) == 1) + if (sscanf(val.c_str(), "LOOPAFTER %lg\n", &periodicity) == 1) continue; xbt_assert(sscanf(val.c_str(), "%lg %lg\n", &event.date_, &event.value_) == 2, "%s:%d: Syntax error in trace\n%s", diff --git a/src/surf/trace_mgr_test.cpp b/src/surf/trace_mgr_test.cpp index 30c53c6ef8..4b81b68863 100644 --- a/src/surf/trace_mgr_test.cpp +++ b/src/surf/trace_mgr_test.cpp @@ -113,7 +113,7 @@ BOOST_AUTO_TEST_CASE(two_evt_loop) std::vector got; trace2vector("1.0 1.0\n" "3.0 3.0\n" - "WAITFOR 2\n", + "LOOPAFTER 2\n", &got); std::vector want; @@ -133,7 +133,7 @@ BOOST_AUTO_TEST_CASE(two_evt_start0_loop) std::vector got; trace2vector("0.0 1\n" "5.0 2\n" - "WAITFOR 5\n", + "LOOPAFTER 5\n", &got); std::vector want; diff --git a/teshsuite/simdag/platforms/bob.trace b/teshsuite/simdag/platforms/bob.trace index 053f1e5727..af700d071f 100644 --- a/teshsuite/simdag/platforms/bob.trace +++ b/teshsuite/simdag/platforms/bob.trace @@ -1,4 +1,4 @@ 0 1.0 11 0.5 20 0.8 -WAITFOR 1 +LOOPAFTER 1 diff --git a/teshsuite/simdag/platforms/carol.fail b/teshsuite/simdag/platforms/carol.fail index f5b00f264b..6d895868c8 100644 --- a/teshsuite/simdag/platforms/carol.fail +++ b/teshsuite/simdag/platforms/carol.fail @@ -1,3 +1,3 @@ 1 -1.0 2 1.0 -WAITFOR 10 +LOOPAFTER 10 diff --git a/teshsuite/simdag/platforms/erin.avail b/teshsuite/simdag/platforms/erin.avail index b74fe35493..4c7378ecc6 100644 --- a/teshsuite/simdag/platforms/erin.avail +++ b/teshsuite/simdag/platforms/erin.avail @@ -1,4 +1,4 @@ 0 1.0 9 0.7 15 0.4 -WAITFOR 1 +LOOPAFTER 1 diff --git a/teshsuite/simdag/platforms/link.bw b/teshsuite/simdag/platforms/link.bw index f858489c22..c91df60250 100644 --- a/teshsuite/simdag/platforms/link.bw +++ b/teshsuite/simdag/platforms/link.bw @@ -1,3 +1,3 @@ 4 40000000 8 60000000 -WAITFOR 12 +LOOPAFTER 12 diff --git a/teshsuite/simdag/platforms/link.fail b/teshsuite/simdag/platforms/link.fail index ee22219029..3bee23b85d 100644 --- a/teshsuite/simdag/platforms/link.fail +++ b/teshsuite/simdag/platforms/link.fail @@ -1,3 +1,3 @@ 1 -1.0 2 1.0 -WAITFOR 10 +LOOPAFTER 10 diff --git a/teshsuite/simdag/platforms/link.lat b/teshsuite/simdag/platforms/link.lat index 5e2eb9a776..d447a89dbf 100644 --- a/teshsuite/simdag/platforms/link.lat +++ b/teshsuite/simdag/platforms/link.lat @@ -1,4 +1,4 @@ 1 0.001 2 0.01 3 0.001 -WAITFOR 5 +LOOPAFTER 5