JSI Tip 0269 - Set foreground/backround priority in the Windows NT 4.0 registry.

Jerold Schulman

October 5, 1997

1 Min Read
ITPro Today logo

The relative priority of foreground vs background applications can be set my modifying Win32PrioritySeparation at:

HKEY_LOCAL_MACHINESystemCurrentControlSetControlPriorityControlWin32PrioritySeparation

This type REG_DWORD entry defaults to 2 if the value is not present.

Win32PrioritySeparation determines how much processor time the threads of a foreground process receive each time they are scheduled on a Windows NT workstation processor.

 Value 

 Meaning

   0

 Short processor interval.  Foreground threads get the same amount of processor time as background threads which is the same as threads of processes with a priority class of Idle.

   1

 Medium length processor interval.  Foreground processes get more processor time than background processes each time they are scheduled.      

   2

 Long processor interval.  Foreground thread processes get much more processor time than background processes.

On a Windows NT 4.0 Server, the length of processor time each thread gets is longer than on a workstation, but it is fixed. The value of Win32PrioritySeparation is used to calculate a priority boost for foreground processes. The higher the value, the greater the boost.

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like