Modeling Language for SPIN-Promela

Modeling Language: The modeling language used for SPIN is called Promela (Process Meta Language). In fact, the name SPIN stands for Simple Promela Interpreter. Promela is a powerful C-like specification language with a variety of synchronization primitives that enables construction of models of distributed systems. Promela is a guarded command language for specifying possibly non-deterministic system behaviors in a distributed system design. It allows for the dynamic creation of concurrent processes which communicate synchronously or asynchronously via message channels.

For example, the following Promela specification describes two processes P and Q that synchronize over a critical region.

2110_promela1.jpg

A Promela model consists of declarations of types, channels, variables, and processes, as well as facilities for initializing the processes. For example,

2359_promela2.jpg

A model consists of a set of concurrent processes, each in turn consisting of a set of atomic guarded actions or transitions. An action whose guard is true is called enabled and can be executed; otherwise, it is disabled and cannot be executed. Actions are not really executed concurrently; rather, they are non-deterministically interleaved, and this is used to model concurrency. Also processes do not have to terminate, which is useful when modeling reactive systems.

   Related Questions in Programming Languages

  • Q : Define Inner class Inner class : A

    Inner class: A class defined within an enclosing method or class. We use the word to refer to non-static nested classes.

  • Q : Explain the steps to design product If

    If not in production, how far did you obey the design and why did not you notice it in production?

  • Q : Define the term Scheduler Define the

    Define the term Scheduler: The portion of the Java Virtual Machine (abbreviated as JVM) which is responsible for managing the threads.

  • Q : Define Livelock Livelock : It is a

    Livelock: It is a situation in which a thread waits to be notified of a condition however, on waking, finds that the other thread has inverted the condition another time. The primary thread is forced to wait again. Whenever this occurs for an indefini

  • Q : State the term WSDL State the term WSDL

    State the term WSDL?

  • Q : What are the uses of GPC and GPT What

    What are the uses of GPC and GPT?

  • Q : Explain Relative filename Relative

    Relative filename: It is a filename whose full path is associative to some point within a file system tree-frequently the present working folder (that is, directory). For example:   

  • Q : Write a program and estimate pi using

    Consider a dartboard of radius 1. Since the area of the board will be  π r2 = π * 1 *1, it's clear the area of the dartboard is exactly π. The area of a square surrounding the board (circumscribing it) would be 2*2 = 4, sin

  • Q : Print the factors of each perfect number

    An integer number is said to be a perfect number if its factors, including 1 (but not the number itself), sum to be the number. For example, 6 is a perfect number because 6 = 1+ 2+ 3. Write a function perfect that determines if parameter number is a perfect number. Us

  • Q : Define Race hazard Race hazard : It is

    Race hazard: It is a situation which occurs between multiple threads sharing a resource. The race hazard occurs whenever one thread's suppositions regarding the state of a resource are invalidated by the actions of the other thread.

©TutorsGlobe All rights reserved 2022-2023.