[PATCH 2/3] os: Don't limit MaxClients to MAXCLIENTS

Keith Packard keithp at keithp.com
Tue Dec 15 08:55:16 PST 2009


On Tue, 15 Dec 2009 09:32:58 -0500, Adam Jackson <ajax at nwnk.net> wrote:

> Well, not devices, at least not for silken-enabled servers.  But yes.
> And right now, it does; MaxClientFd ends up being getdtablesize()-1,
> which is all the file descriptors you can pass to select.

I was just thinking that 'MaxClientFd' was a confusing name as it's
possible for some non-client fd to be present in the array.

> I considered trying to keep MaxClientFd clamped to the smallest correct
> number in a second patch, but it looks to be literally not worth the
> effort.  I could not measure the difference between MaxClientFd of 1024
> and of 16 in x11perf -noop on a recentish laptop.  Would be interesting
> to know the numbers on a less macho device though.

Yeah, you're really just asking the kernel to discover a bunch of zeros
in the select mask, something which clearly doesn't take a lot of
computrons.

In any case, I'd bet that x11perf -prop or x11perf -pointer would be
better able to detect any difference here; you really want to hammer the
select syscall, and -noop won't end up calling that very often.

-- 
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.x.org/archives/xorg-devel/attachments/20091215/4fb825b9/attachment-0001.pgp 


More information about the xorg-devel mailing list