10.1145/582419.582448acmconferencesArticle/Chapter ViewAbstractPublication PagessplashConference Proceedings
Article

Alias annotations for program understanding

ABSTRACT

One of the primary challenges in building and evolving large object-oriented systems is understanding aliasing between objects. Unexpected aliasing can lead to broken invariants, mistaken assumptions, security holes, and surprising side effects, all of which may lead to software defects and complicate software evolution.This paper presents AliasJava, a capability-based alias annotation system for Java that makes alias patterns explicit in the source code, enabling developers to reason more effectively about the interactions in a complex system. We describe our implementation, prove the soundness of the annotation system, and give an algorithm for automatically inferring alias annotations. Our experience suggests that the annotation system is practical, that annotation inference is efficient and yields appropriate annotations, and that the annotations can express important invariants of data structures and of software architectures.

References

  1. Jonathan Aldrich, Craig Chambers, and David Notkin. ArchJava: Connecting Software Architecture to Implementation. Proc. International Conference on Software Engineering, Orlando, Florida, May 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. Jonathan Aldrich, Craig Chambers, and David Notkin. Architectural Reasoning with ArchJava. Proc. European Conference on Object-Oriented Programming, Milaga, Spain, June 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Jonathan Aldrich, Valentin Kostadinov, and Craig Chambers. Alias Annotations for Program Understanding. University of Washington technical report UW-CSE-02-11-01, November 2002.]]Google ScholarGoogle Scholar
  4. Paulo Sergio Almeida. Balloon Types: Controlling Sharing of State in Data Types, Proc. European Conference on Object-Oriented Programming, Jyvaskyla, Finland, June 1997.]]Google ScholarGoogle Scholar
  5. ArchJava web site. http://www.archjava.org/]]Google ScholarGoogle Scholar
  6. Boris Bokowski. Implementing "Object Ownership to Order." Proc. Intercontinental Workshop on Aliasing In Object-Oriented Systems, Lisbon, Portugal, June 1999.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Anindya Banerjee and David A. Naumann. Representation Independence, Confinement, and Access Control. Proc. Principles of Programming Languages, Portland, Oregon, January 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. John Boyland, James Noble, and William Retert. Capabilities for Sharing: A Generalization of Uniqueness and Read-Only. Proc. European Conference on Object-Oriented Programming, Budapest,]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. John Boyland. Alias Burying: Unique Variables Without Destructive Reads. Software Practice & Experience, 6(31):533--553, May 2001.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Chandrasekhar Boyapati and Martin Rinard. A Parameterized Type System for Race-Free Java Programs. Proc. Object-Oriented Programming Systems, Languages and Applications, Tampa, Florida, October 2001.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. Chandrasekhar Boyapati, Robert Lee, and Martin Rinard. Ownership Types for Safe Programming: Preventing Data Races and Deadlocks. Proc. Object-Oriented Programming Systems, Languages and Applications, Seattle, Washington, November 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Boris Bokowski and Andre Spiegel. Barat-A Front-End for Java. Freie Universitat Berlin Technical Report B-98-09, December 1998.]]Google ScholarGoogle Scholar
  13. Alexander Buckley. Ownership Types Restrict Aliasing. MEng. Computing Final Year Project Report, Imperial College of Science, Technology and Medicine, London, United Kingdom, June]]Google ScholarGoogle Scholar
  14. Boris Bokowski and Jan Vitek. Confined Types. Proc. Object-Oriented Programming Systems, Languages, and Applications, Denver, Colorado, November 1999.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. Edwin C. Chan, John T. Boyland, and William L. Scherlis. Promises: Limited Specifications for Analysis and Manipulation. Proc. International Conference on Software Engineering, Kyoto, Japan, April 1998.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. David Clarke and Sophia Drossopoulou. Ownership, Encapsulation, and the Disjointness of Type and Effect. Proc. Object-Oriented Programming Systems, Languages and Applications, Seattle, Washington, November 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. David Clarke. Object Ownership & Containment. Ph.D. Thesis, University of New South Wales, Australia, July 2001.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. David G. Clarke, James Noble, and John M. Potter. Simple Ownership Types for Object Containment. Proc. European Conference on Object-Oriented Programming, Budapest, Hungary, June 2001.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. David G. Clarke, John M. Potter, and James Noble. Ownership Types for Flexible Alias Protection. Proc. Object-Oriented Programming Systems, Languages and Applications, Vancouver, Canada, October 1998.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. Karl Crary, David Walker, and Greg Morrisett. Typed Memory Management in a Calculus of Capabilities. Proc. Principles of Programming Languages, San Antonio, Texas, January 1999.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  21. Manuel Fehndrich and Robert DeLine. Adoption and Focus: Practical Linear Types for Imperative Programming. Proc. Programming Language Design and Implementation, Berlin, Germany, June 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. Manuel Fehndrich, Jakob Rehof, and Manuvir Das. Scalable Context-Sensitive Flow Analysis using Instantiation Constraints. Proc. Programming Language Design and Implementation, Vancouver, Canada, June 2000.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Erich Gamma, Richard Helm, Ralph Johnson and John Vlissides. Design Patterns: Elements of Reusable Object-Oriented Software. Reading, Massachusetts: Addison-Wesley, 1994.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  24. Dan Grossman, Greg Morrisett, Trevor Jim, Michael Hicks, Yanling Wang, and James Cheney. Region-Based Memory Mangagement in Cyclone. Proc. Programming Language Design and Implementation, Berlin, Germany, June 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  25. Christian Grothoff, Jens Palsberg, and Jan Vitek. Encapsulating Objects with Confined Types. Proc. Object-Oriented Programming Languages, Systems, and Applications, Tampa, Florida, November 2001.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  26. David Garlan and Mary Shaw. An Introduction to Software Architecture. In Advances in Software Engineering and Knowledge Engineering, I (Ambriola V, Tortora G, Eds.) World Scientific Publishing Company, 1993.]]Google ScholarGoogle Scholar
  27. Fritz Henglein. Type Inference with Polymorphic Recursion. Trans. Programming Languages and Systems, 15(2):253--289, April 1993.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  28. John Hogg. Islands: Aliasing Protection in Object-Oriented Languages. Proc. Object-Oriented Programming: Systems, Languages and Applications, Phoenix, Arizona, October 1991.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  29. John Hogg, Doug Lea, Alan Wills, Dennis deChampeaux, and Richard Holt. The Geneva Convention on the Treatment of Object Aliasing. OOPS Messenger, 3(2), April 1992.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. Atsushi Igarashi, Benjamin Pierce, and Philip Wadler. Featherweight Java: A Minimal Core Calculus for Java and GJ. Proc. Object-Oriented Programming Systems, Languages, and Applications, Denver, Colorado, November 1999.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. Viktor Kuncak, Patrick Lam, and Martin Rinard. Role Analysis. Proc. Principles of Programming Languages, Portland, Oregon, January 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. Assaf J. Kfoury, Jerzy Tiuryn, and Pawel Urzyczyn. The Undecidability of the Semi-Unification Problem. Information and Computation, 102(1):83--101, January 1993.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. K. Rustan M. Leino, Arnd Poetzsch-Heffter, and Yunhong Zhou. Using Data Groups to Specify and Check Side Effects. Proc. Programming Language Design and Implementation, Berlin, Germany, June 2002.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  34. Naftaly Minsky. Towards Alias-Free Pointers. Proc. of European Conference on Object Oriented Programming, Linz, Austria, July 1996.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. Andrew C. Myers. JFlow: Practical Most-Static Information Flow Control. Proc. Principles of Programming Languages, San Antonio, Texas, January 1999.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  36. Peter Muller and Arnd Poetzsch-Heffter. Universes: A Type System for Controlling Representation Exposure. In A. Poetzsch-Heffter and J. Meyer (Hrsg.): Programmiersprachen und Grundlagen der Programmierung, 10. Kolloquium, Informatik Berichte 263, 1999/2000.]]Google ScholarGoogle Scholar
  37. James Noble, Jan Vitek, and John Potter. Flexible alias protection. Proc. European Conference on Object-Oriented Programming, Brussels, Belgium, 1998.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. Robert O'Callahan. Generalized Aliasing as a Basis for Program Analysis Tools. Ph.D. Thesis, published as Carnegie Mellon technical report CMU-CS-01-124, November 2000.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. Robert O'Callahan and Daniel Jackson. Lackwit: A Program Understanding Tool Based on Type Inference. Proc. International Conference on Software Engineering, Boston, Massachusetts, May 1997.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  40. Mads Tofte and Jean-Pierre Talpin. Implementing the Call-by-Value ?-Calculus Using a Stack of Regions. Proc. Principles of Programming Languages, Portland, Oregon, January 1994.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  41. Philip Wadler. Linear Types Can Change the World! Programming Concepts and Methods, (M. Broy and C. Jones, eds.) North Holland, Amsterdam, April 1990.]]Google ScholarGoogle Scholar
  42. David Walker and Greg Morrisett. Alias Types for Recursive Data Structures. Proc. International Workshop on Types in Compilation, Montreal, Canada, September 2000.]] Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Alias annotations for program understanding

    Comments

    Login options

    Check if you have access through your login credentials or your institution to get full access on this article.

    Sign in

    PDF Format

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader
    About Cookies On This Site

    We use cookies to ensure that we give you the best experience on our website.

    Learn more

    Got it!