• Aucun résultat trouvé

On the Expressiveness of Linearity vs Persistence in the Asychronous Pi-Calculus

N/A
N/A
Protected

Academic year: 2021

Partager "On the Expressiveness of Linearity vs Persistence in the Asychronous Pi-Calculus"

Copied!
11
0
0

Texte intégral

(1)

HAL Id: inria-00201096

https://hal.inria.fr/inria-00201096

Submitted on 23 Dec 2007

HAL is a multi-disciplinary open access archive for the deposit and dissemination of sci- entific research documents, whether they are pub- lished or not. The documents may come from teaching and research institutions in France or abroad, or from public or private research centers.

L’archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d’enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.

On the Expressiveness of Linearity vs Persistence in the Asychronous Pi-Calculus

Catuscia Palamidessi, Vijay Saraswat, Frank Valencia, Bjorn Victor

To cite this version:

Catuscia Palamidessi, Vijay Saraswat, Frank Valencia, Bjorn Victor. On the Expressiveness of Linear- ity vs Persistence in the Asychronous Pi-Calculus. Twenty First Annual IEEE Symposium on Logic in Computer Science (LICS), Aug 2006, Seattle, United States. pp.59-68, �10.1109/LICS.2006.39�.

�inria-00201096�

(2)

On the Expressiveness of Linearity vs Persistence in the Asychronous Pi-Calculus

Catuscia Palamidessi

INRIA and LIX ´Ecole Polytechnique catuscia@lix.polytechnique.fr

Vijay Saraswat

IBM TJ Watson Research Lab vijay@saraswat.org Frank D. Valencia

CNRS and LIX ´Ecole Polytechnique frank.valencia@lix.polytechnique.fr

Bj¨orn Victor

Dept. of Information Technology, Uppsala Univ.

bjorn.victor@it.uu.se

Abstract

We present an expressiveness study of linearity and per- sistence of processes. We choose the π-calculus, one of the main representatives of process calculi, as a framework to conduct our study. We consider four fragments of the π-calculus. Each one singles out a natural source of lin- earity/persistence also present in other frameworks such as Concurrent Constraint Programming (CCP), Linear CCP, and several calculi for security. The study is presented by providing (or proving the non-existence of) encodings among the fragments, a processes-as-formulae interpreta- tion and a reduction from Minsky machines.

1 Introduction

Several process calculi such as CCS, CSP, theπ-calculus [15] and Linear CCP [8, 23] have an obvious source of lin- earity: Messages (or senders) are consumed upon being re- ceived. For example, in theπ-calculus, the system

xhzi | x(y).P | x(y).Q (1) represents a message with a datumz, tagged withx, that can be consumed by either x(y).P orx(y).Q. The sys- tem can evolve into either (a) P{z/y} | x(y).Q or (b) x(y).P | Q{z/y}.

Nevertheless, there are other process calculi which fol- low a different pattern: Messages cannot be consumed; they are persistent rather than linear. One of the most promi- nent representatives of such calculi is Concurrent Constraint Programming (CCP) [22]. In this framework all messages, more precisely items of information, are accumulated in a global store. The messages in the store can be read but, un- like in Linear CCP, they cannot be consumed, i.e., the store is persistent.

Several other frameworks using a persistent store can be found in the context of calculi for analyzing and describing security protocols. For instance, Crazzolara and Winskel’s SPL [7], the Spi Calculus variants by Fiore and Abadi [9]

and by Amadio et al [1], and the calculus of Boreale and Buscemi [4] are all operationally defined in terms of config- urations containing items of information (messages) which cannot be consumed during evolution. The idea is that the persistent store models an attacker’s ability to see and re- member every message that has been in transit.

A legitimate question is whether such persistence re- stricts the systems that we can specify, model or reason about in the framework. For instance, whether CCP can specify the kind of systems that can be described in Linear CCP. Analogously, in the context of the above-mentioned calculi for security, e.g. in SPL, one may wonder if not al- lowing the attacker to remove messages from the network may rule out the specification of a possible attack to a given protocol. (Note that the claims of extra expressivity of Lin- ear CCP over CCP in [2, 8] are based on discrimination in- troduced by divergence that is ignored by the standard no- tion of weak bisimulation.)

There is another source of linearity in (1): Receivers can also be consumed. For example, in the case in which x(y).Pevolves intoP{z/y}. Persistent receivers arise, e.g.

