Important: |
---|
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist. |
As a preemptive multitasking operating system, Windows CE bases preemption solely on the priority of the thread; that is, Windows CE schedules threads with a higher priority to run first. Threads at the same priority level run in a circular fashion with each thread receiving a quantum, or slice of execution time. The quantum has a default value of 100 milliseconds, and is set by the OEM in the OAL. The quantum value set by the OEM is constant throughout the operating system.
The Windows CE 3.0 enables an application to set the quantum on a thread by thread basis. This means that you can adapt the scheduler to the current needs of your application. To adjust the time quantum, Windows CE provides two new functions: CeGetThreadQuantumand CeSetThreadQuantum. CeGetThreadQuantumenables you to receive the quantum for a specified thread, while CeSetThreadQuantumlets you set the quantum for a thread.
Last updated on Tuesday, May 18, 2004