* Vladimir Ivanov:
>> Is it true that there is no shortcut for obtaining a method handle for
>> some code fragment?
>>
>> That is, there is no way to write something like this?
>>
>>MethodHandle repeatIt = (String x) -> x + x;
>>
>> Instead it's necessary to give the expression a name and
Is it true that there is no shortcut for obtaining a method handle for
some code fragment?
That is, there is no way to write something like this?
MethodHandle repeatIt = (String x) -> x + x;
Instead it's necessary to give the expression a name and put it into a
static method somewhere, and
don't use the class loader which was used to define the class to
look up the name?
--
Florian Weimer / Red Hat Product Security
___
mlvm-dev mailing list
mlvm-dev@openjdk.java.net
http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev
classes look very useful for run-time code generation.
--
Florian Weimer / Red Hat Product Security
___
mlvm-dev mailing list
mlvm-dev@openjdk.java.net
http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev
construct of the same name.
--
Florian Weimer / Red Hat Product Security
___
mlvm-dev mailing list
mlvm-dev@openjdk.java.net
http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev
* Remi Forax:
Even a simple code like the one below, there is no scalar replacement
(OSR or not),
Float f = new Float(0);
for(int i=0; ilength; i++) {
f = new Float(f + 1.0f);
}
float result = f;
System.out.println(result);
Last time I looked at this,
* John Rose:
As I recall, Doug Lea noted at the 2010 JVM Language Summit that
tail calls would seem to allow work-stealing algorithms to be
implemented somewhat more cleanly or efficiently. (How's that for
tentative?) A worker thread goes from task to task in a data-driven
way, similar to
* Remi Forax:
I would be surprised if tail calls give more flexibility. Usually
it's the opposite, the mini-interpreter wins in terms of flexibility:
http://www.enyo.de/fw/notes/tail-calls.html
This trick can work with a lexer because usually you don't keep states
between each
and enumConstantDirectory seem good candidates (callers
cache the value anyway or do additional work while accessing the field).
--
Florian Weimerfwei...@bfk.de
BFK edv-consulting GmbH http://www.bfk.de/
Kriegsstraße 100 tel: +49-721-96201-1
D-76133 Karlsruhe fax: +49