[Soot-list] Running Heros with Soot

SRIRAM BALASUBRAMANIAN 160070012 at iitb.ac.in
Tue Jun 5 15:50:28 EDT 2018


Hi,

I am trying to run an IFDS example using Heros on a test program, but I am
struggling with it. I am running this on the terminal where I have the
sootclasses-trunk-jar-with-dependencies.jar ( Nightly build - June 1
version) and Hello.class (which just prints Hello) in my working
directory.

 java -cp sootclasses-trunk-jar-with-dependencies.jar
soot.jimple.toolkits.ide.Main -w -cp
.:/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/rt.jar Hello -pp

I expected it to run a possible types analysis on the Hello program.

The javac version is 1.8.0_171 and java(run time) version is 1.8.0_171.
Hello.java has the following code:

public class Hello{
    public static void main(String args[]){
        System.out.println("Hello");
    }
}

The error is as follows:

[Thread-1] ERROR heros.solver.CountingThreadPoolExecutor - Worker thread
execution failed: Index: 0, Size: 0
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
    at java.util.ArrayList.rangeCheck(ArrayList.java:657)
    at java.util.ArrayList.get(ArrayList.java:433)
    at
soot.jimple.toolkits.ide.exampleproblems.IFDSPossibleTypes$1$3.computeTargets(IFDSPossibleTypes.java:167)
    at
soot.jimple.toolkits.ide.exampleproblems.IFDSPossibleTypes$1$3.computeTargets(IFDSPossibleTypes.java:161)
    at
heros.ZeroedFlowFunctions$ZeroedFlowFunction.computeTargets(ZeroedFlowFunctions.java:58)
    at heros.solver.IDESolver.computeCallFlowFunction(IDESolver.java:426)
    at heros.solver.IDESolver.processCall(IDESolver.java:355)
    at heros.solver.IDESolver.access$000(IDESolver.java:69)
    at heros.solver.IDESolver$PathEdgeProcessingTask.run(IDESolver.java:894)
    at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
Exception in thread "Thread-1" java.lang.RuntimeException: There were
exceptions during IDE analysis. Exiting.
    at
heros.solver.IDESolver.runExecutorAndAwaitCompletion(IDESolver.java:274)
    at
heros.solver.IDESolver.awaitCompletionComputeValuesAndShutdown(IDESolver.java:243)
    at heros.solver.IDESolver.solve(IDESolver.java:217)
    at
soot.jimple.toolkits.ide.JimpleIFDSSolver.solve(JimpleIFDSSolver.java:57)
    at soot.jimple.toolkits.ide.Main$1.internalTransform(Main.java:49)
    at soot.SceneTransformer.transform(SceneTransformer.java:39)
    at soot.Transform.apply(Transform.java:105)
    at soot.ScenePack.internalApply(ScenePack.java:38)
    at soot.Pack.apply(Pack.java:120)
    at soot.PackManager.runWholeProgramPacks(PackManager.java:608)
    at soot.PackManager.runPacksNormally(PackManager.java:492)
    at soot.PackManager.runPacks(PackManager.java:416)
    at soot.Main.run(Main.java:272)
    at soot.Main.main(Main.java:144)
    at soot.jimple.toolkits.ide.Main.main(Main.java:53)
Caused by: java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
    at java.util.ArrayList.rangeCheck(ArrayList.java:657)
    at java.util.ArrayList.get(ArrayList.java:433)
    at
soot.jimple.toolkits.ide.exampleproblems.IFDSPossibleTypes$1$3.computeTargets(IFDSPossibleTypes.java:167)
    at
soot.jimple.toolkits.ide.exampleproblems.IFDSPossibleTypes$1$3.computeTargets(IFDSPossibleTypes.java:161)
    at
heros.ZeroedFlowFunctions$ZeroedFlowFunction.computeTargets(ZeroedFlowFunctions.java:58)
    at heros.solver.IDESolver.computeCallFlowFunction(IDESolver.java:426)
    at heros.solver.IDESolver.processCall(IDESolver.java:355)
    at heros.solver.IDESolver.access$000(IDESolver.java:69)
    at heros.solver.IDESolver$PathEdgeProcessingTask.run(IDESolver.java:894)
    at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
    at java.util.ArrayList.rangeCheck(ArrayList.java:657)
    at java.util.ArrayList.get(ArrayList.java:433)
    at
soot.jimple.toolkits.ide.exampleproblems.IFDSPossibleTypes$1$3.computeTargets(IFDSPossibleTypes.java:167)
    at
soot.jimple.toolkits.ide.exampleproblems.IFDSPossibleTypes$1$3.computeTargets(IFDSPossibleTypes.java:161)
    at
heros.ZeroedFlowFunctions$ZeroedFlowFunction.computeTargets(ZeroedFlowFunctions.java:58)
    at heros.solver.IDESolver.computeCallFlowFunction(IDESolver.java:426)
    at heros.solver.IDESolver.processCall(IDESolver.java:355)
    at heros.solver.IDESolver.access$000(IDESolver.java:69)
    at heros.solver.IDESolver$PathEdgeProcessingTask.run(IDESolver.java:894)
    at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)


Can anyone let me know what I am doing wrong? I just want to run an
out-of-the-box IFDS analysis as of now, using one of the pre-existing
examples, and then define my own flow functions later on.


Thanks and regards,

Sriram



More information about the Soot-list mailing list