Index/list of libc functions OSv implements

14 views
Skip to first unread message

Waldek Kozaczuk

unread,
Sep 20, 2018, 9:22:58 AM9/20/18
to OSv Development
If times allows at some point I would like to create a Wiki page documenting libc functions and syscalls OSv implements. Some sort of Wiki page with a table that points to this or other index - https://www.gnu.org/software/libc/manual/html_node/Function-Index.html.

What would be the best way to compile this info in some automated way? Finding under libc and musl subdirectories and possibly intersecting against info in the doc itself? I understand that some functions are probably commented out or disabled in some other. Also linux.cc for list of syscalls.

Also I have never taken time to understand difference between musl and libc folder given that musl implements libc. Why do have two of these folders? 

Regards,
Waldek

Nadav Har'El

unread,
Sep 20, 2018, 9:33:16 AM9/20/18
to Waldek Kozaczuk, Osv Dev
On Thu, Sep 20, 2018 at 4:23 PM Waldek Kozaczuk <jwkoz...@gmail.com> wrote:
If times allows at some point I would like to create a Wiki page documenting libc functions and syscalls OSv implements. Some sort of Wiki page with a table that points to this or other index - https://www.gnu.org/software/libc/manual/html_node/Function-Index.html.

What would be the best way to compile this info in some automated way? Finding under libc and musl subdirectories and possibly intersecting against info in the doc itself? I understand that some functions are probably commented out or disabled in some other. Also linux.cc for list of syscalls.

If you have a list of functions from glibc and or LSB (http://refspecs.linuxbase.org/LSB_3.0.0/LSB-PDA/LSB-PDA/libc.html) or something, you can fairly easily check which one OSv provides by doing "nm -D" or similar on the OSv kernel to see which symbols it exposes.

Of course, this doesn't take into account which functions are actually implemented *correctly*, or whether the implementation is a complete one or as incomplete as an aborting stub.


Also I have never taken time to understand difference between musl and libc folder given that musl implements libc. Why do have two of these folders? 

musl/ is an unmodified copy of a specific version of Musl we took at some point.
libc/ includes code we wrote ourselves, or *modified* versions of musl files when we had to modify them.

The long term vision was to always take musl/ from the latest Musl upstream, and whatever patches we need to do to their code, try to push them upstream.
But this never materialized.

Nadav.
Reply all
Reply to author
Forward
0 new messages