wala / WALA

T.J. Watson Libraries for Analysis, with frontends for Java, Android, and JavaScript, and may common static program analyses
http://github.com/wala/WALA
Eclipse Public License 2.0
763 stars 221 forks source link

Wala crashes on analyzing bobo #35

Open drzhonghao opened 11 years ago

drzhonghao commented 11 years ago

When I use Wala to build call graphs for bobo, it crashes. The source files of bobo can be downloaded from https://github.com/javasoze/bobo

The stack is as follows: com.ibm.wala.util.debug.UnimplementedError: unexpected instance key [<src-class: Lcom/browseengine/bobo/util/ListMerger$MergedIterator] at com.ibm.wala.util.debug.Assertions.UNREACHABLE(Assertions.java:55) at com.ibm.wala.cast.ipa.callgraph.AstSSAPropagationCallGraphBuilder$AstConstraintVisitor$5.act(AstSSAPropagationCallGraphBuilder.java:681) at com.ibm.wala.util.intset.SparseIntSet.foreach(SparseIntSet.java:438) at com.ibm.wala.util.intset.MutableSharedBitVectorIntSet.foreach(MutableSharedBitVectorIntSet.java:269) at com.ibm.wala.cast.ipa.callgraph.AstSSAPropagationCallGraphBuilder$AstConstraintVisitor.getLexicalDefiners(AstSSAPropagationCallGraphBuilder.java:670) at com.ibm.wala.cast.ipa.callgraph.AstSSAPropagationCallGraphBuilder$AstConstraintVisitor.access$1(AstSSAPropagationCallGraphBuilder.java:643) at com.ibm.wala.cast.ipa.callgraph.AstSSAPropagationCallGraphBuilder$AstConstraintVisitor$LexicalOperator.doLexicalPointerKeys(AstSSAPropagationCallGraphBuilder.java:582) at com.ibm.wala.cast.ipa.callgraph.AstSSAPropagationCallGraphBuilder$AstConstraintVisitor$LexicalOperator.access$1(AstSSAPropagationCallGraphBuilder.java:573) at com.ibm.wala.cast.ipa.callgraph.AstSSAPropagationCallGraphBuilder$AstConstraintVisitor.visitLexical(AstSSAPropagationCallGraphBuilder.java:314) at com.ibm.wala.cast.ipa.callgraph.AstSSAPropagationCallGraphBuilder$AstConstraintVisitor.visitAstLexicalWrite(AstSSAPropagationCallGraphBuilder.java:355) at com.ibm.wala.cast.ir.ssa.AstLexicalWrite.visit(AstLexicalWrite.java:95) at com.ibm.wala.ipa.callgraph.propagation.SSAPropagationCallGraphBuilder.addBlockInstructionConstraints(SSAPropagationCallGraphBuilder.java:277) at com.ibm.wala.ipa.callgraph.propagation.SSAPropagationCallGraphBuilder.addNodeInstructionConstraints(SSAPropagationCallGraphBuilder.java:256) at com.ibm.wala.ipa.callgraph.propagation.SSAPropagationCallGraphBuilder.unconditionallyAddConstraintsFromNode(SSAPropagationCallGraphBuilder.java:229) at com.ibm.wala.ipa.callgraph.propagation.SSAPropagationCallGraphBuilder.addConstraintsFromNode(SSAPropagationCallGraphBuilder.java:195) at com.ibm.wala.ipa.callgraph.propagation.PropagationCallGraphBuilder.addConstraintsFromNewNodes(PropagationCallGraphBuilder.java:338) at com.ibm.wala.ipa.callgraph.propagation.StandardSolver.solve(StandardSolver.java:58) at com.ibm.wala.ipa.callgraph.propagation.PropagationCallGraphBuilder.makeCallGraph(PropagationCallGraphBuilder.java:263) at com.ibm.wala.client.AbstractAnalysisEngine.buildCallGraph(AbstractAnalysisEngine.java:136)

msridhar commented 11 years ago

@drzhonghao can you provide more details on how to reproduce? I.e., what are all the steps after cloning the bobo repository?

drzhonghao commented 11 years ago

I tried to build a call graph for a method in Bobo. The method calls Lcom/browseengine/bobo/util/ListMerger$MergedIterator, and Wala throws the exception when It analyzes Lcom/browseengine/bobo/util/ListMerger$MergedIterator. Perhaps, you can reproduce the problem, if you try to build a call graph that calls the specific method.