From owner-freebsd-hackers@FreeBSD.ORG Tue Feb 22 06:27:17 2005 Return-Path: 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 24BAB16A4CE for ; Tue, 22 Feb 2005 06:27:17 +0000 (GMT) Received: from agava.mipt.ru (ofc2.agava.net [81.5.88.62]) by mx1.FreeBSD.org (Postfix) with ESMTP id 66F9F43D3F for ; Tue, 22 Feb 2005 06:27:16 +0000 (GMT) (envelope-from rzhe@agava.com) Received: by agava.mipt.ru (Postfix, from userid 426) id 1A037877CBC; Tue, 22 Feb 2005 09:26:35 +0300 (MSK) Received: from mailhub (localhost [127.0.0.1]) by localhost (Postfix) with ESMTP id E9C08877DFF for ; Tue, 22 Feb 2005 09:26:34 +0300 (MSK) Received: from rzhe.agava-dubna.local (unknown [213.33.195.194]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (No client certificate requested) by agava.mipt.ru (Postfix) with ESMTP id 9C3FC877CBC for ; Tue, 22 Feb 2005 09:26:34 +0300 (MSK) Date: Tue, 22 Feb 2005 09:27:13 +0300 From: Dmitry Agaphonov To: freebsd-hackers@freebsd.org Message-Id: <20050222092713.43ed42c3.rzhe@agava.com> Organization: AGAVA Software X-Mailer: Sylpheed version 0.9.4claws (GTK+ 1.2.10; i386-portbld-freebsd4.8) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Kernel threads & libc X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Feb 2005 06:27:17 -0000 Hello all, I'm forced to implement kernel threads in application not via LinuxThreads library (because it doesn't compile on FreeBSD 4.10 with gcc-3.4.4, too much errors while processing /usr/src code), but using rfork_thread(3). And the main question I currently stuck on is which libc functions I need to wrap to make them thread-safe and reentrant on multiprocessor systems, since rfork_thread(3)s are created with RFMEM flag and libc_r is not used. Could somebody please give ideas or point me to the appropriate reading? Thanks!