lkml.org 
[lkml]   [2002]   [Aug]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [PATCH] Rmap speedup
    Date
    Wait a second guys, the problem is with the script, look at those CPU
    numbers:

    > ./daniel.sh 39.78s user 71.72s system 368% cpu 30.260 total
    > quad:/home/akpm> time ./daniel.sh
    > ./daniel.sh 38.45s user 70.00s system 365% cpu 29.642 total

    They should be 399%!! With my fancy script, the processes themselves are
    getting serialized somehow.

    Lets back up and try this again with this pair of scripts, much closer to
    the original:

    doitlots:
    -------------------------------
    #!/bin/sh

    doit()
    {
    ( cat $1 | wc -l )
    }

    count=0

    while [ $count != 500 ]
    do
    doit doitlots > /dev/null

    count=$(expr $count + 1)
    done
    echo done
    -------------------------------


    forklots:
    -------------------------------
    echo >foocount
    ./doitlots >>foocount &
    ./doitlots >>foocount &
    ./doitlots >>foocount &
    ./doitlots >>foocount &
    ./doitlots >>foocount &
    ./doitlots >>foocount &
    ./doitlots >>foocount &
    ./doitlots >>foocount &
    ./doitlots >>foocount &

    count=0

    while [ $count != 10 ]
    do
    count=$(wc foocount | cut -b -8)
    done
    -------------------------------

    /me makes the sign of the beast at bash

    --
    Daniel
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:27    [W:0.023 / U:182.660 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site