From owner-freebsd-threads@FreeBSD.ORG Sun Oct 9 02:45:50 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C80AB16A41F; Sun, 9 Oct 2005 02:45:50 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from mail.ntplx.net (mail.ntplx.net [204.213.176.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6B7CF43D46; Sun, 9 Oct 2005 02:45:50 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.ntplx.net (8.13.5/8.13.5/NETPLEX) with ESMTP id j992jnov001555; Sat, 8 Oct 2005 22:45:49 -0400 (EDT) Date: Sat, 8 Oct 2005 22:45:49 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Robert Watson In-Reply-To: <20051008165620.T17032@fledge.watson.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.ntplx.net) Cc: threads@freebsd.org Subject: Re: SIGINFO interrupts connect() with libpthread X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Oct 2005 02:45:50 -0000 On Sat, 8 Oct 2005, Robert Watson wrote: > > On Sat, 8 Oct 2005, Daniel Eischen wrote: > > > It only works with libc_r because libc_r wraps all these calls > > (including connect()) with poll(). Obviously we're not going to do that > > with libpthread. You're only seeing it with SIGINFO because we use > > SIGINFO as a debugging signal for libpthread (to dump thread state). > > libpthread doesn't install any other signal handlers unless the > > application does. We could use a different signal or not use SIGINFO at > > all. > > Ah, so this is why my /tmp is full of garbage :-): > > As you might guess, I like to hit ^T to find out what an application is > doing. Regardless of whether the application has its own SIGINFO handler > or not. libpthread should not implement SIGINFO unless some or another > special circumstances apply -- environmental variable, or compile option, > or such. Well, libc_r has been that way for years and it just carried over into libpthread. We could add another signal, but I'm confused on how signals should be added. We allow up to 128 signals, but only have 31 (up to SIGUSR2) defined and usable. When SIGTHR was added, NSIG wasn't bumped so it isn't found in valid signals by kill(1), and anything added after it would not be either without bumping NSIG. The comments for NSIG also say "number of old signals" and implies that new signals can be added without bumping NSIG. So either the comment is wrong, or kill(1) is wrong. And lib/libc/gen/siglist.c also bases everything on NSIG. -- DE From owner-freebsd-threads@FreeBSD.ORG Mon Oct 10 03:52:33 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7CE8116A41F; Mon, 10 Oct 2005 03:52:33 +0000 (GMT) (envelope-from hwh@gddsn.org.cn) Received: from gddsn.org.cn (gddsn.org.cn [218.19.164.145]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3DDFB43D45; Mon, 10 Oct 2005 03:52:32 +0000 (GMT) (envelope-from hwh@gddsn.org.cn) Received: from [192.168.168.129] (hwh [192.168.168.129]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by gddsn.org.cn (Postfix) with ESMTP id 2B9FC38CB4D; Mon, 10 Oct 2005 11:52:23 +0800 (CST) Message-ID: <4349E56E.6060300@gddsn.org.cn> Date: Mon, 10 Oct 2005 11:52:14 +0800 From: Huang wen hui User-Agent: Mozilla Thunderbird 1.0.6 (X11/20050812) X-Accept-Language: zh-cn,zh MIME-Version: 1.0 To: java@freebsd.org, threads@freebsd.org Content-Type: text/plain; charset=GB2312 Content-Transfer-Encoding: 7bit Cc: Subject: jdk15 and libthr X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Oct 2005 03:52:33 -0000 Hi, I try to use jdk15+libthr on 6.0 and CURRENT, somtimes jdk15 could not pass very simple Test: # cat TestThread.java public class TestThread extends Thread{ public TestThread() { } public void run() { try{ Thread.sleep(12); //Thread.sleep(1235); } catch(Exception ex) { } System.out.println("end"); } public static void main(String[] args) throws Exception { TestThread[] threads = new TestThread[5000]; for(int i=0;iget_state() == RUNNABLE,\"invalid os thread state\")") at /usr/ports/java/jdk15/work/hotspot/src/share/vm/utilities/debug.cpp:210 #8 0x287469af in _start (data=0x821dc18) at /usr/ports/java/jdk15/work/hotspot/src/os/bsd/vm/os_bsd.cpp:614 #9 0x28098e19 in pthread_create () from /usr/lib/libthr.so.2 #10 0x2809b650 in _thread_off_key_allocated () from /usr/lib/libthr.so.2 (gdb) up 8 #8 0x287469af in _start (data=0x81ae418) at /usr/ports/java/jdk15/work/hotspot/src/os/bsd/vm/os_bsd.cpp:614 warning: Source file is more recent than executable. 614 //assert(osthr->get_state() == RUNNABLE, "invalid os thread state"); Current language: auto; currently c++ (gdb) list 609 Thread* thread = (Thread*)data; 610 OSThread* osthr = thread->osthread(); 611 612 // XXXBSD: libc_r update required check was here 613 614 //assert(osthr->get_state() == RUNNABLE, "invalid os thread state"); 615 616 // initialize signal mask for this thread 617 os::Bsd::hotspot_sigmask(thread); 618 # cat hs_err_pid33807.log # # An unexpected error has been detected by HotSpot Virtual Machine: # # Internal Error (/usr/ports/java/jdk15/work/hotspot/src/os/bsd/vm/os_bsd.cpp, 614), pid=33807, tid=0x82d8200 # # Java VM: Java HotSpot(TM) Client VM (1.5.0-p2-hwh_08_oct_2005_14_04-debug mixed mode) # # Error: assert(osthr->get_state() == RUNNABLE,"invalid os thread state") --------------- T H R E A D --------------- Current thread is native thread Stack: [0xbf776000,0xbf7b6000), sp=0xbf7b5e04, free space=255k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) V [libjvm_g.so+0x6c92d4] V [libjvm_g.so+0x2ee4c5] V [libjvm_g.so+0x5d39af] C [libthr.so.2+0xde19] _pthread_create+0x5f9 --------------- P R O C E S S --------------- Java Threads: ( => current thread ) 0x0821dc18 JavaThread "Thread-1967" [_thread_new, id=137200128] 0x0817e818 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=135723520] 0x0817e418 JavaThread "CompilerThread0" daemon [_thread_blocked, id=135722752] 0x0817e018 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=135722240] 0x08104c18 JavaThread "Finalizer" daemon [_thread_blocked, id=135683840] 0x08104818 JavaThread "Reference Handler" daemon [_thread_blocked, id=135683584] 0x08078818 JavaThread "main" [_thread_blocked, id=134586368] Other Threads: 0x08165418 VMThread [id=135681280] 0x08102118 WatcherThread [id=135723776] VM state:not at safepoint (normal execution) VM Mutex/Monitor currently owned by a thread: None Heap def new generation total 576K, used 316K [0x2d920000, 0x2d9c0000, 0x2de00000) eden space 512K, 49% used [0x2d920000, 0x2d95f028, 0x2d9a0000) from space 64K, 100% used [0x2d9b0000, 0x2d9c0000, 0x2d9c0000) to space 64K, 0% used [0x2d9a0000, 0x2d9a0000, 0x2d9b0000) tenured generation total 1408K, used 204K [0x2de00000, 0x2df60000, 0x31920000) the space 1408K, 14% used [0x2de00000, 0x2de333e8, 0x2de33400, 0x2df60000) compacting perm gen total 8192K, used 1425K [0x31920000, 0x32120000, 0x35920000) the space 8192K, 17% used [0x31920000, 0x31a846d8, 0x31a84800, 0x32120000) No shared spaces configured. Dynamic libraries: 0x08048000 /usr/local/jdk1.5.0/bin/java_g 0x2808b000 /usr/lib/libthr.so.2 0x2809d000 /lib/libc.so.6 0x28173000 /usr/local/jdk1.5.0/jre/lib/i386/client/libjvm_g.so 0x289a5000 /lib/libm.so.4 0x289bc000 /usr/local/jdk1.5.0/jre/lib/i386/native_threads/libhpi_g.so 0x289ce000 /usr/local/jdk1.5.0/jre/lib/i386/libverify_g.so 0x289dc000 /usr/local/jdk1.5.0/jre/lib/i386/libjava_g.so 0x289fd000 /usr/local/jdk1.5.0/jre/lib/i386/libzip_g.so 0x28057000 /libexec/ld-elf.so.1 VM Arguments: java_command: TestThread Environment Variables: JAVA_HOME=/usr/local/jdk1.5.0 PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/games:/usr/local/sbin:/usr/local/bin:/usr/X11R6/bin:/root/bin LD_LIBRARY_PATH=/usr/local/jdk1.5.0/jre/lib/i386/client:/usr/local/jdk1.5.0/jre/lib/i386:/usr/local/jdk1.5.0/jre/../lib/i386SHELL=/bin/csh HOSTTYPE=FreeBSD OSTYPE=FreeBSD MACHTYPE=i386 --------------- S Y S T E M --------------- OS:FreeBSD uname:FreeBSD 7.0-CURRENT FreeBSD 7.0-CURRENT #87: Sun Oct 9 08:18:53 CST 2005 hwh@tp.gddsn.org.cn:/usr/obj/usr/src/sys/IBM01 i386 rlimit: STACK 65536k, CORE infinity, NOFILE 11095 CPU:total 1 family 6, cmov, cx8, fxsr, mmx Memory: 4k page, physical 1909116k vm_info: Java HotSpot(TM) Client VM (1.5.0-p2-hwh_08_oct_2005_14_04) for freebsd-x86, built on Oct 8 2005 15:25:45 by root with gcc 3.4.4 [FreeBSD] 20050518 From owner-freebsd-threads@FreeBSD.ORG Mon Oct 10 04:04:18 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 456D716A420; Mon, 10 Oct 2005 04:04:18 +0000 (GMT) (envelope-from bsddiy@126.com) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 00DF343D45; Mon, 10 Oct 2005 04:04:18 +0000 (GMT) (envelope-from bsddiy@126.com) Received: from [127.0.0.1] (davidxu@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j9A44Cor086913; Mon, 10 Oct 2005 04:04:15 GMT (envelope-from bsddiy@126.com) Message-ID: <4349E83C.4060401@126.com> Date: Mon, 10 Oct 2005 12:04:12 +0800 From: David Xu User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20050928 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Huang wen hui References: <4349E56E.6060300@gddsn.org.cn> In-Reply-To: <4349E56E.6060300@gddsn.org.cn> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: java@freebsd.org, threads@freebsd.org Subject: Re: jdk15 and libthr X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Oct 2005 04:04:18 -0000 The jdk has some code for libpthread and libc_r, that may be invalid for libthr. David Xu Huang wen hui wrote: >Hi, >I try to use jdk15+libthr on 6.0 and CURRENT, somtimes jdk15 could not >pass very simple Test: > > From owner-freebsd-threads@FreeBSD.ORG Mon Oct 10 11:02:16 2005 Return-Path: X-Original-To: freebsd-threads@freebsd.org Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7D55516A41F for ; Mon, 10 Oct 2005 11:02:16 +0000 (GMT) (envelope-from owner-bugmaster@freebsd.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 27ECC43D4C for ; Mon, 10 Oct 2005 11:02:16 +0000 (GMT) (envelope-from owner-bugmaster@freebsd.org) Received: from freefall.freebsd.org (peter@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j9AB2Gkt051519 for ; Mon, 10 Oct 2005 11:02:16 GMT (envelope-from owner-bugmaster@freebsd.org) Received: (from peter@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j9AB2E4l051513 for freebsd-threads@freebsd.org; Mon, 10 Oct 2005 11:02:14 GMT (envelope-from owner-bugmaster@freebsd.org) Date: Mon, 10 Oct 2005 11:02:14 GMT Message-Id: <200510101102.j9AB2E4l051513@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: peter set sender to owner-bugmaster@freebsd.org using -f From: FreeBSD bugmaster To: freebsd-threads@FreeBSD.org Cc: Subject: Current problem reports assigned to you X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Oct 2005 11:02:16 -0000 Current FreeBSD problem reports Critical problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2005/01/26] threads/76690threads fork hang in child for (-lc_r & -lthr) o [2005/05/11] threads/80887threads ULE with SMP broke libpthread/libthr on 5 2 problems total. Serious problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2000/07/18] kern/20016 threads pthreads: Cannot set scheduling timer/Can o [2000/08/26] kern/20861 threads libc_r does not honor socket timeouts o [2001/01/20] threads/24472threads libc_r does not honor SO_SNDTIMEO/SO_RCVT o [2001/01/25] threads/24632threads libc_r delicate deviation from libc in ha o [2001/01/25] kern/24641 threads pthread_rwlock_rdlock can deadlock o [2001/11/26] bin/32295 threads pthread dont dequeue signals o [2002/02/01] threads/34536threads accept() blocks other threads o [2002/05/25] kern/38549 threads the procces compiled whith pthread stoppe o [2002/06/27] threads/39922threads [PATCH?] Threaded applications executed w o [2002/08/04] kern/41331 threads Pthread library open sets O_NONBLOCK flag o [2003/03/02] threads/48856threads Setting SIGCHLD to SIG_IGN still leaves z o [2003/03/10] threads/49087threads Signals lost in programs linked with libc s [2004/03/15] kern/64313 threads FreeBSD (OpenBSD) pthread implicit set/un o [2004/08/26] threads/70975threads unexpected and unreliable behaviour when o [2004/10/05] threads/72353threads Assertion fails in /usr/src/lib/libpthrea o [2004/10/07] threads/72429threads threads blocked in stdio (fgets, etc) are o [2004/10/21] threads/72953threads fork() unblocks blocked signals w/o PTHRE o [2004/12/19] threads/75273threads FBSD 5.3 libpthread (KSE) bug o [2004/12/21] threads/75374threads pthread_kill() ignores SA_SIGINFO flag o [2005/01/26] threads/76694threads fork cause hang in dup()/close() function o [2005/03/10] threads/78660threads Java hangs unkillably in STOP state after o [2005/04/08] threads/79683threads svctcp_create() fails if multiple threads o [2005/04/28] threads/80435threads panic on high loads o [2005/05/19] threads/81258threads Thread specific data is sometimes assigne o [2005/08/02] threads/84483threads problems with devel/nspr and -lc_r on 4.x s [2005/08/10] threads/84778threads libpthread busy loop/hang with Java when o [2005/08/20] threads/85160threads [patch] libobjc + libpthread/libthr crash o [2005/09/12] threads/86004threads libthr broken on amd64 28 problems total. Non-critical problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2000/05/26] kern/18824 threads gethostbyname is not thread safe o [2000/06/13] kern/19247 threads uthread_sigaction.c does not do anything o [2000/10/21] kern/22190 threads A threaded read(2) from a socketpair(2) f o [2001/09/09] threads/30464threads pthread mutex attributes -- pshared o [2002/05/02] threads/37676threads libc_r: msgsnd(), msgrcv(), pread(), pwri s [2002/07/16] threads/40671threads pthread_cancel doesn't remove thread from o [2004/07/13] threads/69020threads pthreads library leaks _gc_mutex o [2004/09/21] threads/71966threads Mlnet Core Dumped : Fatal error '_pq_inse o [2004/11/21] threads/74180threads KSE problem. Applications those riched ma o [2005/01/20] threads/76513threads libpthread is not working o [2005/04/13] threads/79887threads [patch] freopen() isn't thread-safe o [2005/05/13] threads/80992threads abort() sometimes not caught by gdb depen o [2005/05/26] threads/81534threads [PATCH] libc_r close() will fail on any f 13 problems total. From owner-freebsd-threads@FreeBSD.ORG Mon Oct 10 13:27:05 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8F6A916A41F; Mon, 10 Oct 2005 13:27:05 +0000 (GMT) (envelope-from hwh@gddsn.org.cn) Received: from gddsn.org.cn (gddsn.org.cn [218.19.164.145]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1DB1643D46; Mon, 10 Oct 2005 13:27:05 +0000 (GMT) (envelope-from hwh@gddsn.org.cn) Received: from [192.168.1.5] (unknown [218.20.158.17]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by gddsn.org.cn (Postfix) with ESMTP id 7747538CB4D; Mon, 10 Oct 2005 21:27:01 +0800 (CST) Message-ID: <434A6C22.7060506@gddsn.org.cn> Date: Mon, 10 Oct 2005 21:26:58 +0800 From: Huang wen hui User-Agent: Mozilla Thunderbird 1.0.6 (X11/20050912) X-Accept-Language: zh-cn,zh MIME-Version: 1.0 To: David Xu References: <4349E56E.6060300@gddsn.org.cn> <4349E83C.4060401@126.com> In-Reply-To: <4349E83C.4060401@126.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: java@freebsd.org, threads@freebsd.org Subject: Re: jdk15 and libthr X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Oct 2005 13:27:05 -0000 David Xu wrote: >The jdk has some code for libpthread and libc_r, that may be invalid >for libthr. > > with thr_create.c rev1.24, I test again many times TestThread.java. The problem seams to gone. thr_create.c Rev1.24 fixed this problem ? thanks, Mr. Xu! --hwh > >David Xu > > >Huang wen hui wrote: > > > >>Hi, >>I try to use jdk15+libthr on 6.0 and CURRENT, somtimes jdk15 could not >>pass very simple Test: >> >> >> >> From owner-freebsd-threads@FreeBSD.ORG Mon Oct 10 14:01:51 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from [127.0.0.1] (localhost [127.0.0.1]) by hub.freebsd.org (Postfix) with ESMTP id D5BDC16A420; Mon, 10 Oct 2005 14:01:49 +0000 (GMT) (envelope-from davidxu@freebsd.org) Message-ID: <434A7459.7080705@freebsd.org> Date: Mon, 10 Oct 2005 22:02:01 +0800 From: David Xu User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.7.10) Gecko/20050806 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Huang wen hui References: <4349E56E.6060300@gddsn.org.cn> <4349E83C.4060401@126.com> <434A6C22.7060506@gddsn.org.cn> In-Reply-To: <434A6C22.7060506@gddsn.org.cn> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: David Xu , threads@freebsd.org, java@freebsd.org Subject: Re: jdk15 and libthr X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Oct 2005 14:01:52 -0000 Huang wen hui wrote: > > David Xu wrote: > >> The jdk has some code for libpthread and libc_r, that may be invalid >> for libthr. >> >> > with thr_create.c rev1.24, I test again many times TestThread.java. > The problem seams to gone. thr_create.c Rev1.24 fixed this problem ? > > thanks, Mr. Xu! > > --hwh > Good news, I hope it is. :-) From owner-freebsd-threads@FreeBSD.ORG Tue Oct 11 22:34:06 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A75B216A420; Tue, 11 Oct 2005 22:34:06 +0000 (GMT) (envelope-from mi+mx@aldan.algebra.com) Received: from blue.virtual-estates.net (aldan.algebra.com [216.254.65.224]) by mx1.FreeBSD.org (Postfix) with ESMTP id B1BAC43D49; Tue, 11 Oct 2005 22:34:05 +0000 (GMT) (envelope-from mi+mx@aldan.algebra.com) Received: from corbulon.video-collage.com (static-151-204-231-237.bos.east.verizon.net [151.204.231.237]) by blue.virtual-estates.net (8.13.4/8.13.4) with ESMTP id j9BMY4cx023968 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 11 Oct 2005 18:34:04 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from mteterin.us.murex.com (195-11.customer.cloud9.net [168.100.195.11]) by corbulon.video-collage.com (8.13.4/8.13.1) with ESMTP id j9BMXwxG014021 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 11 Oct 2005 18:33:58 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from mteterin.us.murex.com (mteterin@localhost [127.0.0.1]) by mteterin.us.murex.com (8.13.3/8.13.3) with ESMTP id j9BMXrb1017385; Tue, 11 Oct 2005 18:33:53 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from localhost (localhost [[UNIX: localhost]]) by mteterin.us.murex.com (8.13.3/8.13.3/Submit) id j9BMXp81017384; Tue, 11 Oct 2005 18:33:51 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) X-Authentication-Warning: mteterin.us.murex.com: mteterin set sender to mi+mx@aldan.algebra.com using -f From: Mikhail Teterin Organization: Virtual Estates, Inc. To: re@freebsd.org Date: Tue, 11 Oct 2005 18:33:50 -0400 User-Agent: KMail/1.8.2 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200510111833.51168.mi+mx@aldan.algebra.com> X-Virus-Scanned: ClamAV devel-20050525/1128/Mon Oct 10 21:30:06 2005 on corbulon.video-collage.com X-Virus-Status: Clean X-Scanned-By: MIMEDefang 2.43 Cc: threads@freebsd.org Subject: debug defines in libc_r on 6.0 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Oct 2005 22:34:06 -0000 Hi! It seems, libc_r is still being built with -D_LOCK_DEBUG and -D_PTHREADS_INVARIANTS. I suspect, this is going to slow the thread operations somewhat: mi@mi:/usr/src (446) find lib/libc_r lib/libthr* -type f | xargs egrep _PTHREADS_INVARIANTS\|_LOCK_DEBUG lib/libc_r/Makefile:CFLAGS+=-D_LOCK_DEBUG lib/libc_r/Makefile:CFLAGS+=-D_PTHREADS_INVARIANTS lib/libc_r/uthread/pthread_private.h:#if defined(_PTHREADS_INVARIANTS) lib/libc_r/uthread/pthread_private.h:#if defined(_PTHREADS_INVARIANTS) lib/libc_r/uthread/pthread_private.h:/* Used for _PTHREADS_INVARIANTS checking. */ lib/libc_r/uthread/pthread_private.h:#ifdef _LOCK_DEBUG lib/libc_r/uthread/pthread_private.h:#if defined(_PTHREADS_INVARIANTS) lib/libc_r/uthread/uthread_exit.c: /* XXX - Do we want abort to be conditional on _PTHREADS_INVARIANTS? */ lib/libc_r/uthread/uthread_exit.c:#if defined(_PTHREADS_INVARIANTS) lib/libc_r/uthread/uthread_mutex.c:#if defined(_PTHREADS_INVARIANTS) lib/libc_r/uthread/uthread_priority_queue.c:#if defined(_PTHREADS_INVARIANTS) lib/libc_r/uthread/uthread_sig.c:#if defined(_PTHREADS_INVARIANTS) lib/libthr/Makefile:CFLAGS+=-D_PTHREADS_INVARIANTS -Wall lib/libthr/thread/thr_mutex.c:#if defined(_PTHREADS_INVARIANTS) lib/libthr/thread/thr_private.h:#ifdef _PTHREADS_INVARIANTS Should not these be undefined in the 6.0-RELEASE? -mi From owner-freebsd-threads@FreeBSD.ORG Tue Oct 11 23:01:07 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C78ED16A41F; Tue, 11 Oct 2005 23:01:07 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from mail.ntplx.net (mail.ntplx.net [204.213.176.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2914943D45; Tue, 11 Oct 2005 23:01:07 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.ntplx.net (8.13.5/8.13.5/NETPLEX) with ESMTP id j9BN0lDT005812; Tue, 11 Oct 2005 19:00:48 -0400 (EDT) Date: Tue, 11 Oct 2005 19:00:47 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Mikhail Teterin In-Reply-To: <200510111833.51168.mi+mx@aldan.algebra.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.ntplx.net) Cc: threads@freebsd.org, re@freebsd.org Subject: Re: debug defines in libc_r on 6.0 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Oct 2005 23:01:07 -0000 On Tue, 11 Oct 2005, Mikhail Teterin wrote: > Hi! > > It seems, libc_r is still being built with -D_LOCK_DEBUG and > -D_PTHREADS_INVARIANTS. > > I suspect, this is going to slow the thread operations somewhat: No, it's only a couple of instructions for a very few operations. I've already replied to you about these before. I don't care whether re@ turns them off or not, but go read my prior email on this topic. I should eliminate the #defines and always do the checks, so you wouldn't notice :( -- DE From owner-freebsd-threads@FreeBSD.ORG Tue Oct 11 23:36:51 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0AFCC16A420; Tue, 11 Oct 2005 23:36:51 +0000 (GMT) (envelope-from mi+mx@aldan.algebra.com) Received: from blue.virtual-estates.net (aldan.algebra.com [216.254.65.224]) by mx1.FreeBSD.org (Postfix) with ESMTP id 86D1043D45; Tue, 11 Oct 2005 23:36:49 +0000 (GMT) (envelope-from mi+mx@aldan.algebra.com) Received: from corbulon.video-collage.com (static-151-204-231-237.bos.east.verizon.net [151.204.231.237]) by blue.virtual-estates.net (8.13.4/8.13.4) with ESMTP id j9BNamaK024178 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 11 Oct 2005 19:36:48 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from mteterin.us.murex.com (195-11.customer.cloud9.net [168.100.195.11]) by corbulon.video-collage.com (8.13.4/8.13.1) with ESMTP id j9BNa7Bm015349 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 11 Oct 2005 19:36:42 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: from mteterin.us.murex.com (mteterin@localhost [127.0.0.1]) by mteterin.us.murex.com (8.13.3/8.13.3) with ESMTP id j9BNZGEc017699; Tue, 11 Oct 2005 19:35:26 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) Received: by mteterin.us.murex.com (8.13.3/8.13.3/Submit) id j9BNZ1GQ017691; Tue, 11 Oct 2005 19:35:01 -0400 (EDT) (envelope-from mi+mx@aldan.algebra.com) X-Authentication-Warning: mteterin.us.murex.com: mteterin set sender to mi+mx@aldan.algebra.com using -f From: Mikhail Teterin Organization: Virtual Estates, Inc. To: Daniel Eischen Date: Tue, 11 Oct 2005 19:34:55 -0400 User-Agent: KMail/1.8.2 References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-u" Content-Transfer-Encoding: 8bit Content-Disposition: inline Message-Id: <200510111934.56300.mi+mx@aldan.algebra.com> X-Virus-Scanned: ClamAV devel-20050525/1128/Mon Oct 10 21:30:06 2005 on corbulon.video-collage.com X-Virus-Status: Clean X-Scanned-By: MIMEDefang 2.43 Cc: threads@freebsd.org, re@freebsd.org Subject: Re: debug defines in libc_r on 6.0 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Oct 2005 23:36:51 -0000 צ×ÔÏÒÏË 11 ÖÏ×ÔÅÎØ 2005 19:00, Daniel Eischen ÷É ÎÁÐÉÓÁÌÉ: > No, it's only a couple of instructions for a very few operations. > I've already replied to you about these before. šI don't care > whether re@ turns them off or not, but go read my prior email > on this topic. šI should eliminate the #defines and always do > the checks, so you wouldn't notice :( We make such checks (however inexpensive) conditional on various DEBUG* and INVARIANTS* flags in the kernel and userspace should be no different. The whole idea of assert() is to provide a way to add debugging checks, which -- however cheap they are -- can be easily removed from a _release_ version of one's software. I remember your e-mail and continue to disagree with it -- the debugging information and checks are, understandably, precious to you, but if we lose, say, a MySQL benchmark by even a small percentage, the advocacy loss will be immense... IMHO, the flags should be removed in RELENG_6, or, at least, in RELENG_6_0. Respectfully, -mi From owner-freebsd-threads@FreeBSD.ORG Tue Oct 11 23:50:41 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7521016A41F; Tue, 11 Oct 2005 23:50:41 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from mail.ntplx.net (mail.ntplx.net [204.213.176.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1436543D48; Tue, 11 Oct 2005 23:50:38 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) by mail.ntplx.net (8.13.5/8.13.5/NETPLEX) with ESMTP id j9BNoWrL018928; Tue, 11 Oct 2005 19:50:32 -0400 (EDT) Date: Tue, 11 Oct 2005 19:50:32 -0400 (EDT) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Mikhail Teterin In-Reply-To: <200510111934.56300.mi+mx@aldan.algebra.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=X-UNKNOWN Content-Transfer-Encoding: QUOTED-PRINTABLE X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.ntplx.net) Cc: threads@freebsd.org, re@freebsd.org Subject: Re: debug defines in libc_r on 6.0 X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Eischen List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Oct 2005 23:50:41 -0000 On Tue, 11 Oct 2005, Mikhail Teterin wrote: > =D7=A6=D7=D4=CF=D2=CF=CB 11 =D6=CF=D7=D4=C5=CE=D8 2005 19:00, Daniel Eisc= hen =F7=C9 =CE=C1=D0=C9=D3=C1=CC=C9: > > No, it's only a couple of instructions for a very few operations. > > I've already replied to you about these before. =9AI don't care > > whether re@ turns them off or not, but go read my prior email > > on this topic. =9AI should eliminate the #defines and always do > > the checks, so you wouldn't notice :( > > We make such checks (however inexpensive) conditional on various DEBUG* a= nd > INVARIANTS* flags in the kernel and userspace should be no different. The > whole idea of assert() is to provide a way to add debugging checks, which= -- > however cheap they are -- can be easily removed from a _release_ version = of > one's software. That's why when I do anything else like this, I'll not make them conditional. They were initially conditional because we didn't know what was eventually going to be put behind them. Now we know and it's nothing. You're just seeing them because they say DEBUG and INVARIANTS. If they weren't conditional, noone would notice. > I remember your e-mail and continue to disagree with it -- the debugging > information and checks are, understandably, precious to you, but if we lo= se, > say, a MySQL benchmark by even a small percentage, the advocacy loss will= be > immense... Please know what it is you are talking about. MySQL benchmarks have been run with and without these flags without any change. > IMHO, the flags should be removed in RELENG_6, or, at least, in RELENG_6_= 0. I'm not having this discussion again. --=20 DE From owner-freebsd-threads@FreeBSD.ORG Wed Oct 12 05:20:29 2005 Return-Path: X-Original-To: freebsd-threads@freebsd.org Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BE33716A41F for ; Wed, 12 Oct 2005 05:20:29 +0000 (GMT) (envelope-from ashokumar.a@radixs.com) Received: from mailbox.radixs.com (mailbox.radixs.com [203.81.41.217]) by mx1.FreeBSD.org (Postfix) with ESMTP id DD42D43D45 for ; Wed, 12 Oct 2005 05:20:28 +0000 (GMT) (envelope-from ashokumar.a@radixs.com) Received: (qmail 31525 invoked by uid 507); 12 Oct 2005 05:22:25 -0000 Received: from unknown (HELO server11.private.radixs) (203.118.32.95) by 0 with SMTP; 12 Oct 2005 05:22:25 -0000 From: Ashokumar To: freebsd-threads@freebsd.org Content-Type: text/plain Date: Wed, 12 Oct 2005 13:20:25 +0800 Message-Id: <1129094425.7373.6.camel@server11> Mime-Version: 1.0 X-Mailer: Evolution 2.0.4 (2.0.4-6) Content-Transfer-Encoding: 7bit Subject: gdb not working X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 12 Oct 2005 05:20:29 -0000 gdb fails while trying to debug a simple multi threaded program with two threads. I am using FreeBSD5.4/SMP and gdb6.1.1. I am wondering there is any compatibility issues with FreeBSD5.4 and gdb6.1.1. Any other debuggers available for debugging multithreaded programs in FreeBSD? -Ashok From owner-freebsd-threads@FreeBSD.ORG Thu Oct 13 08:27:06 2005 Return-Path: X-Original-To: freebsd-threads@FreeBSD.org Delivered-To: freebsd-threads@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 64D9C16A420; Thu, 13 Oct 2005 08:27:06 +0000 (GMT) (envelope-from christian.meutes@de.clara.net) Received: from gundel.de.clara.net (gundel2.de.clara.net [212.82.225.189]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0F1F743D45; Thu, 13 Oct 2005 08:27:05 +0000 (GMT) (envelope-from christian.meutes@de.clara.net) Received: from bla.keyoz.org ([62.24.31.55]) by gundel.de.clara.net with esmtp (Exim 4.30; FreeBSD) id 1EPyQf-000M8G-Ip; Thu, 13 Oct 2005 10:27:09 +0200 Date: Thu, 13 Oct 2005 10:27:03 +0200 From: Christian Meutes To: freebsd-threads@FreeBSD.org, stable@freebsd.org, ports@freebsd.org Message-ID: <52C852D2E1DE99114638D11D@tobaco.qunec.de> X-Mailer: Mulberry/4.0.0b4 (Linux/x86) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Cc: Subject: MySQL(linuxthread) problem with Freeradius X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Oct 2005 08:27:06 -0000 Hi everyone, i have just found out why FreeRADIUS always crashs when loading the mysql module. I have compiled MySQL with linuxthreads and thats why FreeRADIUS always crashs with a Segmentation fault. I have tested this with MySQL 4 and 4.1 (both out of the ports), FreeBSD 5.4-Release and Stable and FreeRADIUS 1.0.4(ports) and FreeRADIUS 1.0.5. So you can see its able to get FreeRADIUS running on FreeBSD with MySQL(linuxthreads). When compiling MySQL with native threads its running just well, but with little performance suffer. Can anybody find out why Linuxthreads with MySQL are not running with FreeRADIUS? -christian From owner-freebsd-threads@FreeBSD.ORG Thu Oct 13 13:14:00 2005 Return-Path: X-Original-To: threads@freebsd.org Delivered-To: freebsd-threads@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AC2D316A41F; Thu, 13 Oct 2005 13:14:00 +0000 (GMT) (envelope-from christian.meutes@de.clara.net) Received: from gundel.de.clara.net (gundel2.de.clara.net [212.82.225.189]) by mx1.FreeBSD.org (Postfix) with ESMTP id B36EB43D70; Thu, 13 Oct 2005 13:13:57 +0000 (GMT) (envelope-from christian.meutes@de.clara.net) Received: from bla.keyoz.org ([62.24.31.55]) by gundel.de.clara.net with esmtp (Exim 4.30; FreeBSD) id 1EQ2uI-0009WR-0f; Thu, 13 Oct 2005 15:14:02 +0200 Date: Thu, 13 Oct 2005 15:13:56 +0200 From: Christian Meutes Message-ID: <96C054CCCCE25B7203317A4A@tobaco.qunec.de> X-Mailer: Mulberry/4.0.0b4 (Linux/x86) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Cc: ports@freebsd.org, threads@freebsd.org, stable@freebsd.org Subject: Re: MySQL(linuxthread) problem with Freeradius (fwd) X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Christian Meutes List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Oct 2005 13:14:00 -0000 Hi Jason, i tried freeradius from the ports 1.0.4 and i compiled it myself with newest version 1.0.5. both times it crashs when i had built mysql with linuxthreads. would be nice if you could reproduce this, but dont forget: you have to rebuilt freeradius when you switch from mysql-linuxthreads to mysql-pthreads, i think this is for importance, but i dont really know. please confirm as fast as possible to get this bug repaired. i dont exactly know if this is only a fault of the linuxthreads or maybe from mysql or freeradius too. -christian --On Thursday, October 13, 2005 08:00:44 -0500 JasonN wrote: > Man, thanks for talking about this issue. I've just installed MySQL > 4.1 with linux threads and I'm running the same dist. and FreeRADIUS > from the ports. Did you install from the ports? > >-- > >Jason A. Nunnelley >---------------------------------------- >http://www.jasonn.com/