Subject: Re: CVS commit: src/lib/libpthread
To: None <current-users@netbsd.org>
From: =?ISO-8859-1?Q?Stefan_Kr=FCger?= <skrueger@meinberlikomm.de>
List: current-users
Date: 03/07/2005 20:44:14
Christos Zoulas wrote:
> In article <420B69A9.6000103@meinberlikomm.de>,
> Stefan Krüger <skrueger@meinberlikomm.de> wrote:
>
>>Christos Zoulas wrote:
>>
>>>Module Name: src
>>>Committed By: christos
>>>Date: Thu Feb 10 02:20:49 UTC 2005
>>>
>>>Modified Files:
>>> src/lib/libpthread: pthread.c
>>>
>>>Log Message:
>>>If $PTHREAD_CONCURRENCY is not set, set it to ncpu
>>
>>do you also plan to fix pthread_kill?
>>
>>see src/regress/lib/libpthread/kill1/*
>>
>>I'm not sure but it may be related to some hardlocks I had w/
>>PTHREAD_CONCURRENCY=2 and firefox/ogg123, see Message-ID:
>><4206A2A2.5020400@meinberlikomm.de>
>
>
> I guess we will need to won't we? Is there a PR for this yet?
>
> christos
sry it took so long but I was quite busy...
anyway, I figured out how to (reproduceable!) panic a fresh netbsd
kernel (build today, from HEAD), with ogg123 but any other pthread app
may trigger it, too :(
again, I have a MP box and this only happens with PTHREAD_CONCURRENCY=2
here are my steps:
first I compiled a stripped down netbsd kernel w/ REALEXTMEM=32768 (I
need/want a small crashdump)
then I booted it with boot netbsd.minimal -s
...
$ mount -r /home (ogg file is saved there)
$ mount -r /usr
$ mount -r /usr/pkg
$ su -m ordinary_user
% env PTHREAD_CONCURRENCY=2 ogg123 song.ogg (let it a few secs play)
CRTL+Z
% fg
CRTL+C
Done. (<- Last msg from ogg123)
panic: kernel diagnostic assertion "p->p_nrlwps == 0" failed: file
"/usr/src/sys/kern/kern_exit.c", line 781
Stopped in pid 30.1 (csh) at netbsd:cpu_Debugger+0x4: popl %ebp
db{0}> bt
cpu_Debugger(c02b0062,c47cfec0,206,c031de80,c02d4cc0) at
netbsd:cpu_debugger+0x4
panic(c02f5280,c02b0def,c02b495f,c02d4800,30d) at netbsd:panic+0xb5
__assert(c02b0def,c02d4800,30d,c02b495f,0) at netbsd:__assert+0x2e
proc_free(c3e4cab4,bfbfe7e8,48,c47cff40,0) at netbsd:proc_free+0x81
sys_wait4(c3e4b6b4,c47cff70,c47cff68,c031daa8,c02fa834) at
netbsd:sys_wait4+0xf5
syscall_plain() at netbsd:syscall_plain+0x10f
--- syscall (number 7) ---
0xbdb3893f
db{0}> sync
...
I also got a crashdump but the netbsd.?.core is somehow damaged, I've
tried it several times but gdb refuses it :-(
so, what's next?