in the notion of omega receptiveness [20] where the input of a name is always available—but always with the same con- tinuation. In theπ-calculus persistent receivers are used, for instance, to model functions, objects, higher-order commu- nications, or procedure definitions. Notice that the situation in this case is somehow dual to the persistent outputs case and begs the same kind of question: If we require inputs to be persistent, do we restrict the kind of systems we can specify?

Now, in the above situations we have that either mes- sages or receivers are persistent. One can further consider the complementary case in which both messages and re-

(3)

ceivers are persistent. In the context of CCP, such a restric- tion would correspond to CCP with universally-quantified persistent ask operations. In the context of calculi for se- curity, persistent receivers can be used to specify protocols where principals are willing to run an unbounded number of times (and persistent messages to model the fact that every message can be remembered by the spy). In fact, the ap- proach of specifying protocols in a persistent setting, with an unbounded number of sessions, has been explored in [3]

by using a classic logic Horn clause representation of pro- tocols (rather than a linear logic one).

In this paper, we present our expressiveness study of linearity and persistence in a well-established framework, namely the asynchronousπ-calculus. This way our study (and its applications) benefits from standard and well- investigated reasoning techniques and notions of equiva- lence. Furthermore the linear/persistent features of the above calculi are naturally captured in this framework. Lin- ear messages are represented as asynchronous outputs, and linear receivers as input processes. Persistent messages (and receivers) can simply be specified using the replication op- erator of the calculus which creates an unbounded number of copies of a given process.

We consider four sub-languages of the asynchronous polyadic π-calculus, each capturing one of the above sources of linearity/persistence. Namely, the polyadic asyn- chronousπ-calculus (π), the persistent-input π (PIπ) de- fined as π but inputs must be replicated, persistent-output defined dually, i.e. outputs rather than inputs must be repli- cated (POπ), and finally persistentπdefined asπbut with all inputs and outputs replicated (Pπ). We conduct our study by providing (or proving the non-existence of) encod- ings among the fragments, a processes-as-formulae inter- pretation and a reduction from Minsky machines.

PI

π

π

Pπ

POπ

: no encoding : subcalculus : encoding : composition

: Minsky Machines

FOL MM

MM

Figure 1. The hierarchy of linearity vs persis- tence.

Contributions. We provide encodings, homomorphic w.r.t. parallel composition, fromπintoPIπandPOπcap- turing the behaviour of the source processes. These encod- ings are, respectively, fully abstract w.r.t. weak barbed con- gruence and weak barbed congruence restricted to encoded

POπ PIπ

0 yes yes no

1 ? no no

2 no no no

Table 1. Decidability of barbed congruence for then-adic (n= 0,1,2) persistent calculi.

contexts. In contrast, we show that it is impossible to pro- vide such encodings fromπintoPπ. Intuitively this means that we need one source of linearity, i.e. either on inputs (PIπ) or outputs (POπ) to capture the behaviour of arbi- traryπprocesses via full-abstraction. Despite the impossi- bility result forwe also prove thatis in fact Turing- powerful by encoding Minsky machines. Figure 1 illus- trates these expressiveness results (a dashed arrow means that the encoding is obtained via composition).

Furthermore, we consider sub-languages of the above π-calculi with restricted arity (i.e., the maximum number of names that can be sent in a single communication) and classify them according to the decidability of barbed con- gruence and their arity. Interestingly, we state that barbed congruence is undecidable for the zero-adic version ofPIπ, the monadic version ofPOπand the bi-adic version ofPπ.

We also show that barbed congruence is decidable for the zero-adic versions ofandPIπ. We leave open the cor- responding decidability question for the monadic version of Pπ. Table 1 summarizes these decidability results.

We also show that admits a processes-as-formulae compositional interpretation, building on the translation of πto linear logic in [13, 23] and the logical characterization of CCP languages [11, 12]. Specifically, we characterize the standardπ-calculus notion of barbed observability (for Pπ) as entailment in First-Order Logic (FOL). Indeed, can be seen as a CCP language over the Gentzen constraint system (without function symbols), with persistent univer- sal asks [22]. Furthermore, we exploit classic FOL results by Bernays, Sch¨onfinkel and G¨odel to identify classes of infinite-state processes with meaningful mobile behaviour for which barbed reachability is decidable.

