On Wed, Jun 22, 2016 at 6:46 AM, Felipe Magno de Almeida <felipe.m.alme...@gmail.com> wrote: > On Jun 22, 2016 9:22 AM, "Daniel Kolesa" <dan...@octaforge.org> wrote: >> On Mon, Jun 20, 2016 at 1:04 AM, Felipe Magno de Almeida >> <felipe.m.alme...@gmail.com> wrote: >> > it is the _perfect_ match IMO. Probably we should ask someone >> > that actually uses Lua about it, instead of guessing. >> >> I'm inclined to agree with raster here. I honestly don't see >> coroutines being a good match here - the API is one thing, and there >> is one other thing to consider that wasn't brought up and that is >> performance - coroutines cannot be JITed and for async stuff we'll be >> jumping across C-Lua border all the time over classic C API rather >> than fast FFI stuff (it will also add a significant amount of new >> runtime on C side, which I would rather avoid) which will abort traces >> and hurt perf. > > Not using coroutines because of performance in lua doesn't seem like a good > reason at all IMO.
<snip> Just focusing here on the performance issue. If you think that coroutine are going to be a performance issue for promise, I think this raise two points to discuss. First how good is the JIT on short function, because if we go with events/callbacks, we will endup with very short snippet of code. I don't know for lua jit, but most JIT I know about are bad with short code anyway (It will literray come from C, execute a small amount of code and go back to C). So I don't really see why coroutine will be any worse than events/callbacks in that case. Second point, if you are concerned by performance, then why is it a good idea to switch to an eo object at all. We are now going to pay a way higher price for an API that will be wrapped in C to be convenient and manually binded in all bindings. So where do people still see any win at all into moving to an eo object ? -- Cedric BAIL ------------------------------------------------------------------------------ Attend Shape: An AT&T Tech Expo July 15-16. Meet us at AT&T Park in San Francisco, CA to explore cutting-edge tech and listen to tech luminaries present their vision of the future. This family event has something for everyone, including kids. Get more information and register today. http://sdm.link/attshape _______________________________________________ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel