Abstract
We demonstrate how to map a control-flow analysis for a higher-order language (dynamic languages are typically higher-order) into a pointer analysis for a first-order language, such as C. This allows us to use existing pointer analysis tools to perform a control-flow analysis, exploiting their technical advancements and the engineering effort that went into developing them. We compare the results of two recent parallel pointer analysis tools with a parallel control-flow analysis tool. While it has been known that a control-flow analysis of higher-order languages and a pointer analysis of first-order languages are very similar, we demonstrate that these two analyses are actually more similar than previously thought. We present the first mapping between a high-order control-flow analysis and a pointer analysis.
- L. O. Andersen. Program Analysis and Specialization for the C Programming Language. PhD thesis, DIKU, University of Copenhagen, May 1994.Google Scholar
- A. W. Appel. Compiling with Continuations. Cambridge University Press, New York, NY, USA, 2007. Google Scholar
Digital Library
- J. M. Ashley and R. K. Dybvig. A practical and flexible flow analysis for Higher-Order languages. ACM Transactions on Programming Languages and Systems, 20(4):845–868, 1998. Google Scholar
Digital Library
- C. Earl, I. Sergey, M. Might, and D. Van Horn. Introspective pushdown analysis of higher-order programs. In Proceedings of the 17th ACM SIGPLAN International Conference on Functional Programming, ICFP ’12, pages 177–188, New York, NY, USA, 2012. ACM. Google Scholar
Digital Library
- A. Guha, C. Saftoiu, and S. Krishnamurthi. The essence of JavaScript. In T. D’Hondt, editor, ECOOP 2010 Object-Oriented Programming, volume 6183 of Lecture Notes in Computer Science, pages 126–150. Springer Berlin Heidelberg, 2010. Google Scholar
Digital Library
- F. Henglein. Simple closure analysis. Technical report, Department of Computer Science, University of Copenhagen (DIKU), Mar. 1992.Google Scholar
- O. Lhotak, Y. Smaragdakis, and M. Sridharan. Pointer analysis (dagstuhl seminar 13162). Dagstuhl Reports, 3(4):91–113, 2013.Google Scholar
- M. Méndez-Lojo, A. Mathew, and K. Pingali. Parallel inclusion-based points-to analysis. In Proceedings of the ACM International Conference on Object Oriented Programming Systems Languages and Applications, OOPSLA ’10, pages 428–443, New York, NY, USA, 2010. ACM. Google Scholar
Digital Library
- M. Méndez-Lojo, M. Burtscher, and K. Pingali. A GPU implementation of inclusion-based points-to analysis. In Proceedings of the 17th ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, PPoPP ’12, pages ples and Practice of Parallel Programming, PPoPP ’12, pages 107–116, New York, NY, USA, 2012. ACM. Google Scholar
Digital Library
- M. Might, Y. Smaragdakis, and D. Van Horn. Resolving and exploiting the k-CFA paradox: Illuminating functional vs. Object-Oriented program analysis. In Proceedings of the 31st Conference on Programming Language Design and Implementation (PLDI 2006), pages 305–315, Toronto, Canada, June 2010. Google Scholar
Digital Library
- J. Palsberg. Closure analysis in constraint form. ACM Transactions on Programming Languages and Systems, 17(1):47– 62, Jan. 1995. Google Scholar
Digital Library
- J. G. Politz, A. Martinez, M. Milano, S. Warren, D. Patterson, J. Li, A. Chitipothu, and S. Krishnamurthi. Python: The full monty. In Proceedings of the 2013 ACM SIGPLAN International Conference on Object Oriented Programming Systems Languages & Applications, OOPSLA ’’13, pages 217– 232, New York, NY, USA, 2013. ACM. ISBN 978-1-4503- 2374-1. Google Scholar
Digital Library
- T. Prabhu, S. Ramalingam, M. Might, and M. Hall. EigenCFA: Accelerating flow analysis with GPUs. In Proceedings of the 38th Annual ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL ’11, pages 511–522, New York, NY, USA, 2011. ACM. Google Scholar
Digital Library
- B. Steensgaard. Points-to analysis in almost linear time. In Proceedings of the 23rd ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL ’96, pages 32–41, New York, NY, USA, 1996. ACM. Google Scholar
Digital Library
- D. Vardoulakis and O. Shivers. CFA2: a Context-Free Approach to Control-Flow Analysis. In European Symposium on Programming, pages 570–589, 2010. Google Scholar
Digital Library
- S. H. Yong, S. Horwitz, and T. Reps. Pointer analysis for programs with structures and casting. In Proceedings of the ACM SIGPLAN 1999 Conference on Programming Language Design and Implementation, PLDI ’99, pages 91–103, New York, NY, USA, 1999. ACM. Google Scholar
Digital Library
Index Terms
Control-flow analysis of dynamic languages via pointer analysis
Recommendations
Control-flow analysis of dynamic languages via pointer analysis
DLS 2015: Proceedings of the 11th Symposium on Dynamic LanguagesWe demonstrate how to map a control-flow analysis for a higher-order language (dynamic languages are typically higher-order) into a pointer analysis for a first-order language, such as C. This allows us to use existing pointer analysis tools to perform ...
Interprocedural pointer alias analysis
We present practical approximation methods for computing and representing interprocedural aliases for a program written in a language that includes pointers, reference parameters, and recursion. We present the following contributions: (1) a framework ...
Semi-sparse flow-sensitive pointer analysis
POPL '09Pointer analysis is a prerequisite for many program analyses, and the effectiveness of these analyses depends on the precision of the pointer information they receive. Two major axes of pointer analysis precision are flow-sensitivity and context-...






Comments