Our expressiveness results bear witness to the general- ity of the persistent store assumption in CCP and calculi for security. Moreover, the processes-as-formulae interpreta- tion ofPOπhas interesting applications. In particular, the decidability results for barbed reachability for may be beneficial for analyzing protocols in which principals (rep- resented as replicated input processes) are willing to run un- boundedly many times, as those studied in [3] .

Due to space limitations most proofs will be omitted.

They can be found in the extended version of this paper [18].

(4)

COM: xh~zi | x(~y).P −→P{~z/~y} if|~z|=|~y|

PAR: P −→P0

P | Q −→P0 | Q RES: P −→P0 (νx)P −→(νx)P0

STRUCT: PP0 −→Q0Q P −→Q

Table 2.Reduction Rules.

2 The Calculi

Here we define the calculi we study. We first recall the (polyadic) asynchronousπ-calculus here referred to asπ.

The other calculi are defined as syntactic restrictions ofπ.

2.1 Asynchronous Pi Calculus: π

We presuppose a countable set of names, ranged over by x, y, . . ., and for each namex, a co-namex. We usel, l0, . . . to range over names and co-names. We use~xto denote a finite sequence of namesx1x2. . . xnof size|~x| =n. The πprocesses are given by the following syntax:

P, Q, . . . := 0 | xh~zi | x(~y).P | (νx)P | P | Q | !P requiring that no name may occur more than once in~y.

Intuitively, an outputxh~zi represents a particle tagged with a name x indicating that can be received by an in- put process x(~y).P which behaves, upon receiving~z, as P{~z/~y}. Furthermore,x(~y).P binds the names~yinP. The other binder is the restriction(νx)P which declares a name x private to P. The parallel compositionP | Q means P and Qrunning in parallel. The replication !P means P | P | . . ., i.e.,!P represents a persistent resource.

We use the standard notations bn(Q) for the bound names inQ, andfn(Q)for the free names inQ, and write (νx1. . . xn)P to denote(νx1). . .(νxn)P. We letσrange over non-capturing substitutions of names on processes.

The reduction −→is the least binary relation on proc- esses satisfying the rules in Table 2. We use −→to denote the reflexive, transitive closure of −→. The reductions are quotiented by the structural congruence relation≡.

Definition 2.1. Letbe the smallest congruence over proc- esses satisfying α-equivalence, the commutative monoid laws for composition with 0 as identity, the replica- tion law !P P | !P, the restriction laws (νx)0 0, (νx)(νy)P (νy)(νx)P and the extrusion law:

(νx)(P | Q)P | (νx)Qifx6∈fn(P).

We conclude the description ofπby recalling some proc- ess equivalences we shall use throughout the paper. First we recall a basic notion of observation in theπ-calculus.

Definition 2.2. Define P x iff ∃~z, ~y, R : P (ν~z)(xh~yi | R) and x is not in ~z. Similarly, P x iff

∃~z, ~y, Q, R : P (ν~z)(x(~y).Q | R)andx is not~z.

Furthermore,P liff ∃Q: P −→Ql.

Intuitively, givenl=x(l=x) we say thatl, a barb, can be observed atP, writtenP l,iffP can perform an input (output) on channelx. However, in the context of the asyn- chronousπ-calculus in defining the process equivalences it is standard to restrict the observables to be the output barbs;

i.e., barbs of the formx[21].

We begin with a basicπprocess equivalence, sometimes referred to as barbed correspondence [17], which equates processes iff they exhibit the same barbs. In what follows we prefer to refer to this equivalence as output equivalence since we only consider output barbs. Recall that a process contextCis an expression with a hole[·]such that placing a process in the hole produces a process term.

Definition 2.3 (Output Equivalence, Output Congruence).

We say thatP andQare output equivalent, writtenP'o Q iff for every x, P x Q x . We say that P andQ are output congruent, writtenP'Q, iff for every process contextC,C[P]'o C[Q].

We now recall the notion of (weak) barbed bisimilarity.

Definition 2.4 (Barbed Bisimilarity, Barbed Congruence).

A (weak) barbed bisimulation is a symmetric relationRsat- isfying the following:(P, Q)∈ Rimplies that:

1. P −→P0then∃Q0:Q −→Q0(P0, Q0)∈ R.

2. P xthenQx.

