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
Add/update copyright notices.
[simgrid.git]
/
examples
/
msg
/
chord
/
chord.c
diff --git
a/examples/msg/chord/chord.c
b/examples/msg/chord/chord.c
index
2493447
..
8dafba4
100644
(file)
--- a/
examples/msg/chord/chord.c
+++ b/
examples/msg/chord/chord.c
@@
-1,5
+1,4
@@
-
-/* Copyright (c) 2010-2013. The SimGrid Team.
+/* Copyright (c) 2010-2014. The SimGrid Team.
* All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
* All rights reserved. */
/* This program is free software; you can redistribute it and/or modify it
@@
-38,6
+37,8
@@
static int periodic_fix_fingers_delay = 120;
static int periodic_check_predecessor_delay = 120;
static int periodic_lookup_delay = 10;
static int periodic_check_predecessor_delay = 120;
static int periodic_lookup_delay = 10;
+static const double sleep_delay = 4.9999;
+
extern long int smx_total_comms;
/*
extern long int smx_total_comms;
/*
@@
-364,7
+365,7
@@
int node(int argc, char *argv[])
random_lookup(&node);
listen = 1;
}else{
random_lookup(&node);
listen = 1;
}else{
- MSG_process_sleep(
5
);
+ MSG_process_sleep(
sleep_delay
);
if(!MC_visited_reduction())
no_op = 1;
}
if(!MC_visited_reduction())
no_op = 1;
}
@@
-383,7
+384,7
@@
int node(int argc, char *argv[])
next_lookup_date = MSG_get_clock() + periodic_lookup_delay;
}else {
// nothing to do: sleep for a while
next_lookup_date = MSG_get_clock() + periodic_lookup_delay;
}else {
// nothing to do: sleep for a while
- MSG_process_sleep(
5
);
+ MSG_process_sleep(
sleep_delay
);
}
}
}
}