2003-07-09 23:21:24

by Diego Calleja

[permalink] [raw]
Subject: benchmark: 2.5 io test regression?

Hi. I just went to my 2.5 kernel source tree and i did

#time grep foo * -r

in both 2.4 & 2.5

doing this in 2.4 takes:
real 0m50.614s
user 0m1.150s
sys 0m2.560s

2.5.74-mm3 AS:
real 0m46.207s
user 0m1.156s
sys 0m3.161s

2.5.74-mm3 deadline:
real 0m57.418s
user 0m1.160s
sys 0m3.107s

I repeated the tests and they show very similar numbers. One time 2.4 was faster
than 2.5 with AS.
Hardware is p3 2x800 UDMA 100 7200 rpm 2 MB ide disk, filesystem ext3 (default
mount options). DMA was activated in both 2.4 and 2.5.


Should 2.5 be faster here, or it's the expected behaviour? I'd
have expected a bit more of AS, but perhaps AS it isn't good for
this benchmark?




2003-07-10 03:13:29

by Nick Piggin

[permalink] [raw]
Subject: Re: benchmark: 2.5 io test regression?



Diego Calleja Garc?a wrote:

>Hi. I just went to my 2.5 kernel source tree and i did
>
>#time grep foo * -r
>
>in both 2.4 & 2.5
>
>doing this in 2.4 takes:
>real 0m50.614s
>user 0m1.150s
>sys 0m2.560s
>
>2.5.74-mm3 AS:
>real 0m46.207s
>user 0m1.156s
>sys 0m3.161s
>
>2.5.74-mm3 deadline:
>real 0m57.418s
>user 0m1.160s
>sys 0m3.107s
>
>I repeated the tests and they show very similar numbers. One time 2.4 was faster
>than 2.5 with AS.
>Hardware is p3 2x800 UDMA 100 7200 rpm 2 MB ide disk, filesystem ext3 (default
>mount options). DMA was activated in both 2.4 and 2.5.
>
>
>Should 2.5 be faster here, or it's the expected behaviour? I'd
>have expected a bit more of AS, but perhaps AS it isn't good for
>this benchmark?
>

This test won't exercise the IO scheduler at all - in any kernel.
It only gets 1 read request at a time. Any differences you see
might be due to something happening in the background or just
random variations. If you want to see AS really work, do something
like this in the background, then time your grep.

while true;
do dd if=/dev/zero of=./temp bs=1M count=(the size of your ram);
done


2003-07-10 07:00:13

by Andrew Morton

[permalink] [raw]
Subject: Re: benchmark: 2.5 io test regression?

Diego Calleja Garc?a <[email protected]> wrote:
>
> Hi. I just went to my 2.5 kernel source tree and i did
>
> #time grep foo * -r
>
> in both 2.4 & 2.5

Me too.

ext2. 2.5 kernels had HZ=100, so we can meaningfully compare system and
user times between 2.4 and 2.5.

2.4.22-pre4-SMP:
0.15s user 0.71s system 9% cpu 8.888 total
0.07s user 0.69s system 11% cpu 6.658 total
0.14s user 0.56s system 11% cpu 6.212 total
0.18s user 0.60s system 11% cpu 6.944 total

Average: 0.64 7.18

2.5.74-mm3-SMP:
0.10s user 0.58s system 11% cpu 6.060 total
0.08s user 0.54s system 10% cpu 6.009 total
0.13s user 0.55s system 11% cpu 6.085 total
0.11s user 0.49s system 10% cpu 5.858 total

Average: 0.54 6.00



2.4.22-pre4-UP:
0.11s user 0.60s system 10% cpu 6.733 total
0.22s user 0.60s system 12% cpu 6.683 total
0.12s user 0.58s system 8% cpu 8.408 total
0.17s user 0.65s system 8% cpu 9.544 total

Average: 0.61 7.84

2.5.74-mm3-UP:
0.11s user 0.45s system 7% cpu 7.431 total
0.19s user 0.46s system 10% cpu 6.354 total
0.19s user 0.51s system 8% cpu 8.197 total
0.09s user 0.59s system 9% cpu 6.842 total

Average: 0.50 7.21


Modest but nice improvements in both system time and elapsed time.

I suspect that more than four runs was needed, really.