Theory IMP_concur
chapter‹‹IMP⇩c⇩o⇩n⇩c⇩u⇩r›-A Shallow Embedding in HOL-CSP›
theory IMP_concur
imports "HOL-CSPM"
begin
section‹Introduction›
text‹
‹IMP⇩c⇩o⇩n⇩c⇩u⇩r› is intended to provide a more common (though still theoretic)
programming-language aspect to CSP, and could be an interesting object
of study in itself. This thin layer over HOL-CSP establishes a link
between programming languages and process-algebras, a link that had already
been present in the influential OCCAM language.
‹IMP⇩c⇩o⇩n⇩c⇩u⇩r› comprises the standard elements of the IMP - language (‹SKIP›, ‹assignment›,
‹IF _ THEN _ ELSE›, ‹WHILE _ DO _› and the sequential composition ‹_ ; _›), plus
the new features:
▸ semaphores with ‹lock› and ‹unlock›, and
▸ thread-global shared variables accessible
via ‹LOAD› and ‹STORE› operations.
This file contains:
▸ the abstract and concrete syntax of ‹IMP⇩c⇩o⇩n⇩c⇩u⇩r›
▸ bricks-specifications for semaphores and global shared variables,
▸ a denotational semantics of ‹IMP⇩c⇩o⇩n⇩c⇩u⇩r› converting ‹IMP⇩c⇩o⇩n⇩c⇩u⇩r›-program
systems into HOL-CSPM, and
▸ some examples and tests.
The general theory should be developed elsewhere; this sample file shows the
global construction principle of a combined semantics.›
section‹The Syntax of ‹IMP⇩c⇩o⇩n⇩c⇩u⇩r››
type_synonym SV = string
type_synonym V = string
type_synonym MV = int
type_synonym D = int
type_synonym "σ" = ‹V ⇒ D›
type_synonym "E⇩a⇩r⇩i⇩t⇩h" = ‹σ ⇒ D›
type_synonym "E⇩b⇩o⇩o⇩l" = ‹σ ⇒ bool›
type_synonym "F" = "σ ⇒ σ"