[ruby-core:63087] Re: [RFC] vm_method.c (rb_method_entry_make): avoid freed me in m_tbl

From: Eric Wong <normalperson@...>
Date: 2014-06-11 01:13:25 UTC
List: ruby-core #63087
SASADA Koichi <ko1@atdot.net> wrote:
> > 
> > Anyways, my ihash proposal is dead.  khash seems the best, so far.
> 
> Ah, really? I missed this post.
> Could you pointed out about this discussion?

Sorry, I haven't posted much on khash, yet.  Other projects[1] are
taking my time away from Ruby.  But so far I like khash most,
and it is used by mruby.

I'm also thinking about a crazy idea to use giant VM-wide hashes for
all methods and constants.  With a per-class list_head to:

a) preserve ordering (compatibility)
b) ensure deletion from the giant hash in case a class goes away

This might reduce space waste from small classes.


[1] one "other project" involves a lock-free hash table from URCU
    <http://lttng.org/urcu>.  Unfortunately Ruby cannot depend on
    LGPLv2.1+ libraries, but maybe it can be optional like gmp.

In This Thread