freebsd-dev/lib/csu
Konstantin Belousov 51015e6d0f csu: move common code to libc
Why? Most trivial point, it shaves around 600 bytes from the dynamic
binaries on amd64. Less trivial, the removed code is no longer part of
the ABI, and we can ship updates to it with libc updates. Right now most
of the csu is linked into the binaries and require us to do somewhat
tricky ABI compat when it needs to change. For instance, the init_array
change would be much simpler and does not require note tagging if we
have init calling code in libc.

This could be improved more, by splitting dynamic and static
initialization. For instance, &_DYNAMIC tests can be removed then.
Such change, nonetheless, would require building libc three times.
I left this for later, after this change stabilizes, if ever.

Reviewed by:	markj
Discussed with:	jrtc27 (some objections, see the review), imp
Tested by:	markj (aarch64)
Sponsored by:	The FreeBSD Foundation
MFC after:	3 weeks
Differential revision:	https://reviews.freebsd.org/D37220
2023-03-12 00:50:03 +02:00
..
aarch64 csu: move common code to libc 2023-03-12 00:50:03 +02:00
amd64 csu: move common code to libc 2023-03-12 00:50:03 +02:00
arm csu: move common code to libc 2023-03-12 00:50:03 +02:00
common csu: move common code to libc 2023-03-12 00:50:03 +02:00
i386 csu: move common code to libc 2023-03-12 00:50:03 +02:00
powerpc csu: move common code to libc 2023-03-12 00:50:03 +02:00
powerpc64 csu: move common code to libc 2023-03-12 00:50:03 +02:00
riscv csu: move common code to libc 2023-03-12 00:50:03 +02:00
tests Revert "csu: test: explicitly add libm as build parameter" 2022-07-28 11:23:26 -03:00
Makefile [PowerPC64LE] Use a shared LIBC_ARCH for powerpc64le. 2020-09-23 00:21:51 +00:00
Makefile.inc csu: define STRIP_FBSDID 2021-12-21 13:34:42 -05:00