We say thatP andQare (weak) barbed bisimilar, written P. Q, iff(P, Q) ∈ Rfor some barbed bisimulationR.

Furthermore, (weak) barbed congruence is defined as:

PQiff for every process contextC[·],C[P]. C[Q].

2.2 (Semi) Persistent Subcalculi ofπ

The Persistent-Output Calculus: POπ. The persistent- output calculusPOπarises as fromπby requiring all out- puts to be replicated. In fact forPOπ processes, −→can equivalently be defined as in Table 2 with COM replaced with the rule below. The new rule reflects the linear-input and persistent-output nature ofPOπ.

!xh~zi | x(~y).P −→ !xh~zi | P{~z/~y} if|~z|=|~y|

The Persistent-Input Calculus: PIπ. ThePIπ calculus results fromπby requiring all input processes to be repli- cated. The relation −→forPIπcan be equivalently defined as in Table 2 with COM replaced with the rule

xh~zi | !x(~y).P −→ P{~z/~y} | !x(~y).P if|~z|=|~y|

(5)

The Persistent Calculus: Pπ. Finally, we have the per- sistent calculus where output and input processes must be replicated. The relation −→forcan be equivalently defined as in Table 2 with COM replaced with the rule

!xh~zi | !x(~y).P −→ P{~z/~y} | !xh~zi | !x(~y).P if|~z|=|~y|

The next proposition reflects the duality ofPIπandPOπ.

Proposition 2.5. The following monotone properties hold:

1. IfPis aPOπprocess,P −→QandPxthenQx. 2. IfPis aPIπprocessP −→QandP xthenQx. 3. IfPis aprocess,P −→QandP lthenQl. 2.3 Calculi Conventions and their Equivalences We will work with fragments of the various calculi in terms of arity.

Definition 2.6. Define the arity ofP,A(P), asA(xh~yi) =

|~y|, A(x(~y).Q) = max(|~y|,A(Q)), A(Q | R) = max(A(Q),A(R)),A((νx)Q) =A(!Q) =A(Q).

GivenΣ ∈ {π,POπ,PIπ,Pπ}, thek-adic (version of) Σ,Σk is defined as Σexcept that its processes have arity less or equal tok. We decree thatΣω= Σ.

Convention 2.7. HenceforthCalcdenote the set of calculi k,k,PIπk,POπk |kN∪ {ω}}.

Let us now specialize our equivalences and reduction re- lation to the various calculi.

Definition 2.8. LetΣCalc.DefineP'o ΣQ(P. ΣQ) iffPandQareΣprocesses andP'o Q(P. Q). Also, de- fineP'ΣQ(P Σ Q) iffP andQareΣprocesses and for every Σ context C, C[P]'o ΣC[Q] (C[P]. ΣC[Q]).

Finally, define P −→Σ Q iffP andQ are Σprocesses andP −→Q.

Notice that reduction, modulo ≡, is invariant wrt the processes of a given calculus Σ Calc, i.e., ifP Σ andP −→Qthen there existsQ0 Σsuch thatQ0 Q.

In what follows when no confusion arises we omit the indices from process relations.

3 Encodings and their properties

In the following sections we provide, or under reason- able conditions demonstrate the impossibility of the exis- tence of, encodings[[·]]from the terms of a given language into the terms of another.

The following condition is particularly appropriate in the context of distributed systems. It describes encodings pre- serving the parallel topology of the source system.

Definition 3.1. An encoding[[·]]is a homomorphism w.r.t.

parallel composition iff [[P | Q]] = [[P]] | [[Q]]. Homo- morphism w.r.t the other operators is defined analogously.

The following notions describe some criteria used in the literature for the correctness of encodings (see e.g., [17]).

Definition 3.2. Let Σ,Σ0 Calc, and 1 {. ,,'o ,' }. Let[[·]] : Σ Σ0 be an encoding (i.e., a map ofΣterms intoΣ0terms). The encoding is sound wrt 1iff[[P]]1Σ0 [[Q]]impliesP 1Σ Q.The encoding is com- plete wrt1iffP1Σ Qimplies[[P]]1Σ0 [[Q]].The encoding is fully abstract wrt1iff it is both sound and complete wrt 1.Finally,[[·]]is ideal wrt1iff[[P]]1πP.

