Hi, Is any effort being made to synchronize the upcoming MacRuby 0.7 release with the upcoming LLVM 2.8 release? How big are the changes to LLVM between the preferred MacRuby version (r106781) and the latest RC (https://llvm.org/svn/llvm-project/llvm/tags/RELEASE_28/rc2, r114689)? MacRuby HEAD doesn't build with 2.8rc2, (at a glance) related to the following changes listed here: http://llvm.org/docs/ReleaseNotes.html#whatsnew * LLVM 2.8 changes the internal order of operands in InvokeInst and CallInst. To be portable across releases, resort to CallSite and the high-level accessors, such as getCalledValue and setUnwindDest. * You can no longer pass use_iterators directly to cast<> (and similar), because these routines tend to perform costly dereference operations more than once. You have to dereference the iterators yourself and pass them in. I'm not expert on LLVM or MacRuby, but I'd like to see compatibility between 'stable' versions, so I'm happy to help if I can. Craig
Hi Craig, There is currently no effort. We are preparing the 0.7 release right now and I don't think synchronizing with the upcoming LLVM 2.8 release is a good idea, since it may introduce side effects. But once the release is done, we can look at it. If you want to work on this feel free. I assume it will just be a matter of porting to the new APIs, assuming no regressions were added recently in LLVM ToT. It would be a good way to learn about the MacRuby compiler :) If you have any question let us know here. Laurent On Sep 24, 2010, at 7:17 AM, Craig Bosma wrote:
Hi,
Is any effort being made to synchronize the upcoming MacRuby 0.7 release with the upcoming LLVM 2.8 release? How big are the changes to LLVM between the preferred MacRuby version (r106781) and the latest RC (https://llvm.org/svn/llvm-project/llvm/tags/RELEASE_28/rc2, r114689)?
MacRuby HEAD doesn't build with 2.8rc2, (at a glance) related to the following changes listed here: http://llvm.org/docs/ReleaseNotes.html#whatsnew
* LLVM 2.8 changes the internal order of operands in InvokeInst and CallInst. To be portable across releases, resort to CallSite and the high-level accessors, such as getCalledValue and setUnwindDest. * You can no longer pass use_iterators directly to cast<> (and similar), because these routines tend to perform costly dereference operations more than once. You have to dereference the iterators yourself and pass them in.
I'm not expert on LLVM or MacRuby, but I'd like to see compatibility between 'stable' versions, so I'm happy to help if I can.
Craig _______________________________________________ MacRuby-devel mailing list MacRuby-devel@lists.macosforge.org http://lists.macosforge.org/mailman/listinfo.cgi/macruby-devel
Thanks Laurent, I am interested in learning more about MacRuby/LLVM internals, so perhaps this is a good opportunity. I created a patch (attached) that gets MacRuby building with LLVM 2.8rc2, but I'm quite certain that this bit: dbg_mdkind = context.getMDKindID("dbg"); - assert(dbg_mdkind != 0); + //assert(dbg_mdkind != 0); is all wrong. I presume that the assertion is there to verify the presence of debug metadata, but beyond that -- where the debug metadata is created, what may have changed in 2.8 pertaining to metadata, or even the basic metadata model/API of LLVM are currently beyond me. Any suggestions for a basic primer on LLVM's architecture, or pointers on where to start digging? I *think* the other changes are straightforward (per the 2.8 release notes). Also, I see there are a lot of rake tests; which one(s) would be a good sanity check when hacking on MacRuby? Craig
Hi Craig, On Sep 27, 2010, at 9:48 AM, Craig Bosma wrote:
Thanks Laurent,
I am interested in learning more about MacRuby/LLVM internals, so perhaps this is a good opportunity. I created a patch (attached) that gets MacRuby building with LLVM 2.8rc2, but I'm quite certain that this bit:
dbg_mdkind = context.getMDKindID("dbg"); - assert(dbg_mdkind != 0); + //assert(dbg_mdkind != 0);
is all wrong. I presume that the assertion is there to verify the presence of debug metadata, but beyond that -- where the debug metadata is created, what may have changed in 2.8 pertaining to metadata, or even the basic metadata model/API of LLVM are currently beyond me. Any suggestions for a basic primer on LLVM's architecture, or pointers on where to start digging?
I guess the debug metadata API changed again. I am not aware of any documentation about LLVM internals except its source code :) However, strange enough, Watson tried your patch and was able to get debugging backtraces working. So, some investigation is required I think. I will have a quick look tomorrow.
I *think* the other changes are straightforward (per the 2.8 release notes).
Indeed, looks straightforward. Thanks for working on this :) We might need to adapt the patch a little bit since the project must still build with an older version of LLVM, but I will do the necessary tweaks.
Also, I see there are a lot of rake tests; which one(s) would be a good sanity check when hacking on MacRuby?
We generally use the RubySpec suite for that. You can run it using: $ rake spec:ci Laurent
participants (2)
-
Craig Bosma
-
Laurent Sansonetti