]> git.ipfire.org Git - thirdparty/glibc.git/commit - NEWS
Move malloc hooks into a compat DSO
authorSiddhesh Poyarekar <siddhesh@sourceware.org>
Thu, 22 Jul 2021 13:07:59 +0000 (18:37 +0530)
committerSiddhesh Poyarekar <siddhesh@sourceware.org>
Thu, 22 Jul 2021 13:07:59 +0000 (18:37 +0530)
commit2d2d9f2b48a943fa556301db532103d09800da4d
tree1adb6efbb63ebadd37233851cf14e5cf394de59f
parent55a4dd39308951da4b0da84b19e415c2bb451b60
Move malloc hooks into a compat DSO

Remove all malloc hook uses from core malloc functions and move it
into a new library libc_malloc_debug.so.  With this, the hooks now no
longer have any effect on the core library.

libc_malloc_debug.so is a malloc interposer that needs to be preloaded
to get hooks functionality back so that the debugging features that
depend on the hooks, i.e. malloc-check, mcheck and mtrace work again.
Without the preloaded DSO these debugging features will be nops.
These features will be ported away from hooks in subsequent patches.

Similarly, legacy applications that need hooks functionality need to
preload libc_malloc_debug.so.

The symbols exported by libc_malloc_debug.so are maintained at exactly
the same version as libc.so.

Finally, static binaries will no longer be able to use malloc
debugging features since they cannot preload the debugging DSO.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
Tested-by: Carlos O'Donell <carlos@redhat.com>
71 files changed:
NEWS
Rules
catgets/Makefile
elf/Makefile
elf/tst-leaks1-static.c [deleted file]
iconvdata/Makefile
intl/tst-gettext.sh
libio/Makefile
localedata/Makefile
malloc/Makefile
malloc/Versions
malloc/arena.c
malloc/hooks.c
malloc/malloc-debug.c [new file with mode: 0644]
malloc/malloc.c
malloc/mcheck.c
malloc/mtrace.c
malloc/tst-compathooks-off.c [new file with mode: 0644]
malloc/tst-compathooks-on.c [new file with mode: 0644]
malloc/tst-malloc-usable-static-tunables.c [deleted file]
malloc/tst-malloc-usable-static.c [deleted file]
malloc/tst-mtrace.sh
manual/memory.texi
manual/tunables.texi
misc/Makefile
nptl/Makefile
posix/Makefile
resolv/Makefile
shlib-versions
stdio-common/Makefile
sysdeps/generic/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/mach/hurd/Makefile
sysdeps/mach/hurd/i386/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/pthread/Makefile
sysdeps/unix/sysv/linux/aarch64/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/alpha/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/arc/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/arm/be/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/arm/le/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/csky/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/hppa/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/hppa/shlib-versions
sysdeps/unix/sysv/linux/i386/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/ia64/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/ia64/shlib-versions
sysdeps/unix/sysv/linux/m68k/coldfire/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/m68k/m680x0/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/microblaze/be/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/microblaze/le/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/mips/mips32/fpu/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/mips/mips32/nofpu/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/mips/mips64/n32/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/mips/mips64/n64/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/mips/shlib-versions
sysdeps/unix/sysv/linux/nios2/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/riscv/rv32/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/riscv/rv64/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/s390/s390-32/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/s390/s390-64/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/sh/be/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/sh/le/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/sh/shlib-versions
sysdeps/unix/sysv/linux/sparc/sparc32/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/sparc/sparc64/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/sparc/sparc64/shlib-versions
sysdeps/unix/sysv/linux/x86_64/64/libc_malloc_debug.abilist [new file with mode: 0644]
sysdeps/unix/sysv/linux/x86_64/x32/libc_malloc_debug.abilist [new file with mode: 0644]