4.1.1 Workload Behavior
The workload behavior is built from the functional
model that is specifying the flow of the executed
actions during a certain system mode. Therefore,
workload situations are defined by activity diagram
stereotyped with MARTE «gaWorkloadBehavior»
stereotype. The latter (HadjKacem et al., 2012) is
able to expose the dynamics of a system and depict a
great degree of resemblance to the Petri Nets.
At this level, we focus on the MARTE
annotations applied to the activity diagram. Indeed,
end-to-end real-time constraints (deadline
properties) are specified on transactions, that is,
chains of operation activations enabled by external
stimuli. Each transaction is stereotyped
«saEndtoEndFlow». However, an event (e.g., timers,
internal event and external occurrences) that triggers
the behavior of a system and precedes all the action
is annotated with MARTE «gaWorkloadEvent»
stereotype. Each event is annotated with the property
«arrivalPattern» in order to fix its period. In
addition, any activity/action which represents the
execution of an operation is extended with the
«saStep» stereotype and has an execution time
(execTime property) specified for a given execution
host (host property).
4.1.2 Platform Resources
To this end an abstracted view of the execution
platform resources is assumed to have execution
time estimation for steps. Thus, the processor
resources are represented as components with the
«saExecHost» stereotype, bus resources are with the
«saCommHost» stereotype and platform resources
are stereotyped by «gaPlatformResources». To be
executed, a software resource must obviously be
mapped on processors or busses. Involved shared
resources should also be described.
4.2 Generation of Concurrency Model
In order to generate a concurrency model from a
workload behavior this stage consists of three steps:
(1) Mapping Workload Behavior diagram to Petri
Nets, (2) identify transactions in Petri Nets model
and (3) allocate actions in transactions to threads.
4.2.1 Mapping Workload Behavior Diagram
to Petri Nets
The first step consists in mapping the workload
behavior to Petri Nets formalism. Petri Nets
(Murata, 1989) are formal models based on strict
mathematical theories. They are powerful and
appropriate for modeling and analyzing systems
with parallelization, synchronization and confliction.
The mapping process consists of the deriving
activity diagram elements (nodes, transitions,
signals, actions, and synchronisation bar) and
MARTE annotations into Petri Nets elements. In
that context, several methods (Yang et al., 2010)
(HadjKacem et al., 2012) proposed mapping rules to
enhance formal analysis. In this paper, the rules for
transforming activity diagram elements into Petri
Nets are similar to those proposed in previous
literatures.
4.2.2 Transaction Identification
Once the mapping process is realized, the second
stage consists of determining all transactions in the
nets running in concurrency. A transaction is defined
as a sequence of actions performed in the end-to-end
processing in response to an external event. The
general problem is quite difficult because there are a
high number of transactions that derive all possible
system modes. Thus, to identify all transactions of
an optimized way we propose using the method of
invariants based on Petri Nets formalism.
Place invariant indicates a set of places in which
the number of tokens remains unchanged in all
reachable markings. As a consequence, it
corresponds to a constraint on the states and system
activities that will always be verified, regardless of
its evolutions.
As already mentioned, the solutions of the
equation C
X = 0 are called place invariants (P-
invariants). The solution is called proper if X≠ 0. In
this work we are interested only in proper place
invariants describing all the operations that will be
performed by the same token in only one
transaction. Thus, the set of places p
i
with X
i
> 0,
called the support of the P-invariant, is considered as
only transaction. The execution order of the
operation sequence in a specific transaction is given
by the crossing transitions order.
4.2.3 Generation of the Task Set
After identifying the transactions, it is necessary to
specify the so-called schedulable Resources. These
are units of execution taken into account by the
scheduler of the system, called tasks in scheduling
literature (Radermacher et al., 2010). The task set is
constructed by mapping all actions of the same
transaction to one task i.e. the execution operations
belonging to the place invariants must be assigned to
threads of execution. In fact, we apply a transaction-
NewSchedulabilityAnalysisforReal-TimeSystemsbasedonMDEandPetriNetsModelatEarlyDesignStages
333