Increase priority of unresponsive threads.

The VM uses a safe-pointing thread suspension mechanism, which currently
means that the GC can't do its work until the various threads enter a
non-running state.  This can be a problem if a low-priority thread was
scheduled out and other processes in the system are running flat out.

This changes the "spin on suspend" mechanism to increase the priority of
unresponsive threads.  Currently we just boost the "nice" value, since
that seems to be enough to do the trick in my tests, but we may have to
shift the cgroup around as well (assuming other recent changes don't
simply render this unnecessary).
1 file changed