[PATCH xserver 01/20] Remove non-smart scheduler. Don't require setitimer.
Adam Jackson
ajax at nwnk.net
Tue Nov 17 12:10:50 PST 2015
On Wed, 2015-11-11 at 22:02 -0800, Keith Packard wrote:
> This allows the server to call GetTimeInMillis() after each request is
> processed to avoid needing setitimer. -dumbSched now turns off the
> setitimer.
I'm not sure there are real systems we'd be protecting by not requiring
setitimer. But, at least on my Ivybridge, this only dings noop
performance by like 1% when using -dumbSched. Probably this would be
worse on non-vdso setups, but anyone with both of those problems is
already in pretty bad shape.
Would also be nice to see doc/smartsched updated to reflect reality,
I'll take a crack at that.
> +#if HAVE_SETITIMER
> if (SmartScheduleEnable() < 0) {
> perror("sigaction for smart scheduler");
> - SmartScheduleDisable = TRUE;
> + SmartScheduleSignalEnable = FALSE;
> }
> +#endif
> }
I have a slight preference for doing like this in the header:
#ifndef HAVE_SETITIMER
#define SmartScheduleEnable() 0
#endif
> +#if HAVE_SETITIMER
> if (SmartSchedulePause() < 0) {
> close(pdes[0]);
> close(pdes[1]);
... same. A bit cosmetic I suppose.
- ajax
More information about the xorg-devel
mailing list