Show enters and exits. Hide enters and exits.
| 01:20:35 | boyscout | Add ability to set thread stack size - aa660db - Evan Phoenix |
| 01:20:35 | boyscout | Rework capi Handles entirely - 4c6a1ef - Evan Phoenix |
| 01:20:48 | boyscout | CI: Build 4c6a1ef failed. http://ci.rubini.us/rubinius/builds/4c6a1efb16afc006fbcaff727b2e6315f5d4d264 |
| 01:21:19 | brixen | uh oh, might have missed a file |
| 01:22:37 | boyscout | Add missing files - 07dfb90 - Evan Phoenix |
| 01:23:36 | rue | Neat, real handles. |
| 01:25:09 | evan | rue: yep |
| 01:25:15 | evan | they basically mimic the MRI memory model now |
| 01:31:27 | boyscout | CI: 07dfb90 success. 1503 files, 7245 examples, 23659 expectations, 0 failures, 0 errors |
| 03:42:39 | mdalessio | Hey all. I'm trying to install a gem, and getting an odd error. |
| 03:42:42 | mdalessio | The command I'm running: ./bin/rbx -S gem install rake |
| 03:42:46 | mdalessio | The error message: ERROR: While executing gem ... (Zlib::GzipFile::Error) invalid compressed data -- crc error |
| 03:43:35 | mdalessio | I'm on latest master |
| 04:55:34 | brixen | mdalessio: that is a weird error |
| 04:55:51 | brixen | I've seen it/heard of it but really don't know the cause |
| 04:56:00 | brixen | I think it could be your zlib |
| 04:56:08 | mdalessio | brixen: agreed. just wanted to do a sanity check, that I'm not doing something obviously wrong |
| 04:56:13 | brixen | rbx uses FFI bindings to zlib |
| 04:56:24 | brixen | it's probably not anything in rbx |
| 04:56:49 | brixen | what platform are you on btw? |
| 04:57:01 | mdalessio | ubuntu hardy |
| 04:57:42 | brixen | had you seen? http://www.ruby-forum.com/topic/148609 |
| 04:59:30 | mdalessio | i did, but nothing i could find there was really relevant. i'm looking at strace output now ... |
| 06:34:58 | boyscout | Fixes to run the sqlite3-ruby gem - 01bd2d1 - Evan Phoenix |
| 06:39:56 | boyscout | CI: 01bd2d1 success. 1503 files, 7245 examples, 23659 expectations, 0 failures, 0 errors |
| 07:37:46 | headius | anyone around that knows about the current status of the capi work? |
| 07:39:18 | evan | yep |
| 07:39:22 | evan | what you wanna know? |
| 07:39:34 | evan | brixen and I have been working on it a bunch |
| 09:13:46 | headius | evan: oh sorry, I didn't notice |
| 09:14:07 | headius | I was just wondering if you had any feeling for the road forward |
| 09:14:28 | headius | we've always hoped there might be a way to load sane extensions directly, but everything I've seen tells me sane extensions are extremely rare |
| 09:14:52 | headius | or that the performance impact of trying to make them work would be so bad as to invalidate the utility of loading them in the first place |
| 09:15:33 | headius | I think this is going to impact all new impls that want to load C extensions....like macruby |
| 09:15:48 | headius | in order for macruby to support this they'll have to do exactly what you do, which is in turn exactly what we'd have to do in JRuby |
| 09:16:05 | headius | so the exploration you're doing could be applicable to all three of us, and I'm obviously interested in that |
| 09:17:42 | boyscout | Added -gc option to show GC stats. - 9d7db4b - Brian Ford |
| 09:17:43 | boyscout | Fixed rake build tasks using profiler_flags. - bd46f4c - Brian Ford |
| 09:17:43 | boyscout | Fixed profiler. - 51cb55a - Brian Ford |
| 09:18:21 | boyscout | CI: Build 51cb55a failed. http://ci.rubini.us/rubinius/builds/51cb55a979779ef47707dfcf1943461103e9a5b4 |
| 09:18:49 | brixen | fscking gcc |
| 09:19:53 | kronos_vano | :) |
| 09:20:59 | headius | so I guess I'm mostly interested because if you're successful, it will be possible for us to implement the same set of APIs and possible reuse a lot of your capi wrapper code with a JNI equivalent |
| 09:22:41 | brixen | headius: evan just implemented gc'd constant values for handles |
| 09:22:59 | brixen | we're running bigdecimal, digest, and sqlite3 |
| 09:23:04 | brixen | and readline |
| 09:23:23 | brixen | and mongrel |
| 09:23:43 | headius | have you done any measurement of performance? I remember you guys talking recently about having to copy stuff in and out for several capi functions |
| 09:23:51 | headius | that seems like it would be a nonstarter |
| 09:24:36 | brixen | no, haven't really looked at perf |
| 09:25:44 | headius | it's at least promising that you can load those libraries and get them to function |
| 09:25:53 | brixen | fucking gcc 4.3 |
| 09:26:08 | headius | my other concern is that the ability to load those libraries will make people just give up on doing ports of them that probably would perform a lot better |
| 09:26:36 | headius | so they'll try running stuff in rubinius or macruby or jruby with the native extension, decide it's just slower, and go back to MRI's comparatively faster extension support |
| 09:27:06 | headius | I'm sure you guys see now a lot of the reasons JNI is structured the way it is |
| 09:27:28 | headius | everything has to be pushed and pulled into the managed handles because things can relocate |
| 09:27:32 | slava | JNI is a bit too low-level. Would've been nice if Java came with an FFI |
| 09:27:44 | headius | slava: FFI works, but you still need a way of getting data out to it |
| 09:28:01 | headius | MRI's extension API, and the parts of it rbx supports, does not support any abstraction of where the data is located |
| 09:28:37 | headius | so while on MRI it's fine, because there's no concurrent threading, no GC running during native code, rbx is penalized because it has to ensure the data presented to C code is fixed in memory |
| 09:29:02 | headius | I've never doubted that it's possible to implement enough of the C api to get things to *work* but to work with acceptable performance is another matter entirely |
| 09:29:33 | headius | we actually had a start on our own capi layer, and came to the point where it would be necessary to copy state in and out |
| 09:29:43 | headius | at that point we didn't figure it was worth continuing, since the performance would always blow |
| 09:31:10 | headius | I think rbx and macruby will have the same problem, though I'd love to be proven wrong |
| 09:32:09 | headius | so yeah, I would love to talk more about it |
| 09:32:14 | headius | when you guys have time |
| 09:35:22 | brixen | headius: well, we'd love to see all the gems and libraries rewritten in FFI |
| 09:35:30 | brixen | but that's not happening any time soon |
| 09:35:39 | headius | right, it certainly isn't |
| 09:35:41 | brixen | and we've had enough issues with bugs in rewritten stuff |
| 09:35:53 | brixen | that it pays to run, even if running slower |
| 09:36:09 | brixen | I'm not sure perf will be that big an issue on basic stuff |
| 09:36:27 | brixen | you should check out evan's work from the past 2 days |
| 09:36:29 | headius | and fwiw I am trying to be constructive with this discussion...we feel the pain of not being able to run native extensions and would whole-heartedly support work on a common set of capi shims if it seemed like it might be feasible, both functionality and performance-wise |
| 09:36:54 | brixen | I'm not sure how much there is in common |
| 09:37:05 | brixen | it's pretty impl specific |
| 09:37:14 | headius | at some level you have a representation of a handle to a ruby object and logic for getting data out of it |
| 09:37:16 | headius | that would be impl specific |
| 09:37:31 | headius | but the basic operations would be the same |
| 09:37:42 | headius | given a ruby string, get a reference to a c-str array |
| 09:37:45 | brixen | well, a lot of capi is rb_funcall |
| 09:37:55 | brixen | and what isn't is calls to our C++ classes |
| 09:38:04 | brixen | so, it's pretty impl specific |
| 09:38:25 | headius | mm, so you're not building any API that abstracts your C++ logic |
| 09:38:28 | brixen | the handles are gc'd now |
| 09:38:39 | brixen | so that's also impl specific |
| 09:38:41 | headius | yes, I saw something about reference-conted |
| 09:39:03 | brixen | nope, inside the rb_xxx functions, it calls C++ stuff directly |
| 09:39:13 | brixen | can't see any reason to abstract that |
| 09:39:14 | headius | mmm ok...that's too bad |
| 09:39:27 | headius | well, except that if your C++ classes change in the future you'll have to fix all that |
| 09:39:32 | brixen | sure |
| 09:39:41 | headius | the reason for abstracting anything, really |
| 09:39:45 | brixen | a lot of stuff is rb_funcalls though |
| 09:41:36 | headius | yeah, that much we had working on wmeissner's work |
| 09:41:57 | headius | but every extension we encountered needed to get access to C string data, for example, which meant copying stuff around |
| 09:42:27 | headius | and some went as far as accessing hash internals using st.c functions |
| 09:43:26 | boyscout | Fixes for gcc 4.3. - 6becfe1 - Brian Ford |
| 09:43:54 | brixen | yeah, the one's that access st just plain suck ass |
| 09:44:06 | headius | there's simply no way to support them |
| 09:44:24 | headius | pushing and pulling an st.c hash would be absurd |
| 09:44:27 | brixen | narray does RCLASS(a)->m_tbl == RCLASS(b)->m_tbl |
| 09:44:31 | rue | headius: The trivial Mongrel+Rack script I wrote ran about 5% slower than MRI, meaning the difference in the C part was negligible. |
| 09:44:33 | brixen | as a type_of |
| 09:44:39 | headius | yeah, exactly, shit like that makes me lose hope |
| 09:45:00 | headius | rue: how did you isolate the time spent in C stuff? |
| 09:45:12 | headius | because other parts could be faster and compensating |
| 09:45:47 | rue | We do not run Ruby faster than MRI |
| 09:45:48 | brixen | heh, we don't have a lot of "faster parts" atm |
| 09:45:51 | headius | brixen: we actually used to have checks like that in JRuby internals, so I think it's a CRubyistm |
| 09:46:01 | rue | brixen: Should just use 4.3 |
| 09:46:16 | brixen | rue: 4.3 should just go commit suicide |
| 09:46:21 | headius | well, that's somewhat promising, but mongrel is probably not a good example |
| 09:46:33 | headius | the transfer across the native/ruby boundary is pretty much a single shot |
| 09:46:41 | headius | and entirely from native to ruby, rather than the other way around |
| 09:46:43 | brixen | mongrel has a lot of global data though |
| 09:47:01 | brixen | it was broken before evan's handle rework |
| 09:47:36 | headius | rue: can I see that script? |
| 09:48:20 | rue | brixen: 4.3 works just fine, and catches quite a few problems that need catching |
| 09:49:03 | boyscout | CI: 6becfe1 success. 1503 files, 7245 examples, 23659 expectations, 0 failures, 0 errors |
| 09:49:44 | rue | http://gist.github.com/87260 |
| 09:50:41 | headius | just hitting it with ab or something? |
| 09:50:55 | rue | Yeah |
| 09:51:46 | headius | so yeah, I guess I've made my case...5% worse than MRI is promising |
| 09:52:10 | headius | I suppose it's going to be a growing corpus of knowledge about whether this is feasible, since we don't know what other hassles are out there |
| 09:52:23 | headius | brixen: how does the capi handlg DataWrapStruct right now? I know nokogiri uses that heavily |
| 09:52:37 | brixen | handles it ok |
| 09:52:45 | brixen | creates a Data instance |
| 09:54:25 | headius | rue: what kind of numbers were you getting for MRI on this? |
| 09:54:29 | headius | it seems slower than it should be |
| 09:54:43 | headius | 92rps? |
| 09:55:58 | headius | hmm |
| 09:55:58 | headius | rack.errors: #<Rack::Lint::ErrorWrapper:0x12c7ef4 @error=#<IO:0x2f7c4>> |
| 09:56:04 | headius | I wonder if I should be seeing that |
| 10:02:44 | headius | rue: without lint and showexceptions I get closer to 609 rps |
| 10:02:53 | headius | can you re-run in rbx without those? |
| 10:19:25 | headius | maybe I can re-run...does this work against master? |
| 10:33:16 | headius | brixen: you around still? |
| 11:02:30 | scoopr | heh http://gist.github.com/99691 |
| 12:29:43 | headius | rue: FYI, I did get that script to run on rbx and wasn't able to reproduce your performance observation |
| 12:29:45 | headius | it also crashed: http://gist.github.com/99739 |
| 12:30:08 | headius | maybe I'm doing something wrong with it...I just did bin/rbx gem install mongrel and gem install rack and then ran my modified version of your script that doesn't use lint or showexceptions |
| 12:31:42 | headius | it seems to die some time after 800 requests |
| 12:32:05 | headius | with 500 requests I can get about 96rps |
| 12:32:15 | headius | MRI does in the neighborhood of 600 |
| 12:32:26 | headius | let me know if there's something else I should be doing to run this |
| 14:56:37 | rue | I went to the zo |
| 14:56:44 | rue | Zoo, too. Both were fun |
| 15:18:31 | scoopr | nice |
| 20:30:11 | boyscout | Declare Time#initialize private instead of public. - c214841 - Tilman Sauerbeck |
| 20:30:12 | boyscout | UnMarshal's methods are private, except unmarshal(). - 65adf3f - Tilman Sauerbeck |
| 20:34:33 | boyscout | CI: 65adf3f success. 1503 files, 7245 examples, 23659 expectations, 0 failures, 0 errors |
| 21:56:52 | boyscout | Fix latent parsing problem - 2242394 - Evan Phoenix |
| 22:03:55 | boyscout | CI: 2242394 success. 1503 files, 7245 examples, 23659 expectations, 0 failures, 0 errors |
| 23:16:14 | boyscout | Changed profiler cumulative seconds method. - dd65a98 - Brian Ford |
| 23:23:36 | boyscout | CI: dd65a98 success. 1503 files, 7245 examples, 23659 expectations, 0 failures, 0 errors |