> A branch is certainly a possibility. But from what I've heard, the primary
> benefit of invokedynamic is convenience for language implementors. The
> performance benefits, if any, are modest.

If your language is doing dynamic dispatch a lot, invokedynamic can be
game-changing since suddenly the JIT has the potential to optimize in
ways similar to invokevirtual.

As far as I know, the main issue with clojure is that it is not heavy
on dynamic dispatch. Regular function calls and protocols don't
benefit from invokedynamic I think, so the performance benefit would
seem to be less than for something like groovy/ruby/python/etc. If
you're doing normal invokevirtual/invokestatic calls on types of known
type, and the performance impact is coming from things like boxing and
the fundamental nature of the data structures, I don't believe
invokedynamic will be expected to help much in the general case (but I
am certainly no expert here).

Would not multimethods be the main candidate for invokedynamic?

-- 
/ Peter Schuller

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to