mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-08 21:09:49 +00:00
Move VG_BUGS_TO to pub_tool_basics.h so that Nulgrind need not import
pub_tool_libcassert.h. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@6320
This commit is contained in:
@@ -32,7 +32,7 @@
|
||||
#define __PUB_TOOL_TOOLIFACE_H
|
||||
|
||||
#include "pub_tool_errormgr.h" // for Error, Supp
|
||||
#include "libvex.h" // for VexGuestLayout
|
||||
#include "libvex.h" // for all Vex stuff
|
||||
|
||||
/* ------------------------------------------------------------------ */
|
||||
/* The interface version */
|
||||
|
||||
@@ -3715,15 +3715,15 @@ VALGRIND_PRINTF_BACKTRACE(const char *format, ...)
|
||||
for calloc(). Put it immediately after the point where a block is
|
||||
allocated.
|
||||
|
||||
If you're allocating memory via superblocks, and then handing out small
|
||||
chunks of each superblock, if you don't have redzones on your small
|
||||
blocks, it's worth marking the superblock with VALGRIND_MAKE_MEM_NOACCESS
|
||||
when it's created, so that block overruns are detected. But if you can
|
||||
put redzones on, it's probably better to not do this, so that messages
|
||||
for small overruns are described in terms of the small block rather than
|
||||
the superblock (but if you have a big overrun that skips over a redzone,
|
||||
you could miss an error this way). See memcheck/tests/custom_alloc.c
|
||||
for an example.
|
||||
If you're using Memcheck: If you're allocating memory via superblocks,
|
||||
and then handing out small chunks of each superblock, if you don't have
|
||||
redzones on your small blocks, it's worth marking the superblock with
|
||||
VALGRIND_MAKE_MEM_NOACCESS when it's created, so that block overruns are
|
||||
detected. But if you can put redzones on, it's probably better to not do
|
||||
this, so that messages for small overruns are described in terms of the
|
||||
small block rather than the superblock (but if you have a big overrun
|
||||
that skips over a redzone, you could miss an error this way). See
|
||||
memcheck/tests/custom_alloc.c for an example.
|
||||
|
||||
WARNING: if your allocator uses malloc() or 'new' to allocate
|
||||
superblocks, rather than mmap() or brk(), this will not work properly --
|
||||
|
||||
Reference in New Issue
Block a user