Show simple item record

dc.contributor.authorChlipala, Adam
dc.contributor.authorWang, Peng
dc.contributor.authorWant, Di
dc.date.accessioned2019-06-10T18:00:00Z
dc.date.available2019-06-10T18:00:00Z
dc.date.issued2017-10
dc.identifier.issn2475-1421
dc.identifier.urihttps://hdl.handle.net/1721.1/121232
dc.description.abstractWe present TiML (Timed ML), an ML-like functional language with time-complexity annotations in types. It uses indexed types to express sizes of data structures and upper bounds on running time of functions; and refinement kinds to constrain these indices, expressing data-structure invariants and pre/post-conditions. Indexed types are flexible enough that TiML avoids a built-in notion of "size," and the programmer can choose to index user-defined datatypes in any way that helps her analysis. TiML's distinguishing characteristic is supporting highly automated time-bound verification applicable to data structures with nontrivial invariants. The programmer provides type annotations, and the typechecker generates verification conditions that are discharged by an SMT solver. Type and index inference are supported to lower annotation burden, and, furthermore, big-O complexity can be inferred from recurrences generated during typechecking by a recurrence solver based on heuristic pattern matching (e.g. using the Master Theorem to handle divide-and-conquer-like recurrences). We have evaluated TiML's usability by implementing a broad suite of case-study modules, demonstrating that TiML, though lacking full automation and theoretical completeness, is versatile enough to verify worst-case and/or amortized complexities for algorithms and data structures like classic list operations, merge sort, Dijkstra's shortest-path algorithm, red-black trees, Braun trees, functional queues, and dynamic tables with bounds like m n logn. The learning curve and annotation burden are reasonable, as we argue with empirical results on our case studies. We formalized TiML's type-soundness proof in Coq.en_US
dc.description.sponsorshipNational Science Foundation (U.S.) (Grant CCF-1512611)en_US
dc.description.sponsorshipUnited States. Defense Advanced Research Projects Agency (FA8750-16-C-0007)en_US
dc.language.isoen
dc.publisherAssociation for Computing Machinery (ACM)en_US
dc.relation.isversionofhttp://dx.doi.org/10.1145/3133903en_US
dc.rightsCreative Commons Attribution 4.0 International licenseen_US
dc.rights.urihttps://creativecommons.org/licenses/by/4.0/en_US
dc.sourceACMen_US
dc.titleTiML: a functional language for practical complexity analysis with invariantsen_US
dc.typeArticleen_US
dc.identifier.citationWang, Peng, et al. “TiML: A Functional Language for Practical Complexity Analysis with Invariants.” Proceedings of the ACM on Programming Languages 1, OOPSLA, (October 2017): pp. 1–26. © 2017 The Authorsen_US
dc.contributor.departmentMassachusetts Institute of Technology. Computer Science and Artificial Intelligence Laboratoryen_US
dc.contributor.departmentMassachusetts Institute of Technology. Department of Electrical Engineering and Computer Scienceen_US
dc.relation.journalProceedings of the ACM on Programming Languagesen_US
dc.eprint.versionFinal published versionen_US
dc.type.urihttp://purl.org/eprint/type/ConferencePaperen_US
eprint.statushttp://purl.org/eprint/status/NonPeerRevieweden_US
dc.date.updated2019-05-13T18:00:45Z
dspace.date.submission2019-05-13T18:00:46Z


Files in this item

Thumbnail

This item appears in the following Collection(s)

Show simple item record