The result is shown below.
I put two counters in speedo_interrupt: one is just before the above
"do{" statement this counts the call-count of speedo_interupt.
another is just after the "inw" statement, for counting the "inw"
instruction.
I split counters for every CPU to eliminate overhead. Result shows
that values are not so varied among CPUs, only few percent difference
observed.
So, I show only the total statistics.
System: Xeon 450MHz x 4, 2MB cache
OS: linux-2.4.0-test1-D (viro patch)
Benchmark: mindcraft WebBench
Speedo interrupt handling frequecy:
speedo_interrupt calls 33.7K/s
"do{}" execution 71.5K/s
These values mean the do{}-loop is executed 2.16 times per function
call.
At that moment, the WebBench transaction speed may be over 3500
tran/s, but I forget to measure the exact value.
Following values are that you requested:
lock aquire 280ns/call
movzwl(inw) 1580ns/call or 750ns/loop
lock release 230ns/call
FYI: 1 CPU clock is 2.2ns@450MHz
lock aquire: if (test_and_set_bit(0, (void*)&sp->in_interrupt)) {
lock release: clear_bit(0, (void*)&sp->in_interrupt);
Huum, "movb" instruction should be applied to exit-lock, again.
Is it enough for you?
-- Computer Systems Laboratory, Fujitsu Labs. kumon@flab.fujitsu.co.jp- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/