[Soot-list] Imprecise pointer analysis by Spark

Ondřej Lhoták olhotak at uwaterloo.ca
Thu Oct 6 09:58:29 EDT 2016


There are no allocation sites of the class
org.apache.lucene.store.FSDirectory
in the Lucene codebase. The class is instantiated at runtime using
reflection. You need to tell this to Spark. This can normally be done
using Soot's -dynamic-class option, but presumably the Tamiflex support
in Soot also does this. I suggest that you check the Tamiflex file to
see whether it mentions this class. If it does not, then the problem is
with the Tamiflex dynamic monitoring. If it does, then the problem is
with the Soot Tamiflex support not correctly considering the dynamically
loaded class.

Ondřej

On Thu, Oct 06, 2016 at 03:49:35PM +0530, Sridhar Gopinath wrote:
> Hi,
> 
> I am trying to do pointer-analysis on DaCapo-9.12-bach benchmark with Soot and Tamiflex.
> I want to get the set of classes an object may point to at runtime.
> 
> I get this information by doing 'Scene.v().getPointsToAnalysis().reachingObjects(local).possibleTypes();'.
> 
> On luindex, I see that the possibleTypes() is being imprecise i.e. the runtime class is not present in the set of possible types.
> 
> Complete details:
> Method: org.apache.lucene.store.IndexInput.readVInt()
> Callsite: this.readByte();
> 
> Spark reported possible class types for 'this' local:
> org.apache.lucene.index.CompoundFileReader$CSIndexInput
> org.apache.lucene.store.ChecksumIndexInput
> org.apache.lucene.index.ByteSliceReader
> 
> Actual runtime class:
> org.apache.lucene.store.FSDirectory$FSIndexInput
> 
> Can anyone please help me in understanding why Spark is being imprecise and how do I rectify this?
> Does using Paddle or setting any phase options for Spark help?
> Any help is greatly appreciated.
> Thanks.
> 
> 
> My command line arguments are:
> java -cp soot-trunk.jar:bin/ Analysis.Main -w -app -pp -p cg.spark enabled:true -p cg reflection-log:out/refl.log -p jb use-original-names:true -include org.apache. -include org.w3c. -keep-line-number -no-bodies-for-excluded -cp out/:jar/hook.jar -main-class Harness Harness -f class -output-dir sootified -validate
> 
> Regards,
> Sridhar Gopinath,
> Scalable Software Systems lab,
> CSA, Indian Institute of Science,
> Bangalore.
> 
> -- 
> This message has been scanned for viruses and
> dangerous content by MailScanner, and is
> believed to be clean.
> 
> _______________________________________________
> Soot-list mailing list
> Soot-list at CS.McGill.CA
> https://mailman.CS.McGill.CA/mailman/listinfo/soot-list
> 


More information about the Soot-list mailing list