[Soot-list] Can soot have multiple runs to collect some info beforehand?

Kelvin Tian kevinn.tian at gmail.com
Wed Jul 22 15:52:04 EDT 2009


Dear Eric,

    Great thanks for your help!  I've successfully output the line number of
the statements I want.
    But I found one problem with Soot, Soot seems to instrument functions up
to down in a class file.  Currently I output all the instrumentation just
before the return statement in main() function by adding some output
statements.  But that's on condition of that all other functions are above
main() function. If I put some functions below main() function, the
instrumentation info of those functions would not output, as Soot instrument
those functions after instrumenting main() function.   So does Soot have
some support for several runs to collect some information beforehand, which
means previous runs of soot can collect some information useful for later
runs of Soot?

   BTW, what's the good location to output all the profiling information,
other than before the return statement in main() function?


--
Best regards,
Kelvin



On Thu, Jul 16, 2009 at 2:56 PM, Eric Bodden <eric.bodden at mail.mcgill.ca>wrote:

> Hi.
>
> If by location you mean source-code line numbers then the answer is
> yes. Just use the -keep-line-number command-line flag and then look
> for a SourceLnPosTag using stmt.getTags(..). There's more on this in
> the archive of this list.
>
> Eric
>
> 2009/7/16 Kelvin Tian <kevinn.tian at gmail.com>:
> > Hi,
> >
> >      I wonder if Soot has some way to record the location of a certain
> > statement,  to build some kind of mapping between a certain statement
> (ie:
> > loop) and the location  (ie. line number in a xx class file) ?  So that I
> > can revisit a certain statement I want?  Thanks a lot for any
> suggestions!
> >
> >
> > --
> > Best regards,
> > Kelvin
> >
> > _______________________________________________
> > Soot-list mailing list
> > Soot-list at sable.mcgill.ca
> > http://mailman.cs.mcgill.ca/mailman/listinfo/soot-list
> >
> >
>
>
>
> --
> Eric Bodden
> Sable Research Group, McGill University
> Montréal, Québec, Canada
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.cs.mcgill.ca/pipermail/soot-list/attachments/20090722/f7de853b/attachment.html 


More information about the Soot-list mailing list