An Opinionated Overview on Static Analysis for Java
Whole-program points-to analysis has many diverse usages, for example, call graph construction, security analysis, auto-parallelization, bug analysis, heap allocation analysis, and program debugging and understanding. As a result, many different flavors of analysis have been proposed: an analysis can be sound or unsound; context insensitive or context sensitive; flow sensitive; path sensitive; memory sensitive. We start with an overview of academic research that explains all the terms. Then we make the claim that static analysis for Java is actually much harder than it looks at the first: Reflection, JNI, Unsafe memory access, method handles, VarHandle, bootstrap methods, ... are all concepts in Java that are overlooked in many of the academic research papers. While that is acceptable for some use cases of static analysis, most real-world use cases cannot ignore it. We show how all of these dynamic features can be handled without sacrificing the precision of the analysis in the static analysis framework that we developed as part of GraalVM Native Image. The presentation will be quite example-driven: we will illustrate where a points-to analysis can successfully prove important whole-program properties that are useful for optimizations and security analysis. But we will also show examples where a points-to analysis fails to prove facts that look trivial for humans.
Resources
• In Defense of Soundiness: A Manifesto ➤
• Scalable Pointer Analysis of Data Structures Using Semantic Models ➤
• Context Sensitivity without Contexts: A Cut-Shortcut Approach to Fast and Precise Pointer Analysis ➤
• GraalVM ➤
• Inside Java ➤
• ➤
• JVMLS ➤
3,331 views
8
0
2 days ago 00:12:29 1
[The Intel Report] The Entebbe Raid - Why Did They Take the Hostages to Uganda?
3 days ago 00:23:09 2
[Asian Boss] How Overworked Are Koreans? | Street Interview
4 days ago 00:26:42 1
[The History Chap] Julius Caesar’s Invasions of Britain 55 & 54 BC
4 days ago 00:15:48 1
[The History Chap] The Shocking Truth About the Royal Navy West Africa Squadron NO ONE Tells You
4 days ago 00:14:54 3
[The History Chap] The German East Africa Campaign during World War 1. A masterclass in guerilla warfare
4 days ago 00:18:50 1
[The History Chap] The Bitter British Siege of Delhi 1857