4 ms·
It can branch based on the syscall return and the ability to copy word-values like file descriptors from open to an fstat and so on. That copying could perhaps
by cb321 6y ago
It can branch based on the syscall return and the ability to copy word-values like file descriptors from open to an fstat and so on. That copying could perhaps be extended to strings in some limited way, but I agree it is generally much more limited.
Not needing superuser/any special capability is also nice, though. Not sure of the current status/plans, but I am pretty sure eBPF needed root that for a very long time.
Anyway, I was not trying to "compete" with you or try to "get into mainline". A module works fine for me. Was just exhibiting an easy possibility about some points discussed.
EDIT: and thanks for the pointer. I will check it out.
EDIT2: and much like the word copy is a fake syscall, other fake syscalls like a "value test" could be added to forge a sort of if condition jump forward thing. My little repo there is more a proof of concept than anything else.
- pengaru 6y ago> I was not trying to "compete" with you It's not like I have a dog in this race, I'm just another consumer of these kernel interfaces... But I am happy something finally has landed upstream we can start writing generic userspace programs targeting and actually expect them to work on distro kernels in the future. But we probably still need a compatibility layer for emulating it in userspace, looks feasible.
- cb321 6y agoAh. "Contributions are welcome" made me think of you as one of the welcomers. Compatibility-layer-wise, I did actually do that for my batch system. In the tiny user-space entry point I check if sys_batch is working and if not I fall back to just a loop of userspace making syscalls. That also checks a BATCH_EMUL environment variable to force that emulation mode for benchmarking purposes { so I don't have to unload/reload the module. :-) } So, user code would always just work, but work faster on kernels with the module loaded.
- pengaru 6y agoI've just been following the io_uring mailing list as of late. It appears to be a welcoming environment to outside contribution, assuming quality and relevance of course.