From 18ad8234b6dc77a00493240779fe17f8431240d6 Mon Sep 17 00:00:00 2001 From: Jason Evans Date: Fri, 2 Apr 2010 13:48:39 -0700 Subject: [PATCH] Don't disable leak reporting due to sampling. Leak reporting is useful even if sampling is enabled; some leaks may not be reported, but those reported are still genuine leaks. --- jemalloc/doc/jemalloc.3.in | 4 +--- jemalloc/src/prof.c | 8 -------- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/jemalloc/doc/jemalloc.3.in b/jemalloc/doc/jemalloc.3.in index 7e80916e..f51e8066 100644 --- a/jemalloc/doc/jemalloc.3.in +++ b/jemalloc/doc/jemalloc.3.in @@ -38,7 +38,7 @@ .\" @(#)malloc.3 8.1 (Berkeley) 6/4/93 .\" $FreeBSD: head/lib/libc/stdlib/malloc.3 182225 2008-08-27 02:00:53Z jasone $ .\" -.Dd March 31, 2010 +.Dd April 2, 2010 .Dt JEMALLOC 3 .Os .Sh NAME @@ -486,8 +486,6 @@ The default value is 128 bytes. @roff_prof@also decreases the computational overhead. @roff_prof@The default sample interval is one (i.e. all allocations are @roff_prof@sampled). -@roff_prof@A sample interval greater than one implicitly disables leak -@roff_prof@reporting. @roff_prof@.It U @roff_prof@Trigger a memory profile dump every time the total virtual memory @roff_prof@exceeds the previous maximum. diff --git a/jemalloc/src/prof.c b/jemalloc/src/prof.c index 4cdebb9e..06df2a93 100644 --- a/jemalloc/src/prof.c +++ b/jemalloc/src/prof.c @@ -1259,14 +1259,6 @@ prof_boot0(void) * arenas are initialized, so this function must be executed early. */ - if (opt_lg_prof_sample > 0) { - /* - * Disable leak checking, since not all allocations will be - * sampled. - */ - opt_prof_leak = false; - } - if (opt_prof_leak && opt_prof == false) { /* * Enable opt_prof, but in such a way that profiles are never