Caching reflection

76 views
Skip to first unread message

Timothy Pratley

unread,
Sep 28, 2009, 2:47:33 AM9/28/09
to Clojure Dev
I came across this idea in an older thread:
http://groups.google.com.au/group/clojure/browse_thread/thread/d3802c761ffbef69

On the surface it sounds like a great idea to me! Are there any
downsides? Is this planned for inclusion? I can run some benchmarks or
something if that's useful?


Regards,
Tim.

Rich Hickey

unread,
Sep 28, 2009, 12:44:56 PM9/28/09
to cloju...@googlegroups.com

If there is to be any caching of reflection, that should occur within
the reflection API. That may or may not happen, as evidenced by
Dalvik.

The real answer for the JDK proper is JSR 292, which allows for the
proper construction of call site caches with performance much better
than memoizaton.

I intend to spend some more time with JSR 292 soon, and would welcome
others who want to work on this. It can speed up reflection and,
potentially, multimethod dispatch.

People interested in participating should join the JVM languages group:

http://groups.google.com/group/jvm-languages

and check out the Da Vinci machine project:

http://www.openjdk.org/projects/mlvm/

as well as Rémi Forax's backport:

http://weblogs.java.net/blog/2009/07/01/jsr292-backport-first-release

Regards,

Rich

Timothy Pratley

unread,
Sep 28, 2009, 9:49:21 PM9/28/09
to Clojure Dev
> The real answer for the JDK proper is JSR 292, which allows for the
> proper construction of call site caches with performance much better
> than memoizaton.

> People interested in participating should join the JVM languages group:

Very cool, thanks for info. That makes a lot of sense.
Reply all
Reply to author
Forward
0 new messages