hmm, this musl-perf thing effectively makes musl LGPL, but they don't supply the source for the glibc string functions they borrowed.
-
hmm, this musl-perf thing effectively makes musl LGPL, but they don't supply the source for the glibc string functions they borrowed.
-
Ariadne Conill 🐰:therian:replied to Ariadne Conill 🐰:therian: on last edited by
one of the patches they apply changes the stdio default buffer size from 1024 bytes to 8192 bytes. why? who knows, no rationale is provided.
i guess the thinking is to align on a page boundary, but why *two* pages?
-
gaytaloggerreplied to Ariadne Conill 🐰:therian: on last edited by
@ariadne 8k is the standard go-to buffered filesize for glibc
-
Ariadne Conill 🐰:therian:replied to gaytalogger on last edited by
@dysfun yes, that makes sense. but why?
-
gaytaloggerreplied to Ariadne Conill 🐰:therian: on last edited by
@ariadne i have nfc why glibc does anything.
-
Ariadne Conill 🐰:therian:replied to gaytalogger on last edited by
@dysfun sure, but you are also not passing off an optimized musl library with no documentation on the design decisions made
-
gaytaloggerreplied to Ariadne Conill 🐰:therian: on last edited by
@ariadne optimised? well now, 2 pages are better than one because you can amortize it over twice as much, obviously.
-
Ariadne Conill 🐰:therian:replied to Ariadne Conill 🐰:therian: on last edited by
outside of adding glibc string functions and the bufsize change, they add ifunc support to the linker.
ifuncs are awful because they make program execution inconsistent across different microarchitectures
-
Matt Campbellreplied to Ariadne Conill 🐰:therian: on last edited by
@ariadne And of course, ifuncs enabled the xz backdoor.
-
Ariadne Conill 🐰:therian:replied to Matt Campbell on last edited by
@matt yes, from a security POV they are a great tool for hiding things like that
-
Rich Felkerreplied to Ariadne Conill 🐰:therian: on last edited by
@ariadne The only thing relevant to perf here is amortizing syscall kernel entry/return overhead. Nothing to do with page or block sizes.
-
Rich Felkerreplied to Ariadne Conill 🐰:therian: on last edited by
@ariadne Ifunc is just an utterly dumb way to do runtime microarch specific code selection.
-
Ariadne Conill 🐰:therian:replied to Rich Felker on last edited by
@dalias yeah, i agree. it would be nice to have some of those AVX string implementations though in musl.
-
Val Packett 🧉replied to Rich Felker on last edited by
-
Thomas Guyot-Sionnestreplied to Rich Felker on last edited by
-
Ariadne Conill 🐰:therian:replied to Thomas Guyot-Sionnest on last edited by
-
Robert D. Frenchreplied to Val Packett 🧉 last edited by
@valpackett @dalias @ariadne Oooh, let me try to answer that! I think the "dumb" comes from the fact that there are other, more portable ways to implement "runtime selection of features" (i.e. function pointers stored in a protected page) that don't allow libraries to provide *arbitrary plugins* for the dynamic linker.
I wrote a whole mini-thesis on this if you are interested in getting INSANELY deep down in the weeds: https://github.com/robertdfrench/ifuncd-up