Intuitively, given a chosen equivalence, full abstraction says that the encoding reflects (soundness) and preserves (completeness) equivalence of source terms. Full abstrac- tion is a useful criterion for the correctness of an encoding wrt a given equivalence when ideal encodings may not ex- ist. Notice that the criterion of being ideal is stronger than that of being fully abstract.

4 On the Expressiveness of

In this section we study the expressiveness of the per- sistent calculusPπ. We first prove that it is impossible to provide a sound encoding, homomorphic wrt parallel com- position, fromπintoPπ. This holds for all the equivalences under consideration in this paper—see Definition 3.2.

Despite the above impossibility result, we prove that is Turing powerful. We also showprocesses can compo- sitionally be encoded as FOL formulae. We illustrate how mobility incan be naturally simulated in FOL and state the characterization of barbed reachability as FOL entail- ment. We use the characterization and classic FOL theo- rems to prove decidability results for meaningful classes of infinite-state mobileprocesses.

4.1 Impossibility of encodingπinto

Key to our impossibility result is establishing the prop- erty P | PP for arbitrary processes P. Consider P = (νz)!xhzi.Pmay be viewed as a generator of a single private name broadcast onxwhileP | P may be viewed as a generator of two different privates names broadcast on x. Therefore, it may not be immediate thanP | Pshould be barbed congruent toPinPπ .In fact, the property would not hold if we had the mismatch operator[x6=y]Qwhose intended meaning is thatQwill be executed iffxandyare different names [21], as the following example illustrates:

Example 4.1. Take R = !x(y).!x(y0).[y 6= y0]!t and Q = (νz)!xhzi. One can verify that (R | Q) 6⇓t but (R | Q | Q)t.

(6)

The following monotonicity property, which also does not hold in the presence of mismatch, is very useful for our results:

Proposition 4.2. For any name substitutionσ,P −→ Q impliesP σ −→Qσ.

Now, the first interesting result foris that output con- gruence and barbed congruence (restricted to contexts) coincide. The result is a corollary of the following lemma whose proof basically rests on showing thatis confluent.

Lemma 4.3. 'o = . . Corollary 4.4. ' = .

We now proceed to prove the Duplication Lemma below.

First we need the following Context Lemma whose proof is similar to Lemma 2.1.19 in [21].

Lemma 4.5 (Context Lemma). PQif for every processTand name substitutionσ,

T | P σ . T | Qσ.

Lemma 4.6 (Duplication Lemma). For every P Pπ, P | PP.

Proof. From Corollary 4.3 we can freely replace with '. The proof proceeds by induction on the size ofP. The proof ofP = (νx)R is particularly interesting and it uses Proposition 4.2 and Lemmas 4.3 and 4.5. The other cases are easier. See [18] for details.

The following proposition can be proven from the above lemmata, and analysis of the reduction of !P in arbitrary contexts.

Proposition 4.7. For everyprocessP,!P P.

We now have all what we need to prove the following impossibility result.

Theorem 4.8 (Impossibility of Sound Encodings). Let1

∈ {. ,,'o ,' }.There is no encoding[[·]] : π Pπ, homomorphic wrt parallel composition, such that for all P, Qπ,[[P]]1[[Q]]impliesP 1πQ.

Proof. Notice 'o π contains all the other process equiva- lences of the form 1π while is contained in every process equivalence of the from 1. Then, it suffices to show that there are P, Q such that [[P]][[Q]] but P6'o πQwith[[·]]being homomorphic wrt parallel composi- tion. TakeP =R | RandQ=RwhereR=x | x.x.t.

Clearly, P6'o πQ since P t but Q 6⇓t. From Lemma 4.6 and homomorphism wrt parallel composition we obtain [[P]] = [[R]] | [[R]][[R]] = [[Q]]as wanted.

4.2 FOL Characterization of

In this section we give a characterization ofin first- order logic by providing a compositional translation of processes into logical formulae, following the translation of π into linear logic [23, Table 2], and the well-known em- bedding of intuitionistic logic in linear logic through the “of course” modality “!”. In particular we shall identify barbed reachability inas logical consequence.

We assume the reader is familiar with basic notations and concepts of first-order logic. We presuppose a first-order languageLwhose non-logical symbols include predicates of the formoutk wherek 0denotes the arity of the predicate. We omit this arity index if it is understood from the context. Given two FOL formulae F andGover L, we write F |= Giff the implication formula (F G) is logically valid. If F |= Gwe say that Gis a logical consequence ofF.

