On Fri, Jun 18, 2010 at 11:35:18AM -0700, Michael Davidson wrote:
> Yes - on some Intel platforms the roundtrip time can be as much as 1800
> clock
> cycles - with the default test threshold of 500 cycles that always fails the
> "roundtrip > 2 * threshold" test and we exit the loop without ever having
> updated
> the delta value.
>
> Note that the actual deta on those platforms is only a few tens of cycles.
>
> Most importantly, on looking more closely at the code that was added in
> this change, it really doesn't do anything useful.(other than cause the test
> to fail on platforms where the roundtrip time his high, even if the measured
>
> delta is low). It isn't as if doing a continue at that point will give you
> another
> shot at running the test - the loop executes a fixed number of times and
> sets the result base on the "best" roundtrip time - continuing the loop
> early
> if the roundtrip time is large is pointless.
>
The first problem is that the patch was not applied in the way I sent.
I sent:
- for (i = 0; i < NUM_ITERS; i++) {
+ while (i < NUM_ITERS) {
...
+ i++;
This would guarantee that if a high roundtrip was found, we would not
count this as a valid execution. This is very different from what it is
in the repository right now, which is clearly wrong.
Other than thta, if there is a platform where 2 * threshold is so common,
maybe we can change it to something bigger (maybe 5?). My main point was to
rule out
scheduling issues in userspace. When they happen, they are likely to be quite
big.
_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest