[Soot-list] Any way to get a local (1-level) call graph?

Eric Bodden bodden at st.informatik.tu-darmstadt.de
Thu Jan 21 02:48:21 EST 2010


Hello.

Since a couple of weeks* (you have to grab the latest SVN build from
http://plg.uwaterloo.ca/~olhotak/build/) there's two things you can
do:

1.) Code it yourself - should not be hard.
2.) Use Spark, probably in CHA mode, in combination with the
-allow-phantom-refs option. This option models all classes that Soot
cannot find on the classpath as empty "phantom classes". So if you
only supply the one class that you are interested in to Soot then you
should be obtaining that partial call graph you are looking for.

Eric

*  -allow-phantom-refs was broken for years but Syed Albiz, Patrick
Lam and I got this fixed a short while ago.

--
Eric Bodden
Software Technology Group, Technische Universität Darmstadt, Germany
Tel: +49 6151 16-5478    Fax: +49 6151 16-5410
Mailing Address: S2|02 A209, Hochschulstraße 10, 64289 Darmstadt



2010/1/20 Sai Zhang <racezhang at gmail.com>:
> Hi all:
>
> I am wondering if there is any way to get a local call graph in Soot,
> without using the "-w" mode and a main entry?
>
> Take the following code as an example:
>
> m() {
>   m1();
>   m2();
> }
>
> m1() {
>   m1'();
>   ...
> }
>
> I just want a simple local call graph containing edges:
> m() -> m1() (and all m1's overriden methods)
> m() -> m2()  (and all m2's overriden methods)
>
> Thought that should not be hard to implement oneself, if there is some
> built-in functions in Soot to achieve that goal, it will be great!
>
> Thanks.
>
>
>
> -- Sai
>
> _______________________________________________
> Soot-list mailing list
> Soot-list at sable.mcgill.ca
> http://mailman.cs.mcgill.ca/mailman/listinfo/soot-list
>
>


More information about the Soot-list mailing list