Hi Stes,
On Mar 29, 2020, at 1:16 AM, stes stes@telenet.be wrote:
The manpage for priocntl says that although it is possible to change priority limit for IA (which is the Inter-Active scheduler class), for the TS (TimeSharing) and IA (InterActive) class , it says there is no guarantuee that the change will be used:
"The priorities of processes in the inter-active class can be changed in the same manner as those in the time-sharing
class, though / the modified priorities continue to be adjusted /to provide good responsiveness for user interaction."
For the TS class (similar to IA) it says:
"It is not guaranteed, however, that a time-sharing process with a *higher tsupri value runs before one with a lower tsupri
value*. This is because the tsupri value is just one factor used to determine the scheduling priority of a time-sharing process."
Another choice which also seems to help to get rid of the pthread_setschedparam() error or warning, is to use th FX (fixed priority) class.
So is it recommended to run the squeak process as a process in the RT (realtime) class to get rid of the warning ?
Who knows? The issue here is that we’re not experts in posix thread policies across implementations (apologies to those that are). So by trial and error we find what works. I encourage you to experiment to find out what works. The criteria for success are:
1. a heartbeat thread running at a higher priority than the main vm thread. Verify by creating a process that consumes all cpu and no GC that is terminated by a delay. If the delay fires the heartbeat thread is running, e.g. | proc sem | proc := [| n | n := 0. [(n := n + 1) even ifTrue: [n := n - 1]] repeat] newProcess. sem := Semaphore new. [(Delay forSeconds: 1) wait. proc terminate. sem signal] forkAt: Processor userInterruptPriority. proc resume. sem wait
2. super user permissions are not required to install the vm with whatever posix thread policy works. I.e. we (I) failed with this in Linux because one needed super user permissions to install the relevant file in etc/security.d that is mentioned in the error message when setschedparam fails.
_,,,^..^,,,_ (phone)