[Soot-list] How to generate Jimple code? (re: How to get my args pointcut to match?)

Eric Bodden eric.bodden at ec-spride.de
Thu Dec 20 03:43:52 EST 2012


Hi John.

> In the email below this one, it was also suggested that I generate Jimple code to an output file to see if that provides any clues. In writing my loopPar pointcut, I never generated Jimple code to an output file. Over the past several days, I've tried to do that, but no luck so far.
>
> My build.xml file includes this line:
>
> <arg line="-O0 +soot -f J -soot -sourceroots sandbox/loopPar -d sandbox/aj/out/loopPar"/>
>
> Unfortunately, that does not appear to generate any .jimple file (and no file generated in the output directory, sandbox/aj/out/loopPar).

That's odd. I suspect some setup problem. Maybe you should run abc
directly from the command line...

java abc.main.Main <commandLine>

> Error: Could not find or load main class soot.Main
>
> The tutorial page says that that is an indication that soot is not installed properly. That is surprising because I installed something way back in June, and I've been successfully compiling and running my new loopPar pointcut for quite a while.

Apparently you provided an incorrect classpath.

> But maybe I installed abc without installing the part of soot that's needed to generate Jimple? In my installation directories, I see lots of mentions of soot (including soot subdirectories), so I know I've something installed with soot.

That's impossible. Abc comprises a full installation of Soot.

> 1. Do you have any suggestions for how to get my soot working so I can generate Jimple code to an output file (so I can make progress on my args pointcut issue)? Is there a way to do it without having to do a complete reinstallation of everything?

I don't think you need to reinstall anything. You just need to learn
to understand how to configure java applications like Soot/abc and run
them.

> abc:  [javac] c:\000parallelLoops\parallelLoops\abc-1.3.0-transcut-4.0\abc\build.xml:157: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
>
> If you have any thoughts about that warning, let me know.

I think this can be ignored.



Ideally you would have a setup where you run abc directly from within
Eclipse or you favorite IDE. That's how I debug abc. When doing so you
can set breakpoints into the actual pointcut-matching machinery and
just *observe* why it does not match. It should be simple to set up -
just define an appropriate run configuration.

Eric


More information about the Soot-list mailing list