23.08.2013 Views

Specification of Reactive Hardware/Software Systems - Electronic ...

Specification of Reactive Hardware/Software Systems - Electronic ...

Specification of Reactive Hardware/Software Systems - Electronic ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

294 Process Part <strong>of</strong> POOSL<br />

distributed system is able to direct a message towards some specific other process by<br />

naming it. This process will only receive a message if this message is actually meant for<br />

it. A typical other characteristic <strong>of</strong> weakly distributed systems is that names <strong>of</strong> processes<br />

in weakly distributed systems can be passed from one process to another. This means<br />

that the network <strong>of</strong> process acquaintances can change during the lifetime <strong>of</strong> a system.<br />

Previous versions <strong>of</strong> POOSL [Voe94, Voe95a]) did not have the expressive power to<br />

model weakly distributed systems. The solution to this problem was obtained when<br />

message-receive statements ch?m(p1 ¥¡ ¡ ¡ ¥ pm) were generalised by extending them with<br />

reception conditions. Using these reception conditions, weakly distributed systems can<br />

be modelled by supplying each process object with a unique process identifier. Process<br />

identifiers are modelled by data objects. Therefore identities can be passed from one<br />

process to another. The sending <strong>of</strong> a message m (on channel ch) to a process with identifier<br />

id can be expressed by statement ch!m(id). The corresponding conditional messagereceive<br />

statement is then <strong>of</strong> the form ch?m(i ¡ i id). It states that the process with<br />

identifier id is willing to receive message m from channel ch only if message parameter i<br />

equals id.<br />

It is interesting to note that conditional message reception is not only applicable for the<br />

modelling <strong>of</strong> message passing based on process identifiers. The primitive can for example<br />

also be used to model processes with priorities. This example clearly shows how<br />

complex the relation between language primitives and method concepts can be. The<br />

reception condition primitive enables the expression <strong>of</strong> the concept weak distribution as<br />

well as the concept <strong>of</strong> priorities. The primitive is however not sufficient to model these<br />

concepts. Other primitives such as message-receive statements and data expressions are<br />

also required.<br />

The replacement <strong>of</strong> message-receive statements by conditional message receive statements<br />

had a great impact on the semantics that had been developed till then. More<br />

about this is explained in the next subsection.<br />

9.7.3 Layers <strong>of</strong> Semantics<br />

The semantics <strong>of</strong> POOSL consists <strong>of</strong> two layers. At the layer <strong>of</strong> data objects, data expressions<br />

and data statements may take lots <strong>of</strong> small steps to be evaluated respectively<br />

executed. At the layer <strong>of</strong> process objects, these small steps are abstracted from and combined<br />

into single steps. In this subsection we will explain why we decided to build the<br />

semantics this way. For an alternative would have been to consider only one semantic<br />

layer and to formalise this layer by a single labeled-transition system.<br />

Consider guarded command § E S p whose execution is given by rule (e’) <strong>of</strong> Subsection<br />

9.5.3:

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!