You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(122) |
Nov
(152) |
Dec
(69) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(6) |
Feb
(25) |
Mar
(73) |
Apr
(82) |
May
(24) |
Jun
(25) |
Jul
(10) |
Aug
(11) |
Sep
(10) |
Oct
(54) |
Nov
(203) |
Dec
(182) |
| 2004 |
Jan
(307) |
Feb
(305) |
Mar
(430) |
Apr
(312) |
May
(187) |
Jun
(342) |
Jul
(487) |
Aug
(637) |
Sep
(336) |
Oct
(373) |
Nov
(441) |
Dec
(210) |
| 2005 |
Jan
(385) |
Feb
(480) |
Mar
(636) |
Apr
(544) |
May
(679) |
Jun
(625) |
Jul
(810) |
Aug
(838) |
Sep
(634) |
Oct
(521) |
Nov
(965) |
Dec
(543) |
| 2006 |
Jan
(494) |
Feb
(431) |
Mar
(546) |
Apr
(411) |
May
(406) |
Jun
(322) |
Jul
(256) |
Aug
(401) |
Sep
(345) |
Oct
(542) |
Nov
(308) |
Dec
(481) |
| 2007 |
Jan
(427) |
Feb
(326) |
Mar
(367) |
Apr
(255) |
May
(244) |
Jun
(204) |
Jul
(223) |
Aug
(231) |
Sep
(354) |
Oct
(374) |
Nov
(497) |
Dec
(362) |
| 2008 |
Jan
(322) |
Feb
(482) |
Mar
(658) |
Apr
(422) |
May
(476) |
Jun
(396) |
Jul
(455) |
Aug
(267) |
Sep
(280) |
Oct
(253) |
Nov
(232) |
Dec
(304) |
| 2009 |
Jan
(486) |
Feb
(470) |
Mar
(458) |
Apr
(423) |
May
(696) |
Jun
(461) |
Jul
(551) |
Aug
(575) |
Sep
(134) |
Oct
(110) |
Nov
(157) |
Dec
(102) |
| 2010 |
Jan
(226) |
Feb
(86) |
Mar
(147) |
Apr
(117) |
May
(107) |
Jun
(203) |
Jul
(193) |
Aug
(238) |
Sep
(300) |
Oct
(246) |
Nov
(23) |
Dec
(75) |
| 2011 |
Jan
(133) |
Feb
(195) |
Mar
(315) |
Apr
(200) |
May
(267) |
Jun
(293) |
Jul
(353) |
Aug
(237) |
Sep
(278) |
Oct
(611) |
Nov
(274) |
Dec
(260) |
| 2012 |
Jan
(303) |
Feb
(391) |
Mar
(417) |
Apr
(441) |
May
(488) |
Jun
(655) |
Jul
(590) |
Aug
(610) |
Sep
(526) |
Oct
(478) |
Nov
(359) |
Dec
(372) |
| 2013 |
Jan
(467) |
Feb
(226) |
Mar
(391) |
Apr
(281) |
May
(299) |
Jun
(252) |
Jul
(311) |
Aug
(352) |
Sep
(481) |
Oct
(571) |
Nov
(222) |
Dec
(231) |
| 2014 |
Jan
(185) |
Feb
(329) |
Mar
(245) |
Apr
(238) |
May
(281) |
Jun
(399) |
Jul
(382) |
Aug
(500) |
Sep
(579) |
Oct
(435) |
Nov
(487) |
Dec
(256) |
| 2015 |
Jan
(338) |
Feb
(357) |
Mar
(330) |
Apr
(294) |
May
(191) |
Jun
(108) |
Jul
(142) |
Aug
(261) |
Sep
(190) |
Oct
(54) |
Nov
(83) |
Dec
(22) |
| 2016 |
Jan
(49) |
Feb
(89) |
Mar
(33) |
Apr
(50) |
May
(27) |
Jun
(34) |
Jul
(53) |
Aug
(53) |
Sep
(98) |
Oct
(206) |
Nov
(93) |
Dec
(53) |
| 2017 |
Jan
(65) |
Feb
(82) |
Mar
(102) |
Apr
(86) |
May
(187) |
Jun
(67) |
Jul
(23) |
Aug
(93) |
Sep
(65) |
Oct
(45) |
Nov
(35) |
Dec
(17) |
| 2018 |
Jan
(26) |
Feb
(35) |
Mar
(38) |
Apr
(32) |
May
(8) |
Jun
(43) |
Jul
(27) |
Aug
(30) |
Sep
(43) |
Oct
(42) |
Nov
(38) |
Dec
(67) |
| 2019 |
Jan
(32) |
Feb
(37) |
Mar
(53) |
Apr
(64) |
May
(49) |
Jun
(18) |
Jul
(14) |
Aug
(53) |
Sep
(25) |
Oct
(30) |
Nov
(49) |
Dec
(31) |
| 2020 |
Jan
(87) |
Feb
(45) |
Mar
(37) |
Apr
(51) |
May
(99) |
Jun
(36) |
Jul
(11) |
Aug
(14) |
Sep
(20) |
Oct
(24) |
Nov
(40) |
Dec
(23) |
| 2021 |
Jan
(14) |
Feb
(53) |
Mar
(85) |
Apr
(15) |
May
(19) |
Jun
(3) |
Jul
(14) |
Aug
(1) |
Sep
(57) |
Oct
(73) |
Nov
(56) |
Dec
(22) |
| 2022 |
Jan
(3) |
Feb
(22) |
Mar
(6) |
Apr
(55) |
May
(46) |
Jun
(39) |
Jul
(15) |
Aug
(9) |
Sep
(11) |
Oct
(34) |
Nov
(20) |
Dec
(36) |
| 2023 |
Jan
(79) |
Feb
(41) |
Mar
(99) |
Apr
(169) |
May
(48) |
Jun
(16) |
Jul
(16) |
Aug
(57) |
Sep
(19) |
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
1
(17) |
2
(21) |
3
(17) |
4
(28) |
5
(21) |
6
(11) |
|
7
(13) |
8
(21) |
9
(21) |
10
(9) |
11
(11) |
12
(15) |
13
(23) |
|
14
(15) |
15
(22) |
16
(28) |
17
(12) |
18
(15) |
19
(8) |
20
(7) |
|
21
(8) |
22
(12) |
23
(13) |
24
(7) |
25
(7) |
26
(3) |
27
(9) |
|
28
(13) |
29
(7) |
30
(7) |
31
(9) |
|
|
|
|
From: Robert W. <rj...@du...> - 2004-03-14 20:05:25
|
> > The actual malloc in glibc appears to be capable of any reasonable > > alignment, but the default is 8 byte. >=20 > Correction - it defaults to "2 * sizeof(size_t)" which will only > be eight on a 32 bit platform - on amd64 and ia64 it will be sixteen. Golly, you mean the man pages are wrong!? That's unheard of! :-) Regards, Robert. --=20 Robert Walsh Amalgamated Durables, Inc. - "We don't make the things you buy." Email: rj...@du... |
|
From: Tom H. <th...@cy...> - 2004-03-14 13:03:54
|
In message <799...@lo...>
Tom Hughes <th...@cy...> wrote:
> The actual malloc in glibc appears to be capable of any reasonable
> alignment, but the default is 8 byte.
Correction - it defaults to "2 * sizeof(size_t)" which will only
be eight on a 32 bit platform - on amd64 and ia64 it will be sixteen.
Tom
--
Tom Hughes (th...@cy...)
Software Engineer, Cyberscience Corporation
http://www.cyberscience.com/
|
|
From: Tom H. <th...@cy...> - 2004-03-14 13:00:32
|
In message <200...@ac...>
Julian Seward <js...@ac...> wrote:
> On Sunday 14 March 2004 11:50, Doug Rabson wrote:
>
> > > Yep. I had a look at glibc and as far as I can see it only does 8
> > > byte alignment, even on x86-64.
> >
> > I don't know about amd64 but ia64 really wants 16 byte alignment for
> > malloc.
>
> Is there anybody on the list who has Linux on ia64 and can investigate
> what alignment GNU malloc returns on that platform? That would be
> helpful.
The actual malloc in glibc appears to be capable of any reasonable
alignment, but the default is 8 byte.
This can be altered by defining MALLOC_ALIGNMENT to the required
alignment, but a grep of the glibc sources found no sign of any
platform setting that, at least in the version I looked at, which
is the version from Fedora Core 1.
Tom
--
Tom Hughes (th...@cy...)
Software Engineer, Cyberscience Corporation
http://www.cyberscience.com/
|
|
From: Julian S. <js...@ac...> - 2004-03-14 12:41:17
|
On Sunday 14 March 2004 11:50, Doug Rabson wrote: > > Yep. I had a look at glibc and as far as I can see it only does 8 > > byte alignment, even on x86-64. > > I don't know about amd64 but ia64 really wants 16 byte alignment for > malloc. Is there anybody on the list who has Linux on ia64 and can investigate what alignment GNU malloc returns on that platform? That would be helpful. J |
|
From: Doug R. <df...@nl...> - 2004-03-14 11:51:26
|
On Saturday 13 March 2004 21:19, Tom Hughes wrote: > In message <107...@sp...> > > Robert Walsh <rj...@du...> wrote: > > > On that point, anybody planning to attack this should check what > > > alignment glibc uses on x86-64 as it have to return 16 byte > > > aligned pointers due to the use of SSE for floating point values. > > > It would be a bit silly to rework it for 8 buyte alignment and > > > then find we need 16 byte alignment ;-) > > > > On one of our Opteron boxes, I spotted this in the posix_memalign() > > man page: > > > > GNU libc malloc() always returns 8-byte aligned memory > > addresses, so these routines are only needed if you require > > larger alignment values. > > Yep. I had a look at glibc and as far as I can see it only does 8 > byte alignment, even on x86-64. I don't know about amd64 but ia64 really wants 16 byte alignment for malloc. |
|
From: <js...@ac...> - 2004-03-14 04:06:54
|
Nightly build on phoenix ( SuSE 8.2 ) started at 2004-03-14 04:00:00 GMT Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow resolv: valgrind ./resolv seg_override: valgrind ./seg_override sha1_test: valgrind ./sha1_test shortpush: valgrind ./shortpush shorts: valgrind ./shorts smc1: valgrind ./smc1 syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 143 tests, 5 stderr failures, 0 stdout failures ================= corecheck/tests/as_mmap (stderr) corecheck/tests/fdleak_fcntl (stderr) helgrind/tests/inherit (stderr) memcheck/tests/writev (stderr) memcheck/tests/zeropage (stderr) make: *** [regtest] Error 1 |
|
From: <js...@ac...> - 2004-03-14 03:47:51
|
Nightly build on nemesis ( SuSE 9.0 ) started at 2004-03-14 03:50:00 GMT Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 143 tests, 13 stderr failures, 0 stdout failures ================= corecheck/tests/as_mmap (stderr) corecheck/tests/fdleak_cmsg (stderr) corecheck/tests/fdleak_creat (stderr) corecheck/tests/fdleak_dup (stderr) corecheck/tests/fdleak_dup2 (stderr) corecheck/tests/fdleak_fcntl (stderr) corecheck/tests/fdleak_ipv4 (stderr) corecheck/tests/fdleak_open (stderr) corecheck/tests/fdleak_pipe (stderr) corecheck/tests/fdleak_socketpair (stderr) helgrind/tests/inherit (stderr) memcheck/tests/writev (stderr) memcheck/tests/zeropage (stderr) make: *** [regtest] Error 1 |
|
From: Tom H. <to...@co...> - 2004-03-14 03:22:51
|
Nightly build on dunsmere ( Fedora Core 1 ) started at 2004-03-14 03:20:02 GMT Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow == 148 tests, 16 stderr failures, 1 stdout failure ================= corecheck/tests/fdleak_cmsg (stderr) corecheck/tests/fdleak_creat (stderr) corecheck/tests/fdleak_dup (stderr) corecheck/tests/fdleak_dup2 (stderr) corecheck/tests/fdleak_fcntl (stderr) corecheck/tests/fdleak_ipv4 (stderr) corecheck/tests/fdleak_open (stderr) corecheck/tests/fdleak_pipe (stderr) corecheck/tests/fdleak_socketpair (stderr) helgrind/tests/inherit (stderr) memcheck/tests/buflen_check (stderr) memcheck/tests/execve (stderr) memcheck/tests/fwrite (stderr) memcheck/tests/trivialleak (stderr) memcheck/tests/weirdioctl (stderr) memcheck/tests/writev (stderr) none/tests/exec-sigmask (stdout) make: *** [regtest] Error 1 |
|
From: Tom H. <th...@cy...> - 2004-03-14 03:17:43
|
Nightly build on audi ( Red Hat 9 ) started at 2004-03-14 03:15:02 GMT Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow pushpopseg: valgrind ./pushpopseg rcl_assert: valgrind ./rcl_assert rcrl: valgrind ./rcrl readline1: valgrind ./readline1 resolv: valgrind ./resolv seg_override: valgrind ./seg_override sha1_test: valgrind ./sha1_test shortpush: valgrind ./shortpush shorts: valgrind ./shorts smc1: valgrind ./smc1 syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 148 tests, 1 stderr failure, 0 stdout failures ================= helgrind/tests/inherit (stderr) make: *** [regtest] Error 1 |
|
From: Tom H. <th...@cy...> - 2004-03-14 03:13:02
|
Nightly build on ginetta ( Red Hat 8.0 ) started at 2004-03-14 03:10:03 GMT Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow resolv: valgrind ./resolv seg_override: valgrind ./seg_override sha1_test: valgrind ./sha1_test shortpush: valgrind ./shortpush shorts: valgrind ./shorts smc1: valgrind ./smc1 syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 148 tests, 5 stderr failures, 0 stdout failures ================= helgrind/tests/deadlock (stderr) helgrind/tests/inherit (stderr) helgrind/tests/race (stderr) helgrind/tests/race2 (stderr) memcheck/tests/nanoleak (stderr) make: *** [regtest] Error 1 |
|
From: Tom H. <th...@cy...> - 2004-03-14 03:07:54
|
Nightly build on alvis ( Red Hat 7.3 ) started at 2004-03-14 03:05:03 GMT Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow smc1: valgrind ./smc1 syscall-restart1: valgrind ./syscall-restart1 syscall-restart2: valgrind ./syscall-restart2 system: valgrind ./system yield: valgrind ./yield -- Finished tests in none/tests ---------------------------------------- == 148 tests, 9 stderr failures, 1 stdout failure ================= helgrind/tests/deadlock (stderr) helgrind/tests/inherit (stderr) helgrind/tests/race (stderr) helgrind/tests/race2 (stderr) memcheck/tests/badfree-2trace (stderr) memcheck/tests/badjump (stderr) memcheck/tests/brk (stderr) memcheck/tests/error_counts (stdout) memcheck/tests/new_nothrow (stderr) memcheck/tests/writev (stderr) make: *** [regtest] Error 1 |
|
From: Julian S. <js...@ac...> - 2004-03-14 03:06:44
|
CVS commit by jseward:
Modify the memory manager so it "natively" supports 8-byte alignment,
basically by messing with the block layout.
* Move freelist next ptr from before payload to after it
* Ensure payload and red zones always have sizes which are
multiples of 8-bytes.
Seems to work OK. Values returned from the two basic allocator
functions VG_(arena_malloc) and VG_(arena_malloc_aligned) are
vg_asserted to have suitable alignment (== 8, >= 8 && == requested
alignment) respectively.
M +69 -37 vg_malloc2.c 1.22
--- valgrind/coregrind/vg_malloc2.c #1.21:1.22
@@ -56,5 +56,5 @@ Bool VG_(replacement_malloc_process_cmd_
VG_(clo_alignment) = (Int)VG_(atoll)(&arg[12]);
- if (VG_(clo_alignment) < 4
+ if (VG_(clo_alignment) < 8
|| VG_(clo_alignment) > 4096
|| VG_(log2)( VG_(clo_alignment) ) == -1 /* not a power of 2 */) {
@@ -62,5 +62,5 @@ Bool VG_(replacement_malloc_process_cmd_
VG_(message)(Vg_UserMsg,
"Invalid --alignment= setting. "
- "Should be a power of 2, >= 4, <= 4096.");
+ "Should be a power of 2, >= 8, <= 4096.");
VG_(bad_option)("--alignment");
}
@@ -147,8 +147,8 @@ typedef
this block total sizeW (1 word)
freelist previous ptr (1 word)
- freelist next ptr (1 word)
red zone words (depends on .rz_szW field of Arena)
(payload words)
red zone words (depends on .rz_szW field of Arena)
+ freelist next ptr (1 word)
this block total sizeW (1 word)
@@ -161,4 +161,8 @@ typedef
is not possible, because a block always has at least four words
of overhead.
+
+ 8-byte payload alignment is ensured by requiring the number
+ of words in the red zones and the number of payload words
+ to both be even (% 2 == 0).
*/
typedef
@@ -210,4 +214,6 @@ void arena_init ( Arena* a, Char* name,
{
Int i;
+ vg_assert(rz_szW >= 0);
+ vg_assert(rz_szW % 2 == 0);
vg_assert((min_sblockW % VKI_WORDS_PER_PAGE) == 0);
a->name = name;
@@ -249,4 +255,5 @@ static
void ensure_mm_init ( void )
{
+ Int client_rz_szW;
static Bool init_done = False;
@@ -260,23 +267,27 @@ void ensure_mm_init ( void )
zone words are unchanged. */
- arena_init ( &vg_arena[VG_AR_CORE], "core", 1, True, 262144, False );
+ arena_init ( &vg_arena[VG_AR_CORE], "core", 2, True, 262144, False );
- arena_init ( &vg_arena[VG_AR_TOOL], "tool", 1, True, 262144, False );
+ arena_init ( &vg_arena[VG_AR_TOOL], "tool", 2, True, 262144, False );
- arena_init ( &vg_arena[VG_AR_SYMTAB], "symtab", 1, True, 262144, False );
+ arena_init ( &vg_arena[VG_AR_SYMTAB], "symtab", 2, True, 262144, False );
- arena_init ( &vg_arena[VG_AR_JITTER], "JITter", 1, True, 8192, False );
+ arena_init ( &vg_arena[VG_AR_JITTER], "JITter", 2, True, 8192, False );
/* No particular reason for this figure, it's just smallish */
sk_assert(VG_(vg_malloc_redzone_szB) < 128);
+ sk_assert(VG_(vg_malloc_redzone_szB) >= 0);
+ client_rz_szW = VG_(vg_malloc_redzone_szB)/4;
+ if (client_rz_szW % 2 == 1) client_rz_szW++;
+
arena_init ( &vg_arena[VG_AR_CLIENT], "client",
- VG_(vg_malloc_redzone_szB)/4, False, 262144, True );
+ client_rz_szW, False, 262144, True );
arena_init ( &vg_arena[VG_AR_DEMANGLE], "demangle", 4 /*paranoid*/,
True, 16384, False );
- arena_init ( &vg_arena[VG_AR_EXECTXT], "exectxt", 1, True, 16384, False );
+ arena_init ( &vg_arena[VG_AR_EXECTXT], "exectxt", 2, True, 16384, False );
- arena_init ( &vg_arena[VG_AR_ERRORS], "errors", 1, True, 16384, False );
+ arena_init ( &vg_arena[VG_AR_ERRORS], "errors", 2, True, 16384, False );
arena_init ( &vg_arena[VG_AR_TRANSIENT], "transien", 2, True, 16384, False );
@@ -324,5 +335,6 @@ Superblock* newSuperblock ( Arena* a, In
if (a->clientmem) {
- sb = (Superblock *)VG_(client_alloc)(0, cszW * sizeof(Word),
+ sb = (Superblock *)
+ VG_(client_alloc)(0, cszW * sizeof(Word),
VKI_PROT_READ|VKI_PROT_WRITE|VKI_PROT_EXEC, 0);
} else
@@ -414,5 +426,5 @@ static __inline__
Word* first_to_payload ( Arena* a, WordF* fw )
{
- return & fw[3 + a->rz_szW];
+ return & fw[2 + a->rz_szW];
}
@@ -422,5 +434,5 @@ static __inline__
Word* payload_to_first ( Arena* a, WordF* payload )
{
- return & payload[- 3 - a->rz_szW];
+ return & payload[- (2 + a->rz_szW)];
}
@@ -444,5 +456,6 @@ void set_prev_p ( WordF* fw, Word* prev
static __inline__
void set_next_p ( WordF* fw, Word* next_p ) {
- fw[2] = (Word)next_p;
+ WordL* lw = first_to_last(fw);
+ lw[-1] = (Word)next_p;
}
static __inline__
@@ -452,5 +465,6 @@ Word* get_prev_p ( WordF* fw ) {
static __inline__
Word* get_next_p ( WordF* fw ) {
- return (Word*)(fw[2]);
+ WordL* lw = first_to_last(fw);
+ return (Word*)(lw[-1]);
}
@@ -482,5 +496,5 @@ static __inline__
void set_rz_lo_word ( Arena* a, WordF* fw, Int rz_wordno, Word w )
{
- fw[3 + rz_wordno] = w;
+ fw[2 + rz_wordno] = w;
}
static __inline__
@@ -488,10 +502,10 @@ void set_rz_hi_word ( Arena* a, WordF* f
{
WordL* lw = first_to_last(fw);
- lw[-1-rz_wordno] = w;
+ lw[-2-rz_wordno] = w;
}
static __inline__
Word get_rz_lo_word ( Arena* a, WordF* fw, Int rz_wordno )
{
- return fw[3 + rz_wordno];
+ return fw[2 + rz_wordno];
}
static __inline__
@@ -499,5 +513,5 @@ Word get_rz_hi_word ( Arena* a, WordF* f
{
WordL* lw = first_to_last(fw);
- return lw[-1-rz_wordno];
+ return lw[-2-rz_wordno];
}
@@ -508,10 +522,10 @@ static __inline__
Int overhead_szW_lo ( Arena* a )
{
- return 3 + a->rz_szW;
+ return 2 + a->rz_szW;
}
static __inline__
Int overhead_szW_hi ( Arena* a )
{
- return 1 + a->rz_szW;
+ return 2 + a->rz_szW;
}
static __inline__
@@ -949,4 +963,15 @@ Bool VG_(is_empty_arena) ( ArenaId aid )
+/* Turn a request size in bytes into a payload request size in
+ words. This means 8-aligning the request size.
+*/
+static __inline__
+Int req_pszB_to_req_pszW ( Int req_pszB )
+{
+ return ((req_pszB + 7) / 8) /* # of 64-bit units */
+ * 2; /* # of 32-bit units */
+}
+
+
/*------------------------------------------------------------*/
/*--- Core-visible functions. ---*/
@@ -959,4 +984,5 @@ void* VG_(arena_malloc) ( ArenaId aid, I
Word* b;
Arena* a;
+ void* v;
VGP_PUSHCC(VgpMalloc);
@@ -968,5 +994,5 @@ void* VG_(arena_malloc) ( ArenaId aid, I
vg_assert(req_pszB < 0x7FFFFFF0);
- req_pszW = (req_pszB + VKI_BYTES_PER_WORD - 1) / VKI_BYTES_PER_WORD;
+ req_pszW = req_pszB_to_req_pszW(req_pszB);
/* Keep gcc -O happy: */
@@ -1052,5 +1078,7 @@ void* VG_(arena_malloc) ( ArenaId aid, I
VGP_POPCC(VgpMalloc);
- return first_to_payload(a, b);
+ v = first_to_payload(a, b);
+ vg_assert( (((UInt)v) & 7) == 0 );
+ return v;
}
@@ -1179,4 +1207,5 @@ void* VG_(arena_malloc_aligned) ( ArenaI
UInt saved_bytes_on_loan;
Arena* a;
+ void* v;
VGP_PUSHCC(VgpMalloc);
@@ -1209,9 +1238,10 @@ void* VG_(arena_malloc_aligned) ( ArenaI
power of 2 >= word size, no need to align the alignment. Still,
we check. */
+ if (req_alignB == 4) req_alignB = 8;
req_alignW = req_alignB / VKI_BYTES_PER_WORD;
vg_assert(req_alignB == req_alignW * VKI_BYTES_PER_WORD);
/* Required payload size for the aligned chunk. */
- req_pszW = (req_pszB + VKI_BYTES_PER_WORD - 1) / VKI_BYTES_PER_WORD;
+ req_pszW = req_pszB_to_req_pszW(req_pszB);
/* Payload size to request for the big block that we will split
@@ -1278,5 +1308,7 @@ void* VG_(arena_malloc_aligned) ( ArenaI
VGP_POPCC(VgpMalloc);
- return align_p;
+ v = (void*)align_p;
+ vg_assert( (((UInt)v) % req_alignB) == 0 );
+ return v;
}
@@ -1296,5 +1328,5 @@ void* VG_(arena_calloc) ( ArenaId aid, I
vg_assert(size >= 0);
- if (alignB == 4)
+ if (alignB == 8)
p = VG_(arena_malloc) ( aid, size );
else
@@ -1339,5 +1371,5 @@ void* VG_(arena_realloc) ( ArenaId aid,
}
- if (req_alignB == 4)
+ if (req_alignB == 8)
p_new = VG_(arena_malloc) ( aid, req_pszB );
else
@@ -1373,10 +1405,10 @@ void VG_(free) ( void* ptr )
void* VG_(calloc) ( Int nmemb, Int nbytes )
{
- return VG_(arena_calloc) ( VG_AR_TOOL, /*alignment*/4, nmemb, nbytes );
+ return VG_(arena_calloc) ( VG_AR_TOOL, /*alignment*/8, nmemb, nbytes );
}
void* VG_(realloc) ( void* ptr, Int size )
{
- return VG_(arena_realloc) ( VG_AR_TOOL, ptr, /*alignment*/4, size );
+ return VG_(arena_realloc) ( VG_AR_TOOL, ptr, /*alignment*/8, size );
}
@@ -1389,6 +1421,6 @@ void* VG_(malloc_aligned) ( Int req_alig
void* VG_(cli_malloc) ( UInt align, Int nbytes )
{
- vg_assert(align >= 4);
- if (4 == align)
+ vg_assert(align >= 8);
+ if (8 == align)
return VG_(arena_malloc) ( VG_AR_CLIENT, nbytes );
else
|
|
From: Tom H. <th...@cy...> - 2004-03-14 03:01:02
|
Nightly build on standard ( Red Hat 7.2 ) started at 2004-03-14 03:00:03 GMT Checking out source tree ... done Configuring ... done Building ... done Running regression tests ... done Last 20 lines of log.verbose follow make[2]: Leaving directory `/tmp/valgrind.7607/valgrind/coregrind/x86' Making check in demangle make[2]: Entering directory `/tmp/valgrind.7607/valgrind/coregrind/demangle' make[2]: Nothing to be done for `check'. make[2]: Leaving directory `/tmp/valgrind.7607/valgrind/coregrind/demangle' Making check in . make[2]: Entering directory `/tmp/valgrind.7607/valgrind/coregrind' source='vg_signals.c' object='vg_signals.o' libtool=no \ depfile='.deps/vg_signals.Po' tmpdepfile='.deps/vg_signals.TPo' \ depmode=gcc3 /bin/sh ../depcomp \ gcc -DHAVE_CONFIG_H -I. -I. -I.. -I./demangle -I../include -I./x86 -DVG_LIBDIR="\"/tmp/valgrind.7607/valgrind/Inst/lib/valgrind"\" -Winline -Wall -Wshadow -O -fno-omit-frame-pointer -mpreferred-stack-boundary=2 -g -DELFSZ=32 -c `test -f 'vg_signals.c' || echo './'`vg_signals.c vg_signals.c: In function `fill_ehdr': vg_signals.c:1310: `ELFOSABI_LINUX' undeclared (first use in this function) vg_signals.c:1310: (Each undeclared identifier is reported only once vg_signals.c:1310: for each function it appears in.) make[2]: *** [vg_signals.o] Error 1 make[2]: Leaving directory `/tmp/valgrind.7607/valgrind/coregrind' make[1]: *** [check-recursive] Error 1 make[1]: Leaving directory `/tmp/valgrind.7607/valgrind/coregrind' make: *** [check-recursive] Error 1 |
|
From: Josef W. <Jos...@gm...> - 2004-03-14 00:15:02
|
Am Friday 05 March 2004 14:48 schrieb sun...@te...: > I expect that this will give me the number of instrumented functions inside > the stack, but sometimes I get more exits than entrances. > > Can anyone explain why this happens? Hi, CALL and RET instructions doesn't have to appear as pairs. This is not only true in handwritten assembler, but in compiler produced code, too. Think about longjmp, dynamic binding or exception handling. You could have CALL next next: POP xxx to get the PC into xxx or PUSH xxx RET to simulate a JMP. Besides, you can leave a function by adjusting the SP only. Josef |
|
From: Josef W. <Jos...@gm...> - 2004-03-14 00:14:21
|
Hi, [sorry for the late reply, I was in holiday] Am Monday 08 March 2004 02:00 schrieb Jeremy Fitzhardinge: > Yes, the heap size for Valgrind is set to a relatively small value. The > idea is that if a tool needs to allocate large chunks of memory, it > could use the shadow memory pool. For most tools, this is sized by a > well-understood ratio to the client memory size - but for calltree this > doesn't necessarily make a lot of sense. That's the problem here. It should be possible with a CLO to influence this ratio. > We could increase the Valgrind heap size pretty easily, but it eats into > the available client address space. > > How does Calltree use memory? What does it allocate? The same as Cachegrind, i.e. 64bit counters for cache events per instruction. But as there can be multiple counters for the same instruction (separation by thread, by caller context etc.) this already can be much more. Additionally, for call sites I maintain lists of callees with counters, and a shadow call stack for every thread. So I can't do a good estimation in advance, because the space needed depends on the client code. Would it be possible to make a command line option for bigger Valgrind heap space? If there is a out-of-memory condition, the error message could contain a tip to increase the VG heap space by using this CLO. Should I regard this as a problem of Valgrind core? I think I should release Calltree-0.9.7 for a broader "beta test" (before it is included into Suse 9.1). Josef |