summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrpj <rpj>2005-05-11 07:18:20 +0000
committerrpj <rpj>2005-05-11 07:18:20 +0000
commit4d142211e3aa40f6714441359a937aec52657606 (patch)
treec97c52fd4627888ed37dbd239bc1eaf28fde4c7f
parent45bb848eea71cdc21662c53916d7af0f7e3be162 (diff)
''
-rw-r--r--tests/stress1.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/stress1.c b/tests/stress1.c
index b8d1c77..68d2ed7 100644
--- a/tests/stress1.c
+++ b/tests/stress1.c
@@ -155,7 +155,8 @@ masterThread (void * arg)
* We are attempting to send the signal close to when the slave
* is due to timeout. We feel around by adding some [non-random] dither.
*
- * with dither added, sleep time range is 2*timeout peak-to-peak centred on timeout,
+ * dither is in the range 2*timeout peak-to-peak
+ * sleep time is the average of timeout plus dither.
* e.g.
* if timeout = 10 then dither = 20 and
* sleep millisecs is: 5 <= ms <= 15
@@ -163,6 +164,8 @@ masterThread (void * arg)
* The bias value attempts to apply some negative feedback to keep
* the ratio of timeouts to signals taken close to 1:1.
* bias changes more slowly than dither so as to average more.
+ *
+ * Finally, if abs(bias) exceeds timeout then timeout is incremented.
*/
if (signalsSent % timeout == 0)
{