stdlib
let emptyset = domain 0
let partition = classes-loc
let tag2instrs = tag2events
let PoD = B
let BR = PoD
let po-loc = po & loc
let rfe = rf & ext
let rfi = rf & int
let co0 = loc & ((IW * (W\IW)) | ((W\FW) * FW))
let toid(s) = [s]
let fencerel(B) = (po & (_ * B)) ; po
let ctrlcfence(ctrl,CFENCE) = (ctrl & (_ * CFENCE)) ; po
let lxsx = rmw \ amo
let inv-field = try inv-domain with 0
let imply (A, B) = ~A | B
let nodetour (R1, R2, R3) = R1 \ ( R2; R3 )
let singlestep (R) = nodetour(R, R, R)
procedure subseteq(A, B) =
empty (A \ B)
end
procedure inclusion(r1, r2) =
empty r1 \ r2
end
procedure total(r,E) =
let rt = (r | r^-1)
call inclusion((E*E),rt)
end
let udr r = domain r | range r
let map f =
let rec do_map S = match S with
|| {} -> {}
|| e ++ S -> f e ++ do_map S
end in
do_map
let LKW = try LKW with emptyset