Skip to main content

A Type System and Analysis for the Automatic Extraction and Enforcement of Design Information

  • Conference paper
Book cover ECOOP 2003 – Object-Oriented Programming (ECOOP 2003)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 2743))

Included in the following conference series:

Abstract

We present a new type system and associated type checker, analysis, and model extraction algorithms for automatically extracting models that capture aspects of a program’s design. Our type system enables the developer to place a token on each object; this token serves as the object’s representative during the analysis and model extraction. The polymorphism in our type system enables the use of general-purpose classes whose instances may serve different purposes in the computation; programmers may also hide the details of internal data structures by placing the same token on all of the objects in these data structures.

Our combined type system and analysis provide the model extraction algorithms with sound heap aliasing information. Our algorithms can therefore extract both structural models that characterize object referencing relationships and behavioral models that capture indirect interactions mediated by objects in the heap. Previous approaches, in contrast, limited by an absence of aliasing information, have focused on control-flow interactions that take place at procedure call boundaries. We have implemented our type checker, analysis, and model extraction algorithms and used them to automatically extract design models. Our experience indicates that it is straightforward to produce the token annotations and that the extracted models provide useful insight into the structure and behavior of the program.

This research was supported in part by a fellowship from Canada’s Natural Sciences and Engineering Research Council, DARPA/AFRL Contract F33615-00-C-1692, NSF Grant CCR-0086154, NSF Grant CCR-0073513, NSF Grant CCR-0209075, an Eclipse Innovation Grant, and the Singapore-MIT Alliance.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 84.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 109.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Aldrich, J., Chambers, C., Notkin, D.: Archjava: Connecting software architecture to implementation. In: 24th International Conference on Software Engineering, Orlando, FL (May 2002)

    Google Scholar 

  2. Aldrich, J., Kostadinov, V., Chambers, C.: Alias annotations for program understanding. In: Proceedings of the 17th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, Seattle, WA (November 2002)

    Google Scholar 

  3. Andersen, L.O.: Program Analysis and Specialization for the C Programming Language. PhD thesis, DIKU, University of Copenhagen (May 1994)

    Google Scholar 

  4. Bloch, J., et al.: JSR175: A metadata facility for the JavaTM programming language (April 2002)

    Google Scholar 

  5. Bokowski, B., Vitek, J.: Confined types. In: Proceedings of the 14th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, Denver, CO (November 1999)

    Google Scholar 

  6. Boyapati, C., Lee, R., Rinard, M.: Ownership types for safe programming: Preventing data races and deadlocks. In: Proceedings of the 17th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, Seattle, WA (November 2002)

    Google Scholar 

  7. Boyapati, C., Rinard, M.: A parameterized type system for race-free Java programs. In: Proceedings of the 16th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, Tampa Bay, Florida (October 2001)

    Google Scholar 

  8. Choi, J., Burke, M., Carini, P.: Efficient flow-sensitive interprocedural computation of pointer-induced aliases and side effects. In: Conference Record of the Twentieth Annual Symposium on Principles of Programming Languages, Charleston, SC. ACM, New York (1993)

    Google Scholar 

  9. Clarke, D., Drossopoulou, S.: Ownership, encapsulation and disjointness of type and effect. In: Proceedings of the 17th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, Seattle, WA (November 2002)

    Google Scholar 

  10. Clarke, D., Potter, J., Noble, J.: Ownership types for flexible alias protection. In: Proceedings of the 13th Annual Conference on Object-Oriented Programming Systems, Languages and Applications, Vancouver, Canada (October 1998)

    Google Scholar 

  11. Das, M.: Unification-based pointer analysis with directional assignments. In: Proceedings of the SIGPLAN 2000 Conference on Program Language Design and Implementation, Vancouver, Canada (June 2000)

    Google Scholar 

  12. D’Souza, D., Wills, A.: Objects, Components, and Frameworks with UML: the catalysis approach. Addison-Wesley, Reading (1998)

    Google Scholar 

  13. Ellson, J., Ganser, E., Koutsofios, E., North, S.: Graphviz, Available from http://www.research.att.com/sw/tools/graphviz

  14. Emami, M., Ghiya, R., Hendren, L.: Context-sensitive interprocedural pointsto analysis in the presence of function pointers. In: Proceedings of the SIGPLAN 1994 Conference on Program Language Design and Implementation, Orlando, FL, pp. 242–256. ACM, New York (1994)

    Chapter  Google Scholar 

  15. Fahndrich, M., Foster, J., Su, Z., Aiken, A.: Partial online cycle elimination in inclusion constraint graphs. In: Proceedings of the SIGPLAN 1998 Conference on Program Language Design and Implementation, Montreal, Canada (June 1998)

    Google Scholar 

  16. Heintze, N., Tardieu, O.: Ultra-fast aliasing using CLA: A million lines of code in a second. In: Proceedings of the SIGPLAN 2001 Conference on Program Language Design and Implementation, Snowbird, UT (June 2001)

    Google Scholar 

  17. Jackson, D., Rinard, M.: The future of software analysis. In: Finkelstein, A. (ed.) The Future of Software Engineering. ACM, New York (2000)

    Google Scholar 

  18. Jackson, D., Waingold, A.: Lightweight extraction of object models from bytecode. In: 21st International Conference on Software Engineering, Los Angeles, CA (May 1999)

    Google Scholar 

  19. Kuncak, V., Lam, P., Rinard, M.: Role analysis. In: Proceedings of the 29th Annual ACM Symposium on the Principles of Programming Languages, Portland, OR, 299 (January 2002)

    Google Scholar 

  20. Landi, W., Ryder, B.: A safe approximation algorithm for interprocedural pointer aliasing. In: Proceedings of the SIGPLAN 1992 Conference on Program Language Design and Implementation, San Francisco, CA (June 1992)

    Google Scholar 

  21. Murphy, G., Notkin, D., Sullivan, K.: Software reflexion models: Bridging the gap between source and high-level models. In: Proceedings of the ACM SIGSOFT 1995 Symposium on the Foundations of Software Engineering,Washington, DC (October 1995)

    Google Scholar 

  22. O’Callahan, R.: Generalized Aliasing as a Basis for Program Analysis Tools. PhD thesis, School of Computer Science, Carnegie Mellon Univ., Pittsburgh, PA (November 2000)

    Google Scholar 

  23. O’Callahan, R., Jackson, D.: Lackwit: A program understanding tool based on type inference. In: 1997 International Conference on Software Engineering, Boston, MA (May 1997)

    Google Scholar 

  24. Ruf, E.: Context-insensitive alias analysis reconsidered. In: Proceedings of the SIGPLAN 1995 Conference on Program Language Design and Implementation, La Jolla, CA (June 1995)

    Google Scholar 

  25. Salcianu, A., Rinard, M.: Pointer and escape analysis for multithreaded programs. In: Proceedings of the 8th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, Snowbird, UT (June 2001)

    Google Scholar 

  26. Shapiro, M., Horwitz, S.: Fast and accurate flow-insensitive points-to analysis. In: Proceedings of the 24th Annual ACM Symposium on the Principles of Programming Languages, Paris, France (January 1997)

    Google Scholar 

  27. Steensgaard, B.: Points-to analysis in almost linear time. In: Proceedings of the 23rd Annual ACM Symposium on the Principles of Programming Languages, St. Petersburg Beach, FL (January 1996)

    Google Scholar 

  28. Warmer, J., Kieppe, A.: The Object Constraint Language: Precise Modeling with UML. Addison-Wesley, Reading (1998)

    Google Scholar 

  29. Wilson, R., Lam, M.: Efficient context-sensitive pointer analysis for C programs. In: Proceedings of the SIGPLAN 1995 Conference on Program Language Design and Implementation, La Jolla, CA. ACM, New York (1995)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2003 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Lam, P., Rinard, M. (2003). A Type System and Analysis for the Automatic Extraction and Enforcement of Design Information. In: Cardelli, L. (eds) ECOOP 2003 – Object-Oriented Programming. ECOOP 2003. Lecture Notes in Computer Science, vol 2743. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-540-45070-2_13

Download citation

  • DOI: https://doi.org/10.1007/978-3-540-45070-2_13

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-40531-3

  • Online ISBN: 978-3-540-45070-2

  • eBook Packages: Springer Book Archive

Publish with us

Policies and ethics