Scaling Java Points-to Analysis Using Spark

  • Ondřej Lhoták
  • Laurie Hendren
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 2622)


Most points-to analysis research has been done on different systems by different groups, making it difficult to compare results, and to understand interactions between individual factors each group studied. Furthermore, pointsto analysis for Java has been studied much less thoroughly than for C, and the tradeoffs appear very different. We introduce Spark, a flexible framework for experimenting with points-to analyses for Java. Spark supports equality- and subset-based analyses, variations in field sensitivity, respect for declared types, variations in call graph construction, off-line simplification, and several solving algorithms. Spark is composed of building blocks on which new analyses can be based.

We demonstrate Spark in a substantial study of factors affecting precision and efficiency of subset-based points-to analyses, including interactions between these factors. Our results show that Spark is not only flexible and modular, but also offers superior time/space performance when compared to other points-to analysis implementations.


Variable Node Call Graph Class Library Call Site Order Binary Decision Diagram 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


  1. 5.
    A. Aiken, M. Fähndrich, J. S. Foster, and Z. Su. Atoolkit for constructing type-and constraintbased program analyses. In Types in Compilation, Second International Workshop, TIC’ 98, volume 1473 of LNCS, pages 78–96, 1998.Google Scholar
  2. 6.
    L. O. Andersen. Program Analysis and Specialization for the C Programming Language. PhD thesis, University of Copenhagen, May 1994. (DIKU report 94/19).Google Scholar
  3. 7.
    D. F. Bacon and P. F. Sweeney. Fast static analysis ofC++virtual function calls. In Proceedings of the 1996 OOPSLA, pages 324–341, 1996.Google Scholar
  4. 8.
    M. Das. Unification-based pointer analysis with directional assignments. In Proceedings of PLDI’00, volume 35.5of ACM Sigplan Notices, pages 35–46, June 2000.CrossRefGoogle Scholar
  5. 9.
    J. Dean, D. Grove, and C. Chambers. Optimization of object-oriented programs using static class hierarchy analysis. In ECOOP’95-Object-Oriented Programming, 9th European Conference, volume 952 of LNCS, pages 77–101, Aug. 1995.Google Scholar
  6. 10.
    A. Diwan, K. S. McKinley, and J. E. B. Moss. Type-based alias analysis. In Proceedings of PLDI’98, pages 106–117, 1998.Google Scholar
  7. 11.
    M. Emami, R. Ghiya, and L. J. Hendren. Context-sensitive interprocedural points-to analysis in the presence of function pointers. In Proceedings of PLDI’94, pages 242–256, 1994.Google Scholar
  8. 12.
    M. Fähndrich, J. S. Foster, Z. Su, and A. Aiken. Partial online cycle elimination in inclusion constraint graphs. In Proceedings of PLDI’98, pages 85–96, June 1998.Google Scholar
  9. 13.
    N. Heintze. Analysis of large code bases: The compile-link-analyze model., 1999.
  10. 14.
    N. Heintze and O. Tardieu. Demand-driven pointer analysis. In Proceedings of PLDI’01, pages 24–34, 2001.Google Scholar
  11. 15.
    N. Heintze and O. Tardieu. Ultra-fast aliasing analysis using CLA:A million lines of C code in a second. In Proceedings of PLDI’01, volume 36.5 of ACM SIGPLAN Notices, pages 254–263, June 2001.CrossRefGoogle Scholar
  12. 16.
    M. Hind. Pointer analysis: Haven’t we solved this problem yet? In Proceedings of PASTE’01, pages 54–61, June 2001.Google Scholar
  13. 17.
    D. Liang, M. Pennings, and M. J. Harrold. Extending and evaluating flow-insensitive and context-insensitive points-to analyses for Java. In Proceedings of PASTE’01, pages 73–79, 2001.Google Scholar
  14. 18.
    P. Pominville, F. Qian, R. Vallée-Rai, L. Hendren, and C. Verbrugge. A framework for optimizing Java using attributes. In Compiler Construction (CC 2001), volume 2027 of LNCS, pages 334–554, 2001.CrossRefGoogle Scholar
  15. 19.
    A. Rountev and S. Chandra. Off-line variable substitution for scaling points-to analysis. In Proceedings of PLDI’00, pages 47–56, Jun 2000.Google Scholar
  16. 20.
    A. Rountev, A. Milanova, and B. G. Ryder. Points-to analysis for Java using annotated constraints. In Proceedings of the 2001 OOPSLA, pages 43–55, 2001.Google Scholar
  17. 21.
    M. Shapiro and S. Horwitz. Fast and accurate flow-insensitive points-to analysis. In Conference Record of 24th POPL’ 97, pages 1–14, Jan. 1997.Google Scholar
  18. 22.
    B. Steensgaard. Points-to analysis in almost linear time. In Conference Record of 23rd POPL’96, pages 32–41, Jan. 1996.Google Scholar
  19. 23.
    Z. Su, M. Fähndrich, and A. Aiken. Projection merging: reducing redundancies in inclusion constraint graphs. In Proceedings of the 27th POPL’00, pages 81–95, 2000.Google Scholar
  20. 24.
    V. Sundaresan, L. Hendren, C. Razafimahefa, R. Vallée-Rai, P. Lam, E. Gagnon, and C. Godin. Practical virtual method call resolution for Java. In Proceedings of the 2000 OOPSLA, pages 264–280, 2000.Google Scholar
  21. 25.
    R. E. Tarjan. Efficiency of a good but not linear set union algorithm. Journal of the AC (JACM), 22(2):215–225, 1975.zbMATHMathSciNetCrossRefGoogle Scholar
  22. 26.
    R. Vallée-Rai, E. Gagnon, L. J. Hendren, P. Lam, P. Pominville, and V. Sundaresan. Optimizing Java bytecode using the Soot framework: Is it feasible? In Compiler Construction (CC 2000), volume 1781 of LNCS, pages 18–34, 2000.CrossRefGoogle Scholar
  23. 27.
    J. Whaley and M. Lam. An efficient inclusion-based points-to analysis for strictly-typed languages. In Static Analysis 9th International Symposium, SAS 2002, volume 2477 of LNCS, pages 180–195, 2002.Google Scholar

Copyright information

© Springer-Verlag Berlin Heidelberg 2003

Authors and Affiliations

  • Ondřej Lhoták
    • 1
  • Laurie Hendren
    • 1
  1. 1.Sable Research GroupMcGill UniversityMontrealCanada

Personalised recommendations