From forax at univ-mlv.fr Thu Mar 30 10:18:03 2017 From: forax at univ-mlv.fr (Remi Forax) Date: Thu, 30 Mar 2017 12:18:03 +0200 (CEST) Subject: Android has now a non-complete implementation of invokedynamic/java.lang.invoke by Google Message-ID: <728768696.1680200.1490869083968.JavaMail.zimbra@u-pem.fr> Hi all, looking for something unrelated in the source of the 'O' release of Android, i've spotted these new opcodes: https://android.googlesource.com/platform/libcore/+/ef44626d0ee0e65f949287932f90688dad3a97ff%5E2..ef44626d0ee0e65f949287932f90688dad3a97ff/ which correspond to invokeExact and invokeDynamic. The meat of the MethodHandle implementation is here: https://android.googlesource.com/platform/libcore/+/168dfc7fcb7594933af3bd4a66651f1eb2f09f7f/ojluni/src/main/java/java/lang/invoke/Transformers.java As far as i understand, it's implemented by reifying things like a StackFrame and stack reader/writer in Java (somewhat similar to the StackWalker implementation of JDK 9). The varargs collector/invoke (invokeGeneric) doesn't seem to be implemented (yet) and there is no trusted lookup. cheers, R?mi