[MacRuby-devel] experimental branch: status update
Laurent Sansonetti
lsansonetti at apple.com
Sun Apr 26 19:43:29 PDT 2009
A status update on the recent progresses on the experimental branch!
Last week did not see a status update, mea culpa.
- A new C/Objective-C dispatcher has been written. The idea is to use
LLVM to compile stubs instead of using libffi. The previous libffi-
based implementation is no longer used (yay for performance!) and we
are able to run most of the C/Objective-C APIs. According to some
early benchmarks, the new dispatcher is about 8 times faster than
trunk, and about 3 times slower than pure Objective-C, so it's very
promising. Getting rid of libffi was the goal, because it's very slow.
- C structures covered by BridgeSupport annotations are also exposed,
providing the exact same behavior as in trunk. The implementation is
however new, since we no longer use libffi to represent them.
Thanks to these changes, we are able to run some MacRuby Cocoa scripts
(like hello world).
- More work on the LLVM interpreter usage: we were able to plug some
of the VM primitives into it and therefore interpret naive
expressions. If everything goes well we could use it to run simple
expressions instead of using the JIT, which should accelerate the load
of large libraries (and make #eval a lot faster).
- The ultra lazy JIT is now enabled by default. A couple of specs are
now failing and will be investigated later, but on average it works
great.
- We started writing specs for MacRuby-specific behaviors (currently
66 examples and 305 expectations).
- All 1.9 multiple assignment scenarios should now be implemented.
- RubySpec was upgraded from the upstream version.
- A RubyFFI-compatible API is under development. It uses the new C
dispatcher functionality under the covers. Currently most types are
supported except :pointer, structures (and maybe more). The cool thing
about this API is that it's implemented in different versions of Ruby,
so we should be able to reuse existing Ruby libraries based on it,
until we support MRI C extensions.
Laurent
More information about the MacRuby-devel
mailing list