Just dropped-in the tcmalloc
2.7, but for some reason my new which calls aligned_alloc still goes to glibc.
I've added following to the compiler options -fno-builtin-memalign -fno-builtin-aligned_alloc -fno-builtin-malloc -fno-builtin-calloc -fno-builtin-realloc -fno-builtin-free -nostdlib
with no visible effect.
Ubuntu 18.04, stock GCC, tcmalloc 2.7
Am I doing something wrong?
EDIT001: for some reason GCC
flag -flto=8
was causing this behavior, first I was suspecting the --gc-sections
messing with symbols, but it was proven to be wrong, somehow the -flto
did the difference.
If anyone knows why, you are most welcome to explain it here