[Soot-list] References to signature polymorphic models

Jens Dietrich j.b.dietrich at massey.ac.nz
Wed Feb 3 04:40:08 EST 2016


Hi,

I came across the following problem when trying to use doop + soot (2.5.0) to extract facts from JRE 7. Soot fails with the following exception: 

Error while processing method: 
<java.lang.invoke.BoundMethodHandle: java.lang.invoke.MethodHandle bindSingle(java.lang.invoke.MethodType,java.lang.invoke.LambdaForm,char,java.lang.Object)>

soot.SootMethodRefImpl$ClassResolutionFailedException: Class java.lang.invoke.MethodHandle doesn't have method invokeBasic([java.lang.invoke.MethodType, java.lang.invoke.LambdaForm, int]) : java.lang.invoke.BoundMethodHandle; 

…    

Indeed, such a method does not exist in java.lang.invoke.MethodHandle, but there is the signature polymorphic invokeBasic method. I assume that what happens here is what is described in https://docs.oracle.com/javase/7/docs/api/java/lang/invoke/MethodHandle.html <https://docs.oracle.com/javase/7/docs/api/java/lang/invoke/MethodHandle.html> : “In source code, a call to a signature polymorphic method will compile, regardless of the requested symbolic type descriptor. As usual, the Java compiler emits an invokevirtual instruction with the given symbolic type descriptor against the named method. The unusual part is that the symbolic type descriptor is derived from the actual argument and return types, not from the method declaration.”. However, this seems to break soot. 

Any advice how to avoid this problem ? BTW, I have tried to use the latest nightly build with doop, but run into other problems with this.


Thanks in advance for any hint ! 

Cheers, Jens



-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://mailman.CS.McGill.CA/pipermail/soot-list/attachments/20160203/197c5491/attachment.html 


More information about the Soot-list mailing list