A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
use get_unique_data()
[simgrid.git]
/
examples
/
cpp
/
task-storm
/
s4u-task-storm.cpp
diff --git
a/examples/cpp/task-storm/s4u-task-storm.cpp
b/examples/cpp/task-storm/s4u-task-storm.cpp
index
98575d0
..
7c02415
100644
(file)
--- a/
examples/cpp/task-storm/s4u-task-storm.cpp
+++ b/
examples/cpp/task-storm/s4u-task-storm.cpp
@@
-107,14
+107,12
@@
int main(int argc, char* argv[])
and use it to adapt their amount of work to do.
*/
B1->on_this_start_cb([&](simgrid::plugins::Task* t) {
and use it to adapt their amount of work to do.
*/
B1->on_this_start_cb([&](simgrid::plugins::Task* t) {
- auto data = t->get_next_token_from(SA_to_B1)->get_data<double>();
+ auto data = t->get_next_token_from(SA_to_B1)->get_
unique_
data<double>();
t->set_amount(*data * 10);
t->set_amount(*data * 10);
- delete data;
});
B2->on_this_start_cb([&](simgrid::plugins::Task* t) {
});
B2->on_this_start_cb([&](simgrid::plugins::Task* t) {
- auto data = t->get_next_token_from(SA_to_B2)->get_data<double>();
+ auto data = t->get_next_token_from(SA_to_B2)->get_
unique_
data<double>();
t->set_amount(*data * 10);
t->set_amount(*data * 10);
- delete data;
});
// Enqueue executions for tasks without predecessors
});
// Enqueue executions for tasks without predecessors