Real-Time Scheduling of Software Tasks
Lawrence T. Hoff
RHIC project, BNL
When designing real-time systems, it is often desirable to schedule execution
of software tasks based on the occurrence of events. The events may be clock
ticks, interrupts from a hardware device, or software signals from other
software tasks. If the nature of the events is well understood, this scheduling
is normally a static part of the system design. If the nature of the events is
not completely understood, or is expected to change over time, it may be
necessary to provide a mechanism for adjusting the scheduling of the software
tasks.
RHIC front-end computers (FECs) provide such a mechanism. The goals in
designing this mechanism were to be as independent as possible of the
underlying operating system, to allow for future expansion of the mechanism to
handle new types of events, and to allow easy configuration. Some
considerations which steered the design were programming paradigm (object
oriented vs. procedural), programming language, and whether events are merely
interesting moments in time, or whether they intrinsically have data associated
with them. The design also needed to address performance and robustness
tradeoffs involving shared task contexts, task priorities, and use of interrupt
service routine (ISR) contexts vs. task contexts. This paper will explore these
considerations and tradeoffs.