The following proposition simplifies the kind of processes we need to consider in the translation.

Definition 4.9. Aprocess is said to be minimal iff it can be generated by the following syntax:

P, Q, . . . := 0 | !xh~yi | !x(~y).P | (νx)P | P | Q.

Hence minimal processes are thoseprocesses where replication only appears immediately before input and out- put processes. For example,!(νx)P is not minimal.

Definition 4.10. Letm(·) : Pπ be the map into min- imal processes given asm(!0) =m(0) = 0,m(!xh~zi) =

!xh~zi, m(!x(~y).Q) = !x(~y).m(Q), m(!(P | Q)) = m(P | Q) = m(P) | m(Q) and m(!(νx)P) = m((νx)P) = (νx)m(P).

Proposition 4.11. For everyP Pπ,m(P)P.

Proof. From Proposition 4.7.

Therefore, we can freely restrict ourselves to minimal processes. The following encoding compositionally trans- lates minimal processes into formulae.

Definition 4.12. Let[[·]] : Pπ * FOL be the partial map from minimalterms into FOL formulae given by:

[[0]] = true [[!xh~zi]] = out(x, ~z)

[[!x(~y).P]] = ∀~y(out(x, ~y)⇒[[P]]) [[P | Q]] = [[P]]∧[[Q]]

[[(νx)P]] = ∃x[[P]]

Intuitively, the above encoding[[·]]is meant to capture in logic terms how computation proceeds inPπ. In particular it has the following property: P will perform an output iff

(7)

that output is a logical consequence of[[P]]. Notice that ex- istential quantification corresponds to restriction, which can simulate name extrusion as illustrated below. Also notice that in the translation the two binders ofPπ, input and re- striction, are translated into universal and existential quan- tifiers (resp), hence reflecting an elegant duality.

Example 4.13 (Name Extrusion in FOL). The processP = (νz)(!xhzi |!z(u).u)creates a namez, broadcasts it to the outside onx, and waits on it for a messageufrom the out- side. So,R = Q | P, withQ =x(y).yhti, can perform the outputt, i.e., R ¯t .Consider the FOL translation in Definition 4.12. We have

[[R]] = ∀y(out(x, y)out(y, t))

∧ ∃z(out(x, z)∧ ∀uout(z, u)out(u)).

which is logically equivalent to

F= ∃z(∀y(out(x, y)out(y, t))

out(x, z)∧ ∀uout(z, u)out(u)).

Now, since out(z, t) is a logical consequence of

∀y(out(x, y)out(y, t))out(x, z), we have F |= ∃zout(z, t)∧ ∀uout(z, u)out(u) from which we obtainF|=out(t).

Roughly speaking, the logical step to (4.13) corresponds to using the Structural Equivalence to move a restriction to outermost position (Definition 2.1). The other steps involve Modus Ponens which corresponds to applying rule COM.

The lemma below, which can be proven using induction on length of the derivation, states that reduction corre- sponds to logical consequence.

Lemma 4.14. IfP −→Qthen[[P]]|= [[Q]].

The following theorem states the characterization of barbed observability in terms of logical consequence. It is related to a similar characterization in [23, Theorem 2.6].

Recall thatA(P)denotes the arity ofP(see Definition 2.6) and that from Proposition 4.11, up-to barbed congruence for Pπ, we can confine our attention to minimal processes.

Theorem 4.15 (FOL Characterization of Barbs). Let[[·]] : Pπ * FOL be the map in Definition 4.12. LetP be a minimalprocess. Then

P x if and only if [[P]]|=∃~zout(x, ~z) for some~zsuch that|~z| ≤ A(P).

Proof. The proof of the ”only-if” direction uses Lemma 4.14. The proof of the ”if” direction, the most difficult case, uses a normal form representation of the target formulae.

Such normal forms simplifies the analysis of how the for- mulae on the right-hand of|=could have been deduced from [[P]]. See [18].

Remark 4.16. Theorem 4.15 reveals an interesting corre- spondence between restriction and existential quantifica- tion. Intuitively, it holds because we do not have operators than can make use of the fact that two names are different.

It would not hold if we had mismatch with the natural trans- lation[[[x 6=y]P]] = (x6=y)⇒[[P]]. E.g.,(νxy)[x6=y]t can performtwhile from∃xy(x6=y)out(t)we cannot concludeout(t).For more on this issue see [18].

Applications. The following results are meant to illus- trate applications of our FOL characterization. We use clas- sic results from FOL to prove decidability results for barb reachability and barbed congruence.

Decidable Classes. The following lemma identifies several classes of processes whose barb-reachability problem is decidable. These classes include classes of infinite-state processes with name mobility (extrusion). The reachability question is relevant for safety properties stating that a given undesired output will never be performed.

Lemma 4.17. Let[[·]] : Pπ * FOL be the map in Defi- nition 4.12. GivenP andz, the question whetherP z is decidable ifP belongs to one of the following classes:

1. {R|[[R]]⇔ ∀~x∃~yF}(Bernays-Sch ¨onfinkel’s class).

2. {R|[[R]]⇔ ∀~x∃uw∀~yF}(G ¨odel’s class).

3. {R|RR0for some R’ s.t.|fn(R0)bn(R0)| ≤ 2}

(Two-Variables Class).

4. 0(Persistent CCS-like Class).

whereFis a quantifier-free formula.

Proof. By reducing the question, with the help of Proposi- tion 4.11, Theorem 4.15, to the validity of a formula which is in the class of either Bernays-Sch¨onfinkel, G¨odel, two- variables, or Monadic FOL formulae without function sym- bols. All these classes of formulae are decidable [5]. See [18] for details.

Decidable Classes with Mobility. Let us illustrate briefly the name extrusion capabilities of the “mobile” classes in the above lemma. Recall that input and restriction binders are translated into universal and existential quantifiers, re- spectively. Hence an alternation of inputs and restric- tions corresponds to alternation of universal and existen- tial quantifiers. For instance, take Q = !x(y).(νz)!yhzi.

Notice that Qhas an input-restriction alternation and[[Q]]

has an universal-existential alternation as it is equivalent to

∀y∃z(out(x, y)out(y, z)).

Consequently, Bernays-Sch¨onfinkel’s class allows providers of new names like the process Q above, i.e, processes that upon request, say on a channelx, can output private names in a given return channely. It is worth point- ing out that this class is closed under parallel composition.

(8)

So Q composed with a process R in the class, remains in the class: e.g. R could be a process !xhri | !r(z).Q0 requesting fromQa fresh name.

Nevertheless, in general the Bernays-Sch¨onfinkel’s class does not allow processes with inputs on private names as the P = (νz)(!xhzi | !z(u).!u) in our name-extrusion example (Example 4.13). However, the G¨odel class allows such processes only if the number of such inputs on private names is less than three.

The third class allows processes which can be rewritten (by re-using bound names wherever possible) with only two names. E.g.,P andQabove belong to the class sinceP (νz)(!xhzi |!z(x).!x)andQ≡!x(u).(νx)!uhxi.

Decidability Result for Barbed Congruence. It is easy to adapt the results [6] to prove that (weak) barbed con- gruence is undecidable for the zero-adic version of theπ, in our notationπ0. In contrast, here we prove that (weak) barbed congruence is decidable for the zero-adic version of Pπ,0. The proof, which can be found in [18], uses the FOL reasoning.

The following theorem states the decidability of all the equivalences under consideration for0. It should be no- ticed that the decidability result for' involves the use of FOL reasoning to characterize a finite set of contexts which is sufficient for verifying the congruence (see [18]).

Theorem 4.18 (Decidable Equivalences of0). LetΣ = 0. GivenP, QinΣand1∈ {'o ,',. ,≈ }, the question whetherP 1ΣQis decidable.

4.3 Turing Expressiveness of

In Section 4.1 we proved that there is no sound encod- ing, homomorphic wrt parallel, fromπintoPπ. In this sec- tion we show that despite such an impossibility resultis Turing-powerful. We do this by encoding two-counter ma- chines, also called Minsky machines, which are known to be Turing-powerful [16].

Minsky Machines. A two-counter Minsky machine is an imperative program consisting of a sequence of labelled instructionsI1;. . .;Ikwhich modify the values of two non- negative countersc0andc1. The instructions, using coun- ters cn for n ∈ {0,1}, are of three kinds: Li : halt, Li : cn := cn + 1; goto Lj, and Li : if cn = 0 then goto L1j else cn := cn 1; goto L2j. The Minsky machine starts atLsand halts if control reaches the location of a halt instruction. A Minsky machine M(v0, v1)computes the valuenif it halts withc0=n.

