soba

SOBA (Simple Objects for Bytecode Analysis) is a toolkit for program analysis on Java bytecode. It wraps ASM library ( http://asm.ow2.org/ ) to easily access Java class and method information.

SOBA enables a Java program to extract control dependence, data dependence, method calls, and class inheritance relationships from Java bytecode. Compared with famous tools such as Soot and WALA, SOBA intentionally focuses on a small set of features in order to be an easy-to-learn, lightweight toolkit.

We provide example source code as follows. Each class implements a main method that takes as input directories and jar files including class files to be analyzed.

File NameFeature
CallGraphPerformance.java An example prgoram extracting method call relationships from class files
ClassHierarchyPerformance.java An example prgoram extracting class inheritance relationships and resolving dynamic binding
ControlAndDataDependencePerformance.java An example program extracting intra-procedural control dependence and data dependence
DumpAnalysisClass.java An example program extracting class names

Note: We have commented out some "println" statements in the examples in order to replicate a performance comparison with Soot and WALA described in an article about SOBA in JSSST Compute Software (in Japanese). Please remove "//" in prior to use the examples.

Download SOBA

Installation: SOBA is dependent on ASM 5.0.x, GNU Trove 3.0.x, and Hamcrest 1.3. Please include soba-core.jar and their JAR files in your classpath.

SOBA is distributed under the MIT License. LICENSE.txt includes the details.

OSDNGroup Sites
SRAD | OSDN Corporation