Typing termination in a higher-order concurrent imperative language

被引:10
|
作者
Boudol, Gerard [1 ]
机构
[1] INRIA Sophia Antipolis, F-06902 Sophia Antipolis, France
关键词
RECURSIVE TYPES; INFORMATION-FLOW; SEMANTICS; PROGRAMS; STORAGE;
D O I
10.1016/j.ic.2009.06.007
中图分类号
TP301 [理论、方法];
学科分类号
081202 ;
摘要
We propose means to predict termination in a higher-order imperative and concurrent language a la ML. We follow and adapt the classical method for proving termination in typed formalisms, namely the realizability technique. There is a specific difficulty with higher-order state, which is that one cannot define a realizability interpretation simply by induction on types, because applying a function may have side-effects at types not smaller than the type of the function. Moreover, such higher-order side-effects may give rise to computations that diverge without resorting to explicit recursion. We overcome these difficulties by introducing a type and effect system for our language that enforces a stratification of the memory. The stratification prevents the circularities in the memory that may cause divergence, and allows us to define a realizability interpretation of the types and effects, which we then use to establish that typable sequential programs in our system are guaranteed to terminate, unless they use explicit recursion in a divergent way. We actually prove a more general fairness property, that is, any typable thread yields the scheduler after some finite computation. Our realizability interpretation also copes with dynamic thread creation. (C) 2010 Elsevier Inc. All rights reserved.
引用
收藏
页码:716 / 736
页数:21
相关论文
共 50 条
  • [1] Termination in higher-order concurrent calculi
    Demangeon, Romain
    Hirschkoff, Daniel
    Sangiorgi, Davide
    JOURNAL OF LOGIC AND ALGEBRAIC PROGRAMMING, 2010, 79 (07): : 550 - 577
  • [2] Termination in Higher-Order Concurrent Calculi
    Demangeon, Romain
    Hirschkoff, Daniel
    Sangiorgi, Davide
    FUNDAMENTALS OF SOFTWARE ENGINEERING, 2010, 5961 : 81 - +
  • [3] CML - A HIGHER-ORDER CONCURRENT LANGUAGE
    REPPY, JH
    SIGPLAN NOTICES, 1991, 26 (06): : 293 - 305
  • [4] Modular Reasoning about Concurrent Higher-Order Imperative Programs
    Birkedal, Lars
    ACM SIGPLAN NOTICES, 2014, 49 (01) : 1 - 1
  • [5] Representing imperative language in higher-order action calculus
    Jin, Ying
    Jin, Cheng-Zhi
    2002, Science Press (39):
  • [6] Soundness of data refinement for a higher-order imperative language
    Naumann, DA
    THEORETICAL COMPUTER SCIENCE, 2002, 278 (1-2) : 271 - 301
  • [7] A Higher-Order Logic for Concurrent Termination-Preserving Refinement
    Tassarotti, Joseph
    Jung, Ralf
    Harper, Robert
    PROGRAMMING LANGUAGES AND SYSTEMS (ESOP 2017): 26TH EUROPEAN SYMPOSIUM ON PROGRAMMING, 2017, 10201 : 909 - 936
  • [8] Pilsner: A Compositionally Verified Compiler for a Higher-Order Imperative Language
    Neis, Georg
    Hur, Chung-Kil
    Kaiser, Jan-Oliver
    McLaughlin, Craig
    Dreyer, Derek
    Vafeiadis, Viktor
    PROCEEDINGS OF THE 20TH ACM SIGPLAN INTERNATIONAL CONFERENCE ON FUNCTIONAL PROGRAMMING (ICFP'15), 2015, : 166 - 178
  • [9] Pilsner: A Compositionally Verified Compiler for a Higher-Order Imperative Language
    Neis, Georg
    Hur, Chung-Kil
    Kaiser, Jan-Oliver
    McLaughlin, Craig
    Dreyer, Derek
    Vafeiadis, Viktor
    ACM SIGPLAN NOTICES, 2015, 50 (09) : 166 - 178
  • [10] Predicate transformer semantics of a higher-order imperative language with record subtyping
    Naumann, DA
    SCIENCE OF COMPUTER PROGRAMMING, 2001, 41 (01) : 1 - 51