Section BISepAlg.
Context {A} `{sa : SepAlg A}.
Context {B} `{IL: ILogic B}.
Program Instance SABIOps: BILOperators (ILFunFrm A B) := {
empSP := mkILFunFrm e (fun x => sa_unit === x /\\ ltrue) _;
sepSP P Q := mkILFunFrm e (fun x => Exists x1, Exists x2, sa_mul x1 x2 x /\\
P x1 //\\ Q x2) _;
wandSP P Q := mkILFunFrm e (fun x => Forall x1, Forall x2, sa_mul x x1 x2 ->>
P x1 -->> Q x2) _
}.
Next Obligation.
admit.
Defined.
Next Obligation.
admit.
Defined.
Next Obligation.
admit.
Defined.
End BISepAlg.
Set Implicit Arguments.
Definition Chan := WORD.
Definition Data := BYTE.
Inductive Action :=
| Out (c:Chan) (d:Data)
| In (c:Chan) (d:Data).
Definition Actions := list Action.
Instance ActionsEquiv : Equiv Actions := {
equiv a1 a2 := a1 = a2
}.
Definition OPred := ILFunFrm Actions Prop.
Definition mkOPred (P : Actions -> Prop) : OPred.
admit.
Defined.
Definition eq_opred s := mkOPred (fun s' => s === s').
Definition empOP : OPred.
exact (eq_opred nil).
Defined.
Definition catOP (P Q: OPred) : OPred.
admit.
Defined.
Class IsPointed (T : Type) := point : T.
Generalizable All Variables.
Notation IsPointed_OPred P := (IsPointed (exists x : Actions, (P : OPred) x)).
Record PointedOPred := mkPointedOPred {
OPred_pred :> OPred;
OPred_inhabited: IsPointed_OPred OPred_pred
}.
Existing Instance OPred_inhabited.
Canonical Structure default_PointedOPred O `{IsPointed_OPred O} : PointedOPred
:= {| OPred_pred := O ; OPred_inhabited := _ |}.
Instance IsPointed_eq_opred x : IsPointed_OPred (eq_opred x).
admit.
Defined.
Instance IsPointed_catOP `{IsPointed_OPred P, IsPointed_OPred Q} : IsPointed_OPred (catOP P Q).
admit.
Defined.
Definition Flag  := BITS 5.
Definition OF: Flag.
admit.
Defined.
Inductive FlagVal := mkFlag (b: bool) | FlagUnspecified.
Coercion mkFlag : bool >-> FlagVal.
Inductive NonSPReg := EAX | EBX | ECX | EDX | ESI | EDI | EBP.
Inductive Reg := nonSPReg (r: NonSPReg) | ESP.
Inductive AnyReg := regToAnyReg (r: Reg) | EIP.
Inductive BYTEReg := AL|BL|CL|DL|AH|BH|CH|DH.
Inductive WORDReg := mkWordReg (r:Reg).
Definition PState : Type.
admit.
Defined.
Instance PStateEquiv : Equiv PState.
admit.
Defined.
Instance PStateType : type PState.
admit.
Defined.
Instance PStateSepAlgOps: SepAlgOps PState.
admit.
Defined.
Definition SPred : Type.
exact (ILFunFrm PState Prop).
Defined.
Local Existing Instance ILFun_Ops.
Local Existing Instance SABIOps.

Axiom BYTEregIs : BYTEReg -> BYTE -> SPred.