Lectures 5 and 6 - 1st October 2019 Flashcards

Never claims, LTL formulae, and Trace

1
Q

Why do liveness properties require more than propositional logic? What is needed instead?

A

Liveness properties require perspective on possible future situations. Propositional logic alone doesn’t require this.

Temporal logic is needed, as it includes temporal operators that fulfil this requirement.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why can safety properties mostly be written with propositional logic?

A

They often do not require temporal logic, as they usually just describe a property that should hold in a state.

Temporal operators are required to express properties concerning executions and not just states.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What are never claims in Spin/PROMELA?

A

Code blocks that case the program to fail and give a trace of execution to an error whenever the statements (properties) in them evaluate to being true.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Are statements in never claims atomic? Why?

A

They can be thought of as being atomic within the never claim, as they execute one-by-one. They aren’t atomic overall, however, as other processes can interleave inbetween them. This is because never claims get every other turn of execution.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

How do never claims and assert() statements compare?

A

Asserts are more simple but less powerful. If able, just use an assert rather than a never claim.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What does it mean for a never claim to succeed?

A

It has found an error, represented as it terminating or infinitely going out of accepting labels in a loop. It will then cease the program’s execution and provide a trace of execution to the error as a counterexample of the model’s correctness.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Does a never claim or another process execute first after global variables are initialised?

A

A never claim. It always executes before any other process after any global variables have been initialised.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

How do never claims execute with other processes?

A

They get every 2nd turn of execution.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Why do loops need true nondeterministic options?

A

They don’t continue looping by default if they can’t execute any options. To keep them looping, there must always be an option they can execute - be an option they can always execute.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

How can never claims be specified more easily?

A

With linear temporal logic, which is then converted into an equivalent never claim.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What are LTL statements composed of?

A

They are made of atomic propositions and boolean and temporal operators.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

How are LTL formulae included in PROMELA specifications?

A

Inline in the specification after the globals and before processes, in the format ltl[]’{‘’}’

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What does the operator □ represent in LTL?

A

always

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What does the operator ◇ represent in LTL?

A

eventually

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What does the operator X represent in LTL?

A

next

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What does the operator U represent in LTL?

A

strong until

17
Q

What does the operator W represent in LTL?

A

weak until

18
Q

What is the difference between the strong and weak until operations?

A

In strong until the second operand must eventually become true. Weak until holds if the first is always true and the second never becomes true.

19
Q

What does the operator → represent in LTL?

A

implies

20
Q

Which LTL operator can be used to represent an invariant system property?

A

p□q

21
Q

Which LTL operator can be used to represent a reply system property?

A

p◇q

22
Q

Which LTL operator can be used to represent a guranteed reply system property?

A

p→◇q

23
Q

Which LTL operator can be used to represent a progress system property?

A

p□ ◇q

24
Q

Which LTL operator can be used to represent a stability system property?

A

p◇ □q

25
Q

Which LTL operator can be used to represent an exclusion system property?

A

p→¬q

26
Q

What are the restrictions on the temporal logic of LTL formulae?

A

LTL formulae can only look at the present and future, and not the past.

27
Q

What is a trace?

A

Trace = trace of execution = the chronological list of states of an execution of a model up to a certain point.

28
Q

How do you represent a trace and property?

A

trace = t, property = p

relate the two with t ⊨ p iff t satisfies p

29
Q

What does it mean for a formula to be satisfied over a trace?

A

If the formula is true for the trace. By default, with no temporal operators, it will just be if it is true in the initial state/s. For it to be true in all, □ a is needed, for it to be true in the second state/s, X a, etc.

30
Q

What is the difference between a trace in PROMELA/SPIN and a trace of exection?

A

In PROMELA, traces of execution are called trails. Traces are atomic-like constructs that hold code blocks. Traces in PROMELA force communication sequences that must be valid across all executions of a program.

31
Q

What does the state-based nature of verification in SPIN allow us to check?

A

If a property ever holds (is reachable); if properties hold always, repeatedly, under certain conditions, never, etc; the states the system can be at (except for trace blocks in PROMELA specifications).

32
Q

What are trace constraints?

A

Atomic-like constructs that hold blocks of code that force communication sequences that must be valid across all executions of a program. They only concern the correctness of the communication actions of a specification.

33
Q

What are patterns of communication?

A

The order in which certain messages are exchanged between processes.

34
Q

What are communication actions?

A

Any statement which performs some data exchange between processes in PROMELA.

35
Q

What are the differences between trace conditions and never claims?

A

Never claims check the behaviour of a specification against disallowed behaviour and interleave with it.

Trace conditions force a specification to have certain patterns of communication and synchronise with it.

36
Q

What is an atomic proposition?

A

A statement or assertion that must be true or false.

37
Q

What are labelled transistion systems?

A

A theoretical state machine often used for describing the potential behaviour of discrete systems (i.e. systems with more than one state).