[Soot-list] Paddle: All points-to sets of a field

Michael Pradel michael at binaervarianz.de
Sun Jan 17 08:20:26 EST 2010


> I am a bit confused because first you say that you want a
> context-sensitive analysis and then you want to project the context
> away again (by joining over all c). So why use a context-sensitive
> analysis in the first place? For example, if you just use Spark, which
> is context-insensitive, with a field-based mode (see
> http://www.sable.mcgill.ca/soot/tutorial/phase/) then this will join
> together the results for "all host objects".

I don't want to join the results of all objects but analyze how the
points-to sets of different host objects differ.

> To find all statements that access a field f you would need to iterate
> through all method bodies of the program. For every statement you can
> check containsFieldRef(). Then you can check the field reference to
> see if it points to the field you are looking for. Last but not least
> you could then use the results of the points-to analysis to see which
> of these field accesses may access the same host object.
>
> Do you think this would work?

Yes, but I don't see how to get the information from the points-to
analysis. Imagine we have two instances of A, a1 and a2, and three
instances of B, b1 to b3. Let's have the following assignments to A's
field f somewhere in the program:
  a1.f = b1   // in context c1
  a2.f = b2   // in context c2
  a2.f = b3   // in context c3
I want to get two points-to sets, namely
  P2S(a1) = {b1}       // joined over contexts of a1
  P2S(a2) = {b2, b3}   // joined over contexts of a2

To get them from PointsToAnalysis.reachingObjects(ctx,local,field), I
need the contexts in which the assignments happen (c1 to c3). How can I
get them?


Thanks again!
Michael

-- 
michael at binaervarianz.de
GPG Fingerprint 2069 ED1D 7A80 E35E F4C9  43CF D4E0 57FC 7B97 6D4F

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: OpenPGP digital signature
Url : http://mailman.cs.mcgill.ca/pipermail/soot-list/attachments/20100117/2d92d352/attachment.bin 


More information about the Soot-list mailing list