Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
article
Open access

Equality-based flow analysis versus recursive types

Published: 01 November 1998 Publication History
  • Get Citation Alerts
  • Abstract

    Equality-based control-flow analysis has been studied by Henglein, Bondorf and Jørgensen, DeFouw, Grove, and Chambers, and others. It is faster than the subset-based-0-CFA, but also more approximate. Heintze asserted in 1995 that a program can be safety checked with an equality-based control-flow analysis if and only if it can be typed with recursive types. In this article we falsify Heintze's assertion, and we present a type system equivalent to equality-based control-flow analysis. The new type system contains both recursive types and an unusual notion of subtyping. We have st if s and t unfold to the same regular tree, and we have ⊥≤t≤⊤ where t is a function type. In particular, there is no nontrivial subtyping between function types.

    References

    [1]
    AMADIO, R. M. AND CARDELLI, L. 1993. Subtyping recursive types. ACM Trans. Program. Lang. Syst. 15, 4, 575-631.
    [2]
    ASHLEY, J. M. 1996. A practical and flexible flow analysis for higher-order languages. In Proceedings of POPL '96, 23rd Annual SIGPLAN-SIGA CT Symposium on Principles of Programming Languages. ACM, New York, 184-194.
    [3]
    BONDORF, t. AND JORGENSEN, J. 1993. Efficient analyses for realistic off-line partial evaluation. J. of Func. Program. 3, 3, 315-346.
    [4]
    BRUCE, I~. B., CARDELLI, L., CASTAGNA, G., EIFRIG, J., SMITH, S. F., TRIFONOV, V., LEAVENS, G. T., AND PIERCE, B. C. 1995. On binary methods. Theory Pract. Obj. Syst. 1, 3, 221-242.
    [5]
    DEFouw, G., GROVE, D., AND CHAMBERS, C. 1998. Fast interprocedural class analysis. In Proceedings of POPL '98, 25th Annual SIGPLAN-SIGACT Symposium on Principles of Programming Languages. ACM, New York, 222-236.
    [6]
    GOSLING, J., JoY, B., AND STEELE, G. 1996. The Java Language Specification. Addison-Wesley, Reading, Mass.
    [7]
    HEINTZE, N. 1995. Control-flow analysis and type systems. In Proceedings of SAS'95, International Static Analysis Symposium. Lecture Notes in Computer Science, vol. 983. Springer-Verlag, Berlin, 189-206.
    [8]
    HEINTZE, N. AND MCALLESTER, D. 1997. Linear-time subtransitive control flow analysis. In Proceedings of ACM SIGPLAN 1997 Conference on Programming Language Design and Iraplementation. ACM, New York, 261-272.
    [9]
    HENGLEIN, F. 1992. Dynamic typing. In Proceedings of ESOP'92, European Symposium on Programming. Lecture Notes in Computer Science, vol. 582. Springer-Verlag, Berlin, 233-253.
    [10]
    MILNER, R., WOFTE, M., AND HARPER, R. 1990. The Definition of Standard ML. MIT Press, Cambridge, Mass.
    [11]
    PALSBERG~ J. 1995. Closure analysis in constraint form. ACM Trans. Program. Lang. Syst. 17, 1 (Jan.), 47-62.
    [12]
    PALSBERG, J. AND O'I~EEFE, P. M. 1995. A type system equivalent to flow analysis. ACM Trans. Program. Lang. Syst. 17, 4 (July), 576-599.
    [13]
    PALSBERG~ J. AND PAVLOPOULOU~ C. 1998. From polyvariant flow information to intersection and union types. In Proceedings of POPL'98, 25th Annual SIGPLAN-SIGACT Symposium on Principles of Programming Languages. ACM, New York, 197-208.
    [14]
    PALSBERG~ J. AND SCHWARTZBACH~ M. I. 1994. Object-Oriented Type Systems. John Wiley & Sons, New York.
    [15]
    SHAPIRO~ M. AND HORWITZ~ S. 1997. Fast and accurate flow-insensitive points-to analysis. In Proceedings of POPL '97, 2~th Annual SIGPLAN-SIGACT Symposium on Principles of Programming Languages. ACM, New York, 1-14.
    [16]
    SHIVERS~ O. 1991. Control-flow analysis of higher-order languages. Ph.D. thesis, CMU-CS-91-145, Carnegie Mellon Univ., Pittsburgh, Pa.
    [17]
    STEENSGAARD~ B. 1996. Points-to analysis in almost linear time. In Proceedings of POPL'96, 23nd Annual SIGPLAN-SIGA CT Symposium on Principles of Programming Languages. ACM, New York, 32-41.

    Cited By

    View all

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM Transactions on Programming Languages and Systems
    ACM Transactions on Programming Languages and Systems  Volume 20, Issue 6
    Nov. 1998
    212 pages
    ISSN:0164-0925
    EISSN:1558-4593
    DOI:10.1145/295656
    Issue’s Table of Contents
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 01 November 1998
    Published in TOPLAS Volume 20, Issue 6

    Permissions

    Request permissions for this article.

    Check for updates

    Author Tags

    1. flow analysis
    2. type systems

    Qualifiers

    • Article

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)32
    • Downloads (Last 6 weeks)9
    Reflects downloads up to 11 Aug 2024

    Other Metrics

    Citations

    Cited By

    View all

    View Options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Get Access

    Login options

    Full Access

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media