Hector: An Equivalence Checker for a Higher-Order Fragment of ML
We present Hector, an observational equivalence checker for a higher-order fragment of ML. The input language is RML, the canonical restriction of standard ML to ground-type references. Hector accepts programs from a decidable fragment of RML identified by us at ICALP’11, which comprises programs of short-type (order at most 2 and arity at most 1) that may contain free variables whose arguments are also of short-type. This is an expressive fragment that contains complex higher-order types, and includes many examples from the literature which have proven challenging to verify using other methods. To our knowledge, Hector is the first fully-automated equivalence checker for higher-order, call-by-value programs. Both sound and complete, the tool relies on the fully abstract game semantics of RML to construct, on-the-fly, visibly pushdown automata which precisely capture program behaviour. These automata are then checked for language equivalence, and if they are inequivalent a counterexample (in the form of a separating context) is constructed.
KeywordsModel Checker Equivalence Checker Game Model Predicate Abstraction Game Semantic
- 3.Alur, R., Madhusudan, P.: Visibly pushdown languages. In: STOC (2004)Google Scholar
- 6.Dreyer, D., Neis, G., Birkedal, L.: The impact of higher-order state and control effects on local relational reasoning. In: ICFP, pp. 143–156 (2010)Google Scholar
- 10.Kobayashi, N.: Model-checking higher-order functions. In: PPDP, pp. 25–36 (2009)Google Scholar
- 11.Pitts, A.M., Stark, I.D.B.: Operational reasoning for functions with local state. Higher Order Operational Techniques in Semantics (1998)Google Scholar
- 12.Stark, I.D.B.: Names and Higher-Order Functions. PhD thesis, Univ. of Cambridge (1995)Google Scholar