Perhaps, though the opt-in wouldn't be per object, it would be per
class. You'd essentially specify that you want to use instance vars or
singletons with a given Java type.
I will probably at least try to mock up the lazy ivar logic, which
seems like it could work. The singleton logic...that's
Could the opt-in be in the form of a command line opt or a require 'somenewlib'
which would likely be a lot easier to port and more clean than calling a method
per object?
-Original Message-
From: Charles Oliver Nutter [mailto:head...@headius.com]
Sent: Sunday, June 13, 2010 6:28 PM
On Sat, Jun 12, 2010 at 3:53 PM, Ola Bini ola.b...@gmail.com wrote:
I do see the need to make these kind of changes, based on their performance
impact. But I still have reservations (maybe because I'm one of the people
who write code that usually sets instance variables on Java objects, and
On Sun, Jun 13, 2010 at 2:54 AM, Wayne Meissner wmeiss...@gmail.com wrote:
Could the weak ref wiring be done lazily, so the overhead is only
incurred when someone sets an ivar on a java object?
e.g. when a java object enters jruby, it gets a new lightweight
wrapper, but when someone does an
On Sun, Jun 13, 2010 at 11:19 PM, Charles Oliver Nutter
head...@headius.com wrote:
On Sun, Jun 13, 2010 at 2:54 AM, Wayne Meissner wmeiss...@gmail.com wrote:
Could the weak ref wiring be done lazily, so the overhead is only
incurred when someone sets an ivar on a java object?
e.g. when a java
One of the primary remaining perf challenges for JRuby is the cost of
bringing Java objects into the Ruby environment. Currently, all
objects get wrapped with a small wrapper object that implements
IRubyObject. This is primarily because all our call logic requires
receivers and arguments to all be
On 2010-06-12 10.41, Charles Oliver Nutter wrote:
One of the primary remaining perf challenges for JRuby is the cost of
bringing Java objects into the Ruby environment. Currently, all
objects get wrapped with a small wrapper object that implements
IRubyObject. This is primarily because all our
On Sat, Jun 12, 2010 at 11:41 AM, Charles Oliver Nutter
head...@headius.com wrote:
One of the primary remaining perf challenges for JRuby is the cost of
bringing Java objects into the Ruby environment. Currently, all
objects get wrapped with a small wrapper object that implements
IRubyObject.
Could the weak ref wiring be done lazily, so the overhead is only
incurred when someone sets an ivar on a java object?
e.g. when a java object enters jruby, it gets a new lightweight
wrapper, but when someone does an ivar get/set on it, it looks for the
ivar holder for the java object in the weak