BIP -- Incremental Component-based Construction of Real-time Systems
Preemptable tasks sharing CPU's
This is a performance evaluation problem with timed tasks
processing events from a bursty event generator. (Source
http://www.tik.ee.ethz.ch/~leiden05)
The
model is a serial connection of a bursty event generator with three
tasks T1, T2 and T3. T1 and T3 share CPU1 while T2 runs on CPU2 as
shown below.
The atomic components for this model are 'Task' and the 'EventGenerator' and are defined in the example 'Tasks running on dedicated CPU's'.
The compound component 'System' is a serial connection of the EventGenerator and the three instances of Task, T1, T2 and T3 , as shown in the architecture below. Mutual exclusion between T1 and T3 is enforced by the connectors C3, C4, C5 and C6. They guarantee that an executing task will preempt if another task sharing the same CPU has to start. A preempted task can resume only when the executing task finishes. This is shown in the architecture of the System shown below.
BIP
priorities are used to enforce static priorities between T1 and T3
and also to ensure non-preemption of T1 by T3. Running an
execution gives the end-to-end delay of each event processed by the
System, with details of the execution (CPU) time and waiting time.
Here time means the number of 'tick' transitions occurred.
Steps to execute the application:
To generate the C++ code for the application,
$ bipc -f task_b.bip --genC-top System
To compile the application,
$ make -f $BIP_HOME/util/Makefile task_b.bip.x
To run the execution,
$ task_b.bip.x
Ctrl-C to terminate.
Back to examples