From owner-freebsd-hackers Mon Jul 15 3:39:48 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BC0CB37B400 for ; Mon, 15 Jul 2002 03:39:46 -0700 (PDT) Received: from goose.mail.pas.earthlink.net (goose.mail.pas.earthlink.net [207.217.120.18]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5A48043E65 for ; Mon, 15 Jul 2002 03:39:46 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0003.cvx40-bradley.dialup.earthlink.net ([216.244.42.3] helo=mindspring.com) by goose.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17U3Gb-0007Jt-00; Mon, 15 Jul 2002 03:39:45 -0700 Message-ID: <3D32A644.EE31B1C9@mindspring.com> Date: Mon, 15 Jul 2002 03:39:00 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Naje V Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: named pipes and pthread References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Naje V wrote: > Why opening of named pipe blocks all pthreads in process? Because the user space pthreads can only may threads work by trading a blocking operation for a non-blocking operation plus a context switch, and opening a named pipe can not be done via O_NDELAY, while preserving the semantics (i.e. "reader open waits for writer open"). Consider using a real pipe or a socket, instead. -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message