Re: click userland patches for large speed improvements
Luigi Rizzo <rizzo <at> iet.unipi.it>
2011-07-02 09:48:30 GMT
On Fri, Jul 01, 2011 at 11:13:45AM -0700, Eddie Kohler wrote:
> Hi Roman,
> I believe Luigi generally tests on a FreeBSD version, and the FreeBSD malloc
> appears particularly slow compared to current Linux versions. But Luigi's
> patches are AWESOME and will be integrated soon, with adjustments. Any help
> appreciated!! THANKS LUIGI!!!
> Luigi, have you done github?
correct, i am developing/testing on FreeBSD and click 1.8.0.
Will try github next week.
The 0.5Mpps figure is dominated by timestamps, which, with the default
configuration on freebsd, are incredibly expensive (800ns to run gettimeofday;
clock_gettime is faster, around 400ns, but click does not use it anyways).
I don't know how cheap is access to timestamps in linux , but certainly it
would make sense to have a run-time option to use, say, TSC or jiffies
as the internal representation (accessible without a syscall)
and convert to sec/usec/nsec only when the value is actually used.
Of course to use TSC you need constant_tsc, and for jiffies you need
an OS that exports the value in a readonly page to all userland threads.