@@ -1771,25 +1771,32 @@ Over-allocation on sparse files is entirely ignored on Windows.</para>
17711771
17721772<para ><function >sched_setpolicy</function > only emulates API behavior
17731773because Windows does not offer alternative scheduling policies.
1774- If <literal >SCHED_OTHER</literal > is selected, the Windows priority is
1775- set according to the nice value. If <literal >SCHED_FIFO</literal >
1776- or <literal >SCHED_RR</literal > is selected, the nice value is preserved
1777- and the Windows priority is set according to the
1778- <literal >sched_priority</literal > value.</para >
1774+ If <literal >SCHED_OTHER</literal > or <literal >SCHED_BATCH</literal > is
1775+ selected, the Windows priority is set according to the nice value.
1776+ If <literal >SCHED_IDLE</literal > is selected, the Windows priority is
1777+ set to <literal >IDLE_PRIORITY_CLASS</literal >.
1778+ If <literal >SCHED_FIFO</literal > or <literal >SCHED_RR</literal > is
1779+ selected, the nice value is preserved and the Windows priority is set
1780+ according to the <literal >sched_priority</literal > value.
1781+ If the <literal >SCHED_RESET_ON_FORK</literal > flag is set, realtime
1782+ policies and negative nice values are dropped on
1783+ <function >fork</function >.</para >
17791784
17801785<para ><function >nice</function >, <function >setpriority</function >,
17811786<function >sched_setparam</function > and <function >sched_setpolicy</function >
1782- map the nice value (<literal >SCHED_OTHER</literal >) or the
1783- <literal >sched_priority</literal > (<literal >SCHED_FIFO</literal >,
1784- <literal >SCHED_RR</literal >) to Windows priority classes as follows:</para >
1787+ map the nice value (<literal >SCHED_OTHER</literal >,
1788+ <literal >SCHED_BATCH</literal >) or the <literal >sched_priority</literal >
1789+ (<literal >SCHED_FIFO</literal >, <literal >SCHED_RR</literal >) to Windows
1790+ priority classes as follows:</para >
17851791<screen >
1786- nice value sched_priority Windows priority class
1787- 12...19 1....6 IDLE_PRIORITY_CLASS
1788- 4...11 7...12 BELOW_NORMAL_PRIORITY_CLASS
1789- -4....3 13...18 NORMAL_PRIORITY_CLASS
1790- -12...-5 19...24 ABOVE_NORMAL_PRIORITY_CLASS
1791- -13..-19 25...30 HIGH_PRIORITY_CLASS
1792- -20 31...32 REALTIME_PRIORITY_CLASS
1792+ SCHED_OTHER SCHED_BATCH SCHED_FIFO/RR
1793+ nice value nice value sched_priority Windows priority class
1794+ 12...19 4...19 1....6 IDLE_PRIORITY_CLASS
1795+ 4...11 -4....3 7...12 BELOW_NORMAL_PRIORITY_CLASS
1796+ -4....3 -12...-5 13...18 NORMAL_PRIORITY_CLASS
1797+ -12...-5 -13..-19 19...24 ABOVE_NORMAL_PRIORITY_CLASS
1798+ -13..-19 -20 25...30 HIGH_PRIORITY_CLASS
1799+ -20 - 31...32 REALTIME_PRIORITY_CLASS
17931800</screen >
17941801The use of values which are mapped to the
17951802<literal >REALTIME_PRIORITY_CLASS</literal > require administrative
0 commit comments