From owner-freebsd-arch@FreeBSD.ORG Wed Mar 26 01:18:29 2003 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 705D737B404 for ; Wed, 26 Mar 2003 01:18:29 -0800 (PST) Received: from skynet.stack.nl (skynet.stack.nl [131.155.140.225]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8B30243F93 for ; Wed, 26 Mar 2003 01:18:28 -0800 (PST) (envelope-from marcolz@stack.nl) Received: by skynet.stack.nl (Postfix, from userid 65534) id 0D43B3E32; Wed, 26 Mar 2003 10:19:01 +0100 (CET) Received: from turtle.stack.nl (turtle.stack.nl [2001:610:1108:5010::132]) by skynet.stack.nl (Postfix) with ESMTP id B85843E2D; Wed, 26 Mar 2003 10:19:00 +0100 (CET) Received: by turtle.stack.nl (Postfix, from userid 333) id DE2A11CC2D; Wed, 26 Mar 2003 10:18:26 +0100 (CET) Date: Wed, 26 Mar 2003 10:18:26 +0100 From: Marc Olzheim To: Jeff Roberson Message-ID: <20030326091826.GA79113@stack.nl> References: <20030326031245.O64602-100000@mail.chesapeake.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030326031245.O64602-100000@mail.chesapeake.net> X-Operating-System: FreeBSD turtle.stack.nl 5.0-CURRENT FreeBSD 5.0-CURRENT X-URL: http://www.stack.nl/~marcolz/ User-Agent: Mutt/1.5.4i X-Spam-Status: No, hits=-32.5 required=5.0 tests=EMAIL_ATTRIBUTION,IN_REP_TO,QUOTED_EMAIL_TEXT,REFERENCES, REPLY_WITH_QUOTES,USER_AGENT_MUTT autolearn=ham version=2.50 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) cc: arch@freebsd.org cc: kse@elischer.org cc: Julian Elischer Subject: Re: 1:1 Threading implementation. X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 26 Mar 2003 09:18:30 -0000 On Wed, Mar 26, 2003 at 03:36:57AM -0500, Jeff Roberson wrote: > First, if your application has more threads than cpus it is written > incorrectly. For people who are doing thread pools instead of event > driven IO models they will encounter the same overhead with M:N as 1:1. > I'm not sure what applications are entirely compute and have more threads > than cpus. These are the only ones which really theoretically benefit. I > don't think our threading model should be designed to optimize poorly > thought out applications. Might I suggest that there are 'nice' C++ ways of using thread-classes where both the usual C++ dogmas of readability and reuseability make you easily end up with more threads than cpus... I think that from a userland's point of view, most programmers shouldn't be caring less about how many cpus the machine has their core is running on. With this (not limited to) C++ model in mind, the M:N way would be a great thing to have. Zlo