Date: Wed, 8 Nov 2000 07:22:33 -0500 (EST) From: Daniel Eischen <eischen@vigrid.com> To: Alfred Perlstein <bright@wintelcom.net> Cc: jadream <jadream@chat.ru>, freebsd-questions@FreeBSD.ORG, deischen@FreeBSD.ORG, jasone@FreeBSD.ORG Subject: Re: Is msgrcv() thread-blocking in 4.x? Message-ID: <Pine.SUN.3.91.1001108071745.22005A-100000@pcnet1.pcnet.com> In-Reply-To: <20001107230204.Q5112@fw.wintelcom.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 7 Nov 2000, Alfred Perlstein wrote: > * Alfred Perlstein <bright@wintelcom.net> [001106 01:51] wrote: > > * jadream <jadream@chat.ru> [001106 00:11] wrote: > > > Hi ppl! > > > > > > I have two processes both multithreaded with threads from one process > > > comunicating with threads from another using SystemV IPC (msgs & > > > semaphores). > > > That used to work well under Linux as threads there are just same as > > > processes. > > > But when I came to the process-limit in Linux and had to change for > > > freeBSD all comes bad. > > > msgrcv() and semop() are blocking whole processes not appropriate > > > threads and I'm near the point of blowing up. > > Updated patch is here: > > http://people.freebsd.org/~alfred/uthread_sysvipc.diff I'd much rather see it go to sleep for a second or two rather than (possibly) spinning in a tighter loop. If it was the highest priority thread, then it would essentially be blocking. > it's for releng4, it makes the FreeBSD threads library poll on the > semaphores and msgqueues, not very good, but if/when I get a chance > I may try to hook kqueue into some of the sysv IPC stuff so that > we don't need to poll the primatives. This seems a better solution, at least for our current threads library implementation. -- Dan Eischen eischen@vigrid.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.SUN.3.91.1001108071745.22005A-100000>