On the other hand, V&V can encounter in few
cases, especially with model-based formal methods,
some difficulties like the State Explosion Problem for
instance. When the system grows up, the size of the
state space exponentially also grows. Even model
cheking tools like SPIN are able to verify models
with 10
120
states thanks to the use of Binary Decision
Diagrams (BDD) for the representation of the state
space (Miller et al., 2010), these verification tools do
not fit to bigger systems. Formal verification can not
apparently likewise verify systems with an uncount-
ably infinite state space in practice. For these cases,
simulation approach could be a very interesting com-
plementary approach to the verification tools, espe-
cially as FDDEVS supports both verification and sim-
ulation.
Due to the fact that there are many various tech-
niques used in each of these disciplines, we only fo-
cus here on two formalisms, in order to validate our
approach: FDDEVS (Hwang and Zeigler, 2006a) and
PROMELA (Holzmann, 2004). One must keep in
mind that the approach which we want to develop
does not depend on the choice of the formalisms. Fi-
nite and Deterministic Discrete Event-system Speci-
fication (FDDEVS) is a subclass of DEVS problem,
which is used to describe, model and simulate dis-
crete event systems. Discrete Event Systems (Zeigler,
1976) are those whose the evaluation of their current
state is done at some specific points in the time, called
events. Across that, PROMELA is especially used to
describe, model and verify asynchronous and concur-
rent systems. In these terms, reader can think that
the case studies concerned with one or the other of
these languages, and the goals of these two domains
are totally disconnected. Moreover, it is legitimate
to ask how simulation could bring something to ver-
ification: indeed, the simulation is by nature an em-
pirical method while the verification is an exhaustive
method.
We will then introduce here a way to transform
PROMELA models into FDDEVS models through
one example, and show why using a simulation ap-
proach could be beneficial for formal methods in
some cases, before speaking about the possible con-
tributions of such a method for both domains.
3 VERIFICATION OF THE
DEKKER’S ALGORITHM
In this paper, we will exclusively handle our problem
through one example which is representative of clas-
sic problems concerned by V&V and model-based
formal methods. Our work introduced in this paper
is thus based on the problem of mutual exclusion, and
especially its resolution by the Dekker’s algorithm.
3.1 The Dekker’s Algorithm of the
Mutual Exclusion Problem
The Dekker’s algorithm of mutual exclusion was in-
troduced in 1965 by Theodorus Dekker, according to
Dijkstra (Dijkstra, 2002). This is the first and a rel-
atively simple solution for a well-known problem in
concurrent systems: the mutual exclusion that allows
two processes accessing a shared critical resource.
The algorithm for a process p considers two vari-
ables b
p
, b
q
, and a flag k. The two first boolean vari-
ables indicate whether processes p and q want to ac-
cess to the critical resource or not. If both of them
wish to reach the resource, the flag k acts as a referee
and indicates which of them can immediately have
the resource. Then, the process, which is forbidden
to enter the critical section, turns his willingness flag
to false and enters active waiting while the other pro-
cess enters the critical section. At the end, the pro-
cess, which had the resource in this turn, sets the flag
k to the value of the other process, that guarantees the
fairness property which ensures processes are fairly
executed.
3.2 Verification by Model-checking
Model-checking is a model-based formal
method (Huth and Ryan, 2000) in which the
considered system is described as a state transition
system M used by the model-checker to verify if
M φ, where φ is a set of properties expressed
in a temporal logic. Among all model-checking
languages, our work is focusing on PROMELA
language introduced by Holzmann (Holzmann,
1997) (Holzmann, 2004). PROMELA was especially
designed to verify dynamic concurrent systems,
which are then translated into non-deterministic
automata. Properties which must be verified are
expressed in Linear Temporal Logic (LTL) before
being translated into B
¨
uchi Automata. The SPIN
model-checker performs verification on these two
final models. Moreover, the SPIN model-checker can
also operate as a simulator, which allows us making a
good comparison between this tool and our approach
with the FDDEVS simulator.
The PROMELA implementation of the Dekker’s
algorithm (given in Program 1) is very natural, thanks
to the characteristics of the language. Processes are
expressed as proctype blocks, and communication
between both of them is done through global variables
wantp, wantq and turn, which respectively represent
SIMULTECH2014-4thInternationalConferenceonSimulationandModelingMethodologies,Technologiesand
Applications
422