[PATCH] D71786: RFC: [Support] On Windows, add optional support for rpmalloc

Alexandre Ganea via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 14 08:33:24 PDT 2020


aganea added a comment.

Ping!

Would reviewers be ok if I changed this patch to always compile `rpmalloc.c` as part of LLVM (no cmake flag), but only make it active on demand? (with something like `-fintegrated-crt-alloc` in both Clang and LLD)
Additionally, I could provide a cmake hook for linking in an external CRT alloc .lib, such as mimalloc or tcmalloc3. In which case, `-fintegrated-crt-alloc` would use that lib instead.

If we go that route, does Linux support some kind of early entry point (before (m)allocations can occur), like TLS callbacks <https://resources.infosecinstitute.com/debugging-tls-callbacks/#gref> on Windows? It is true Linux users could use `LD_PRELOAD` to achieve the goal of this patch, I am simply wondering if we should have an uniform (integrated-crt-alloc) behavior across platforms.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D71786/new/

https://reviews.llvm.org/D71786





More information about the llvm-commits mailing list