On Mon, 1 Dec 2003 21:44:28 +1100, Andrew Bevitt wrote:
>
>Im looking into why the Xserver starts with niceness -1 when started as root.
>Ive tracked the occurance down to these lines in xinit.c 
>#ifdef PRIO_PROCESS
>                setpriority( PRIO_PROCESS, serverpid, -1 );
>#endif
>
>PRIO_PROCESS is a kernel header include which is defined indefintely, so 
>basically the setpriority() call is made whenever the Xserver is initialised.
>If this is done by a normal user niceness will become 0 as a normal user
>cannot set niceness below 0. But as root, well as you can see -1 ...

The X server always runs as root, even when launched by a user.  It's
required for I/O access.

>What I cant figure out is why this is done... ?

GUI responsiveness is critically important.  Nothing makes a system feel
sluggish more than poor mouse response, even if everything else is
blazingly fast.

I think you know this, but just in case, -1 is a HIGHER priority than 0.
--
- Tim Roberts, [EMAIL PROTECTED]
  Providenza & Boekelheide, Inc.


_______________________________________________
Devel mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/devel

Reply via email to