-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RDY] os: implement VimL libcall with {mch,os}_libcall #802
Conversation
@Shougo would you like to test this branch? |
|
Done, and rebased against master. |
I tested your branch and worked vimproc and vimshell. |
Good news! |
👍 |
I benchmarked your branch by vimproc's benchmark.vim.
|
I suspect that's either libuv's or @tarruda's magic at work, nothing to do with libcall ;).
I reckoned that, I suspect most of the work is in the loading and unloading of the library. If that's the case and it needs to be faster, we could conceivably keep loaded libraries in a dictionary, but that would increase the complexity and I don't think it's worth it for a feature that's not often used. The same speed sounds good for this one, don't you think? |
Not bad for me. https://groups.google.com/d/msg/vim_dev/F2z5I9tayKY/UNGZ1-kSvq4J But if neovim supports FFI, it will be good. |
That is because of the new implementation of |
It is good news for other plugins! |
There are some uses of |
I'm not sure if I understand you. With this PR, |
#ifdef FEAT_LIBCALL
"libcall",
#endif So we should remove |
Ok, I just Ag'ed over the source. I think the best thing is to just remove the |
👍 |
@Hinidu done, can you review that? To all others: I added the |
aktau@5934529 is ok 👍 |
The old mch_libcall was removed from neovim. This is a partial reimplementation on top of libuv. It doesn't catch exceptions (windows) nor signals (unix) though, so it's quite a bit more prone to crashing if the loadable library throws an exception or crashes. Still, it should be fine for well-behaved libraries. Requested by @Shougo.
Remove as much leftover cruft as possible. Tried to see which globals are now not used anymore.
Remove all the legacy code that related to mch_libcall in some way. os_libcall is implemented on top of libuv now.
I don't mind at all, thanks for noticing. I have removed those lines, rebased for good measure and force-pushed. |
Thank you, good work 👍 |
Merged |
Great! |
The extra cmd line flags "-- -Wall -Wextra" are not accepted and processed by clang-check, moreover they actually prevent it from working correctly.
The old mch_libcall was removed from neovim. This is a partial
reimplementation on top of libuv. It doesn't catch exceptions (windows) nor
signals (unix) though, so it's quite a bit more prone to crashing if the
loadable library throws an exception or crashes. Still, it should be fine
for well-behaved libraries. Requested by @Shougo.