09.08.2013 Views

Design and Verification of Adaptive Cache Coherence Protocols ...

Design and Verification of Adaptive Cache Coherence Protocols ...

Design and Verification of Adaptive Cache Coherence Protocols ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Intuitively, \2P " means that \P is true all the times". We can de ne temporal operators<br />

such as\3" (eventually) <strong>and</strong> \" (leads-to) using the operator \2".<br />

3P : 2: P . This predicate asserts that P will be true at some future time (that is,<br />

P is not always false). Note that by \future time" we also include the \present time".<br />

PQ 2(P ) 3Q ). This predicate asserts that whenever P is true, Q will be true<br />

at some later time. This operator is transitive, meaning that any sequence satisfying<br />

\PQ "<strong>and</strong>\QG " also satis es \PG ".<br />

To ensure liveness, we need to enforce some fairness throughout the system execution.<br />

Intuitively, fairness means that if a rule is applicable, it must be applied eventually. The<br />

fairness <strong>of</strong> concurrent systems can be expressed in terms <strong>of</strong> weak fairness <strong>and</strong> strong fairness<br />

conditions. Weak fairness means that if a rule is applicable, it must be applied eventually or<br />

will become impossible to apply at some later time. Strong fairness means that if a rule is<br />

applicable, it must be applied eventually or will become impossible to apply forever.<br />

Let Enabled(R) be the predicate that determines whether the rule R is applicable. We can<br />

de ne weak fairness <strong>and</strong> strong fairness as follows:<br />

WF(R) (23R) _ (23:Enabled(R))<br />

SF(R) (23R) _ (32:Enabled(R))<br />

The fairness <strong>of</strong> a rule actually refers to the fairness <strong>of</strong> the application <strong>of</strong> the rule on a<br />

speci c redex. Note that a rule can <strong>of</strong>ten be applied on di erent redexes at the same time.<br />

Unless otherwise speci ed, weak or strong fairness <strong>of</strong> a rule means the application <strong>of</strong> the rule<br />

on any redex is weakly or strongly fair.<br />

Theorem-WF Given predicates P <strong>and</strong> Q , PQ if the following conditions are true:<br />

8s (P (s) )9R 9s 0 (WF(R) ^ s R !s 0 ^ Q (s 0 )))<br />

8s (P (s) )8R 8s 0 (s R !s 0 ) (Q (s 0 ) _ P (s 0 )))).<br />

Theorem-SF Given predicates P <strong>and</strong> Q , PQ if the following conditions are true:<br />

8s (P (s) )9R 9s 0 (SF(R) ^ s R !s 0 ^ Q (s 0 )))<br />

8s (P (s) )8R 8s 0 (s R !s 0 ) (Q (s 0 ) _9G (G (s 0 ) ^ (GP ))))).<br />

Although the operator \2" can be used to specify properties such as what will happen<br />

eventually, it does not allow us to express properties such as what will happen in the next term<br />

<strong>of</strong> a sequence. This constraint is deliberate because an implementation can <strong>of</strong>ten take various<br />

number <strong>of</strong> steps to achieve the semantic e ect <strong>of</strong> a single step in a speci cation. Therefore, it<br />

makes little sense for a speci cation to require that something must happen in the next step <strong>of</strong><br />

an execution.<br />

However, some additional temporal operators can be used to simplify the liveness pro<strong>of</strong>.<br />

The operator \ " (next) is introduced for this purpose: the predicate ( P )(hs1, s2, s3, :::i)<br />

41

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

Saved successfully!

Ooh no, something went wrong!