Put the custom allocator in its own lib, as to lessen the difficulty to switch between libc's allocator and a custom one (#7)
This commit is contained in:
parent
713f0f0302
commit
cb7f3c3fdf
85 changed files with 1121 additions and 877 deletions
32
allocator/src/vg/valgrind_mem_status.c
Normal file
32
allocator/src/vg/valgrind_mem_status.c
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
/* ************************************************************************** */
|
||||
/* */
|
||||
/* ::: :::::::: */
|
||||
/* valgrind_mem_status.c :+: :+: :+: */
|
||||
/* +:+ +:+ +:+ */
|
||||
/* By: maiboyer <maiboyer@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2024/05/12 23:08:47 by maiboyer #+# #+# */
|
||||
/* Updated: 2024/05/12 23:22:08 by maiboyer ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
#include "aq/internal_vg_funcs.h"
|
||||
|
||||
#ifdef VGFUNCS
|
||||
|
||||
void vg_mem_no_access(void *ptr, t_usize size)
|
||||
{
|
||||
VALGRIND_MAKE_MEM_NOACCESS(ptr, size);
|
||||
}
|
||||
|
||||
void vg_mem_undefined(void *ptr, t_usize size)
|
||||
{
|
||||
VALGRIND_MAKE_MEM_UNDEFINED(ptr, size);
|
||||
}
|
||||
|
||||
void vg_mem_defined(void *ptr, t_usize size)
|
||||
{
|
||||
VALGRIND_MAKE_MEM_DEFINED(ptr, size);
|
||||
}
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue