|
From: <sv...@va...> - 2005-08-19 00:15:47
|
Author: dirk
Date: 2005-08-19 01:15:43 +0100 (Fri, 19 Aug 2005)
New Revision: 4453
Log:
merge 4439: Fix broken malloc_usable_size()
Added:
branches/VALGRIND_3_0_BRANCH/memcheck/tests/malloc_usable.c
branches/VALGRIND_3_0_BRANCH/memcheck/tests/malloc_usable.stderr.exp
branches/VALGRIND_3_0_BRANCH/memcheck/tests/malloc_usable.vgtest
Modified:
branches/VALGRIND_3_0_BRANCH/coregrind/m_mallocfree.c
branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_mallocfree.h
branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_replacemalloc.h
branches/VALGRIND_3_0_BRANCH/memcheck/tests/Makefile.am
Modified: branches/VALGRIND_3_0_BRANCH/coregrind/m_mallocfree.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/VALGRIND_3_0_BRANCH/coregrind/m_mallocfree.c 2005-08-19 00:1=
4:07 UTC (rev 4452)
+++ branches/VALGRIND_3_0_BRANCH/coregrind/m_mallocfree.c 2005-08-19 00:1=
5:43 UTC (rev 4453)
@@ -1197,7 +1197,7 @@
}
=20
=20
-SizeT VG_(arena_payload_szB) ( ArenaId aid, void* ptr )
+SizeT VG_(arena_payload_szB) ( ThreadId tid, ArenaId aid, void* ptr )
{
Arena* a =3D arenaId_to_ArenaP(aid);
Block* b =3D get_payload_block(a, ptr);
Modified: branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_mallocfree.h
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_mallocfree.h 2005-08-=
19 00:14:07 UTC (rev 4452)
+++ branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_mallocfree.h 2005-08-=
19 00:15:43 UTC (rev 4453)
@@ -81,7 +81,7 @@
must be called before any of VG_(malloc) and friends are called. */
extern void VG_(set_client_malloc_redzone_szB) ( SizeT rz_szB );
=20
-extern SizeT VG_(arena_payload_szB) ( ArenaId aid, void* payload );
+extern SizeT VG_(arena_payload_szB) ( ThreadId tid, ArenaId aid, void* p=
);
=20
extern void VG_(sanity_check_malloc_all) ( void );
=20
Modified: branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_replacemalloc.h
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_replacemalloc.h 2005-=
08-19 00:14:07 UTC (rev 4452)
+++ branches/VALGRIND_3_0_BRANCH/coregrind/pub_core_replacemalloc.h 2005-=
08-19 00:15:43 UTC (rev 4453)
@@ -50,7 +50,7 @@
void (*tl___builtin_vec_delete)(ThreadId tid, void* p);
void* (*tl_realloc) (ThreadId tid, void* p, SizeT size);
=20
- SizeT (*arena_payload_szB) (ArenaId aid, void* payload);
+ SizeT (*arena_payload_szB) (ThreadId tid, ArenaId aid, void* pay=
load);
Bool clo_trace_malloc;
};
=20
Modified: branches/VALGRIND_3_0_BRANCH/memcheck/tests/Makefile.am
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/VALGRIND_3_0_BRANCH/memcheck/tests/Makefile.am 2005-08-19 00=
:14:07 UTC (rev 4452)
+++ branches/VALGRIND_3_0_BRANCH/memcheck/tests/Makefile.am 2005-08-19 00=
:15:43 UTC (rev 4453)
@@ -39,6 +39,7 @@
leak-tree.stderr.exp2 leak-tree.stderr.exp64 \
leak-regroot.vgtest leak-regroot.stderr.exp \
leakotron.vgtest leakotron.stdout.exp leakotron.stderr.exp \
+ malloc_usable.stderr.exp malloc_usable.vgtest \
malloc1.stderr.exp malloc1.vgtest \
malloc2.stderr.exp malloc2.vgtest \
malloc3.stderr.exp malloc3.stdout.exp malloc3.vgtest \
@@ -99,7 +100,7 @@
doublefree error_counts errs1 exitprog execve execve2 erringfds \
fprw fwrite hello inits inline \
leak-0 leak-cycle leak-tree leak-regroot leakotron \
- malloc1 malloc2 malloc3 manuel1 manuel2 manuel3 \
+ malloc_usable malloc1 malloc2 malloc3 manuel1 manuel2 manuel3 \
match-overrun \
memalign_test memalign2 memcmptest mempool mmaptest \
nanoleak new_nothrow \
Copied: branches/VALGRIND_3_0_BRANCH/memcheck/tests/malloc_usable.c (from=
rev 4439, trunk/memcheck/tests/malloc_usable.c)
Copied: branches/VALGRIND_3_0_BRANCH/memcheck/tests/malloc_usable.stderr.=
exp (from rev 4439, trunk/memcheck/tests/malloc_usable.stderr.exp)
Copied: branches/VALGRIND_3_0_BRANCH/memcheck/tests/malloc_usable.vgtest =
(from rev 4439, trunk/memcheck/tests/malloc_usable.vgtest)
|