Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
10.1145/263699.263753acmconferencesArticle/Chapter ViewAbstractPublication PagespoplConference Proceedingsconference-collections
Article
Free access

A demand-driven set-based analysis

Published: 01 January 1997 Publication History

Abstract

In this paper we present an analysis technique for isolating dead code in higher-order functional programs. First, we formalize what it means for a program fragment to contribute to the value returned by the program. Next, we provide a purely declarative specification of a subset of terms which constitute dead code. This is done by a refinement of the set-based semantics technique, developed by Nevin Heintze, by the introduction of a concept of demand. We then develop a demand-driven set-based analysis to compute dead code specified by the declarative specification. The demand-driven set-based analysis developed in this paper is polynomial time, in the size of the input program.

References

[1]
M. Abadi, B. Lampson, and J.-J. L4vy. Analysis and caching of dependencies. In Proceedings of the 1996 A CM SIGPLAN International Conference on Functional Programming, pages 83-92, 1996.
[2]
A. V. Aho, R. Sethi, and J. D. Ullman. Compilers: Principles, Techniques, and Tools. Addison- Wesley, 1985.
[3]
A. Appel. Compiling with Continuations. Cambridge University Press, 1992.
[4]
Z.M. Ariola, M. Felleisen, J. Maraist, M. Odersky, and P. Wadler. A Call-By-Need Lambda Calculus. In P. Lee, editor, Conference Record of the Twenty-Second Annual A CM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, pages 233-246. ACM, 1995.
[5]
T. Chuang and B. Goldberg. Backward Analysis for Higher-Order Functions Using Inverse Images. Technical Report 620, Department of Computer Science, New York University, 1991.
[6]
P. Fradet. Collecting More Garbage. In A CM Conference on LISP and Functional Programming, pages 24-33, 1994.
[7]
C. A. Gunter. Semantics of Programming Languages: Structures and Techniques. Foundations of Computing. The MIT Press, 1992.
[8]
N. Heintze. Private Communication.
[9]
N. Heintze. Set Based Program Analysis. PhD thesis, School of Computer Science, Carnegie Mellon University, 1992.
[10]
N. Heintze. Set Based Analysis of Arithmetic. Technical Report CMU-CS-93-221, School of Computer Science, Carnegie Mellon University, 1993.
[11]
N. Heintze. Set Based Analysis of ML Programs. In Lisp and Functional Programming, pages 306-317. ACM, 1994.
[12]
J. Hughes. Lazy Memo-functions. In J. Jouannaud, editor, Proceedings of the Conference on Functional Programming and Computer Architecture, pages 129-146. Springer-Verlag LNCS, 1985.
[13]
J. Hughes. Compile-time Analysis of Functional Programs. In D. Turner, editor, Research Topics in Functional Programming, pages 117-153. Addison- Wesley, 1990.
[14]
N. Jones and S. Muchnik. Flow analysis and optimization of LISP-like structures. In Principles of Programming Languages, pages 244-256. ACM, 1979.
[15]
J. Launchbury. A natural semantics for lazy evaluation. In S. L. Graham, editor, Conference Record of the Twentieth Annual A CM SIGPLAN-SIGA CT Symposium on Principles of Programming Languages, pages 144-154. ACM, 1993.
[16]
R. Milner, M. Tofte, and R. Harper. The Definition of Standard ML. The MIT Press, 1990.
[17]
G. Morrisett, M. Felleisen, and R. Harper. Abstract models of memory management. In Proceedings of the 7th International Conference on Functional Languages and Program Architecture, pages 66-77, 1995.
[18]
A. Mycroft. The Theory and Practice of Transforming Call-by-need into Call-by-value. In International Symposium on Programming. Springer- Verlag LNCS, 1980.
[19]
G. D. Plotkin. Call-by-name, call-by-value and the lambda calculus. Theoretical Computer Science, 1:125-159, 1975.
[20]
N. RSjemo and C. Runciman. Lag, drag, void and use - heap profiling and space-efficient compilation revisited. In Proceedings of the 1996 A CM SIGPLAN International Conference on Functional Programming, pages 34-41, 1996.
[21]
R.C. Sekar, P. Mishra, and I.V. Ramakrishnan. On the Power and Limitation of Strictness Analysis based on Abstract Interpretation. In Conference Record of the 18th Annual A CM SIGPLAN- SIGACT Symposium on Principles of Programming Languages, pages 37-48. ACM, 1991.

Cited By

View all

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
POPL '97: Proceedings of the 24th ACM SIGPLAN-SIGACT symposium on Principles of programming languages
January 1997
497 pages
ISBN:0897918533
DOI:10.1145/263699
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]

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 01 January 1997

Permissions

Request permissions for this article.

Check for updates

Qualifiers

  • Article

Conference

POPL97
Sponsor:
  • SIGPLAN
  • Ctr Natl de la Recherche Sci
  • L'Ecole des Mines de Paris
  • SIGACT

Acceptance Rates

POPL '97 Paper Acceptance Rate 36 of 225 submissions, 16%;
Overall Acceptance Rate 824 of 4,130 submissions, 20%

Upcoming Conference

POPL '25

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)36
  • Downloads (Last 6 weeks)2
Reflects downloads up to 30 Aug 2024

Other Metrics

Citations

Cited By

View all
  • (2019)Demand Control-Flow AnalysisVerification, Model Checking, and Abstract Interpretation10.1007/978-3-030-11245-5_11(226-246)Online publication date: 11-Jan-2019
  • (2012)Control-flow analysis of functional programsACM Computing Surveys10.1145/2187671.218767244:3(1-33)Online publication date: 14-Jun-2012
  • (2012)Control-flow analysis of function calls and returns by abstract interpretationInformation and Computation10.1016/j.ic.2011.11.005211(49-76)Online publication date: 1-Feb-2012
  • (2008)Dynamic slicing of lazy functional programs based on redex trailsHigher-Order and Symbolic Computation10.1007/s10990-008-9023-721:1-2(147-192)Online publication date: 1-Jun-2008
  • (2008)A Calculational Approach to Control-Flow Analysis by Abstract InterpretationProceedings of the 15th international symposium on Static Analysis10.1007/978-3-540-69166-2_23(347-362)Online publication date: 16-Jul-2008
  • (2004)Dynamic slicing based on redex trailsProceedings of the 2004 ACM SIGPLAN symposium on Partial evaluation and semantics-based program manipulation10.1145/1014007.1014020(123-134)Online publication date: 24-Aug-2004
  • (2002)Useless-Code Detection and Elimination for PCF with Algebraic Data TypesTyped Lambda Calculi and Applications10.1007/3-540-48959-2_8(83-97)Online publication date: 27-May-2002
  • (2000)Automated analysis of standard MLACM SIGSOFT Software Engineering Notes10.1145/340855.34095025:1(53)Online publication date: 1-Jan-2000
  • (1997)Set constraintsProceedings of the 3rd International Conference on Principles and Practice of Constraint Programming10.1007/BFb0017466(549-561)Online publication date: 29-Oct-1997

View Options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Get Access

Login options

Media

Figures

Other

Tables

Share

Share

Share this Publication link

Share on social media