4 ms·
200k is very large in the OpenWrt world
by phoronixrly 3y ago
200k is very large in the OpenWrt world
- fulafel 3y agoAda then? Eg on https://ada.godbolt.org/ https://ada.godbolt.org/ you can see the default program compiled to ~25 lines of assembler. edit: actually it contains a call to a bounds check function that presumably is in the runtime library, i don't know how big that is. A major point in this is that C also has a fairly big runtime library that should be factored into the comparison!
- zokier 3y ago> A major point in this is that C also has a fairly big runtime library that should be factored into the comparison! But libc will be there anyways, unless you are rewriting absolutely all of userland.
- mananaysiempre 3y ago> C also has a fairly big runtime library The original releases of OpenWRT used uClibc, which is nowhere near Glibc levels of bloat (Musl beats it on code quality and is used today, but didn’t exist back then). Also, yeah, you’re going to have a libc on a Linux system no matter what, so this is one of the rare cases where dynamic linking makes for a legitimate optimization.
- acka 3y agoCurrent OpenWRT uses musl libc[1] which can be optimized to have a tiny footprint and supports full static linking, before that it used ucLibc which was similarly optimized. You can still build software for OpenWRT that requires the much bigger Glibc, but of course it will not work that well on devices with limited memory. [1]: https://musl.libc.org/ https://musl.libc.org/
- fulafel 3y agoMusl libc seems to be 2 MB ish, it's smaller than glibc but still something when comparing to other languages and their runtimes.
- phoronixrly 3y ago464.7K Oct 15 2022 /lib/libc.so As seen on openwrt on armv7l system
- ranma42 3y agoAlso OpenWRT udev itself is tiny: 20.0K Oct 13 2022 /usr/lib/libudev.so.1 8.0K Dec 15 2022 /sbin/udevtrigger
- synergy20 3y agomusl is a few hundred kb