What is the difference between the three priorities used in the Linux kernel?

I am new to the Linux kernel, and now I am studying the planning process in the Linux kernel. There are three types of priorities in Linux:

  • Static priority
  • Dynamic priority
  • Real time priority

Now I realized that:

  • Static priority and dynamic priority are defined only for ordinary processes , and they can take a value from 100 to 139.
  • Static priority is used to determine the main time slice of the process.
  • Dynamic priority is used to select the next process.

  • Real-time priorities are determined only for real-time processes , and this value can vary from 0 to 99

Now my questions are:

  • , , , ,    Linux    ?
  • , 100 139 . ?
  • Linux, , , - ?
+4
1

. Linux ( Windows ). , , .

1. . ( 0 , .. ), . , :

`pthread_setschedparam(pthread_t thread, int policy, const struct sched_param *param);`

, sched_param :

struct sched_param 
{
    int sched_priority;     /* Scheduling priority */
};

2 . , , , , . / (, ) , . Linux .

3. . , () (SCHED_FIFO, SCHED_RR) sched_priority 1 () 99 (). / .

: http://man7.org/linux/man-pages/man3/pthread_getschedparam.3.html

, :

, , , , Linux ?

, , , , , /, .

, 100 139 . ?

, .

Linux, , , ?

, . " " .

+3

Source: https://habr.com/ru/post/1529930/


All Articles