Re: building async-calls

From: Amos Jeffries <squid3@dont-contact.us>
Date: Mon, 17 Dec 2007 13:52:28 +1300 (NZDT)

> On Sun, Dec 16, 2007, Tsantilas Christos wrote:
>
>> > Have you benchmarked what that'll do to performance? :)
>>
>> Maybe has some performance penalty. But if there is a performance
>> decrease, I do not think that it is huge.
>> Normally creating a class is not more costly than creating a C struct
>> and initialize it. The AsyncCall classes are very simple classes.
>
> Well, the previous C comm loop code didn't create a C struct and
> initialise it. That was the whole point. :)
>
>> Moreover, I believe with current design you are loosing more in
>> performance, trying to prevent problems adding extra code for tests or
>> workarounds.
>
> I suggest just benchmarking it under high transaction load (ie,
> which pegs the CPU 100%) and see where the CPU is going.
> You'll see the memory allocator taking up quite a bit of CPU
> time. Remove the low-hanging fruit which will be eliminated with
> a few easy changes (headersEnd() taking loads of CPU, memcpy(),
> memset()) and if its anything like what I saw before you'll see
> the allocator taking up more CPU than is fair..
>
> Adrian
>

Adrian, I've tried to do some profiling myself recently but am stuck
getting those nice stats you post out of it. (Last time I did profiling
was in VisualStudio).

Could you send me or the list a how-to on using the cpu-profiling feature,
from enable to viewing stats please?

Amos
Received on Sun Dec 16 2007 - 17:52:31 MST

This archive was generated by hypermail pre-2.1.9 : Mon Dec 31 2007 - 12:00:03 MST