Encoding Minsky Machines. Our encoding of a given Minsky machine M with start location Ls and initial counter values v0, v1 into Pπ, [[Ms(v0, v1)]], is given below, with the encoding of non-negative numbers

in counter c, [(n)]c. The counter values are encoded in a standard fashion (similar to the persistent lists in [14]), and each location Li corresponds to a fresh name li over which the current counter values are passed. Where ever ljhc, cn⊕1i appears, order the ob- jects correctly based onn(⊕denotes addition modulo 2).

[[Ms(v0, v1)]] = (νc0, c1)`

[(v0)]c0|[(v1)]c1|!lshc0, c1i

|Q

1≤i≤k[[Ii]]´

whereM=I1;. . .;Ik

[[Li:halt]] = !li(c0, c1).!halthc0i [[Li:cn:=cn+ 1; goto Lj]]

= !li(c0, c1).(νc)(S(c, cn)|!ljhc, cn⊕1i)

[[Li:if cn= 0 then goto L1j else cn:=cn1; goto L2j]]

= !li(c0, c1).(νs, z)`

!cnhs, zi |

!z .!l1jhc0, c1i |!s(c).!l2jhc, cn⊕1i´

[(0)]c =Z(c)

[(n)]c = (νp)([(n1)]p|S(c, p)) forn >0

Z(c) = !c(s, z).!z (zero)

S(c, p) = !c(s, z).!shpi (successor)

In the encoding, because of the persistent nature ofPπ, all states which have been triggered can always be “re- executed”. The encoding of (persistent) counter values uses private channels for signalling successor and zero val- ues, and incremented values are created at private locations.

Thus the operations on the counters in one state have no ef- fect on the values encoded in another state – the encoding is free of side-effects.

For example, consider the encoding of the if-then-else instruction. The counter values at the previous enabled lo- cation are received overli; the countercn is asked for its value and will respond on one of the fresh namessandz.

If it responds onz, locationl1j is triggered with the current counter values; if it responds ons, indicating it is a succes- sor value, then locationl2jis triggered with the predecessor ofcn(which is received overs) and the other counter value.

Theorem 4.19. A Minsky machine Ms(v0, v1) computes the valueniff[[Ms(v0, v1)]]|!halt(c).Decn(c)yes where

Dec0(c) = (νs, z)(!chs, zi |!z .!yes)

Deci(c) = (νs, z)(!chs, zi |!s(p).Deci−1(p)) fori >0 Applications. In the previous sections we proved that all equivalences and barb reachability problems are decidable for0. Here we state, on the contrary, that all these prob- lems are undecidable forPπ.

As a direct consequence of the encoding of two-counter machines, we get undecidability of barbed reachability:

Lemma 4.20. GivenP inand a namex, the question whetherP xis undecidable.

From the above lemma and a series of reductions (see [18]) we get the following results.

Theorem 4.21 (Undecidable Equivalences ofPπ). LetΣ = Pπ. GivenP, QinΣand1∈ {'o ,',. ,≈ }, the question whetherP 1ΣQis undecidable.

Références

Documents relatifs

We prove that this encoding is correct and that encoded proofs can be mechanically checked by Dedukti , a type checker for the λΠ-calculus modulo theory using rewriting.. 2012

The two examples cited above have in common that a typing system stronger than the sorts is associated to a sequential calculus, introduced either in addition to, or as a fragment

Our main contribution is to provide a uniform and general result stating that, under some reasonable conditions, Aπ cannot be encoded into any of the above (semi-) persistent

Although it has been shown that this is not possible with an exact encoding, we suggest a randomized approach using a probabilistic extension of the asynchronous π -calculus, and

Intuitively, the reachability was reduced to a problem of checking whether given a sequence and an action then the process has two special barbs, with our previous results we know

3. A general lower bounding technique. We now present a framework for obtaining lower bounds on edit distances between permutations in a simple and unified way. , n ), introduced

Inspired by [MT12], we provide an example of a pure group that does not have the indepen- dence property, whose Fitting subgroup is neither nilpotent nor definable and whose

As can be seen, in this partition of the 16 possible 4-tuples into 3 mutually exclusive subsets, L corresponds to the truth table of the analogy A, K gathers the 8 patterns including