Date: Sat, 28 Mar 2020 21:47:45 +0000 (UTC) From: Toomas Soome <tsoome@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r359407 - head/stand/libsa Message-ID: <202003282147.02SLljCo067522@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: tsoome Date: Sat Mar 28 21:47:44 2020 New Revision: 359407 URL: https://svnweb.freebsd.org/changeset/base/359407 Log: loader: add knob to build with user malloc This option is intended to aid development, to allow building with user malloc. The use case would be to build userboot & test with libc (or other) malloc and use extra malloc debug features. Modified: head/stand/libsa/stand.h Modified: head/stand/libsa/stand.h ============================================================================== --- head/stand/libsa/stand.h Sat Mar 28 20:43:15 2020 (r359406) +++ head/stand/libsa/stand.h Sat Mar 28 21:47:44 2020 (r359407) @@ -436,7 +436,14 @@ extern void mallocstats(void); const char *x86_hypervisor(void); -#ifdef DEBUG_MALLOC +#ifdef USER_MALLOC +extern void *malloc(size_t); +extern void *memalign(size_t, size_t); +extern void *calloc(size_t, size_t); +extern void free(void *); +extern void *realloc(void *, size_t); +extern void *reallocf(void *, size_t); +#elif DEBUG_MALLOC #define malloc(x) Malloc(x, __FILE__, __LINE__) #define memalign(x, y) Memalign(x, y, __FILE__, __LINE__) #define calloc(x, y) Calloc(x, y, __FILE__, __LINE__)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202003282147.02SLljCo067522>