From owner-freebsd-current@FreeBSD.ORG Wed Apr 25 13:07:00 2007 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EFDD716A400; Wed, 25 Apr 2007 13:07:00 +0000 (UTC) (envelope-from citrin@citrin.ru) Received: from mail.classis.ru (classis.ru [213.248.60.120]) by mx1.freebsd.org (Postfix) with ESMTP id ABA1D13C455; Wed, 25 Apr 2007 13:07:00 +0000 (UTC) (envelope-from citrin@citrin.ru) Received: from citrin (unknown [81.19.65.68]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: citrin.citrin.ru) by mail.classis.ru (Postfix) with ESMTP id A22031227C25; Wed, 25 Apr 2007 17:06:59 +0400 (MSD) Date: Wed, 25 Apr 2007 17:05:51 +0400 From: Anton Yuzhaninov X-Mailer: The Bat! (v3.62.14) Professional Organization: Rambler X-Priority: 3 (Normal) Message-ID: <578626816.20070425170551@citrin.ru> To: Jason Evans In-Reply-To: <4627DD1B.2080806@freebsd.org> References: <313993633.20070419232238@citrin.ru> <4627DD1B.2080806@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 8bit Cc: freebsd-current@freebsd.org Subject: Re[2]: clamd memory corruption (may be jemalloc related) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Apr 2007 13:07:01 -0000 Hello Jason, You wrote on Friday, April 20, 2007, 1:20:27 AM: JE> Anton Yuzhaninov wrote: >> I try to test clamav 0.90.2 on current and got strange errors: >> >> LibClamAV Warning: Multipart/alternative MIME message contains no boundary header >> LibClamAV Warning: Multipart/ZZZZZZZZZZZZÇÇÇÇÀå MIME message contains no boundary header >> LibClamAV Warning: Multipart/related MIME message contains no boundary header JE> The only race condition issue for malloc that I know of has to do with JE> rtld not replacing the libc spinlock stubs with threaded JE> implementations. However, I am pretty sure that this problem only shows JE> up when versioned symbols are enabled. JE> malloc's locking methodology is pretty straightforward, which makes me JE> reasonably confident about its correctness. If your debugging efforts JE> point you at malloc, you should try reverting to phkmalloc to see if JE> that makes the problem go away. As I wrote bug was in clamav... Big thanks for new malloc - it work very fast and scales well with SMP. For test was used system with 2 CPU x 4 cores. clamd scan time with jemalloc (under current) - 5.6 seconds. Same hardware, but with 6.2 stable - 274.8 seconds (and with 8 cores it several times slower than with only one core). -- Anton Yuzhaninov.