From owner-freebsd-current@FreeBSD.ORG Wed Jul 7 10:00:27 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CF2DF16A4CE for ; Wed, 7 Jul 2004 10:00:27 +0000 (GMT) Received: from srv1.cosmo-project.de (srv1.cosmo-project.de [213.83.6.106]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2A3B343D46 for ; Wed, 7 Jul 2004 10:00:27 +0000 (GMT) (envelope-from ticso@cicely12.cicely.de) Received: from cicely5.cicely.de (cicely5.cicely.de [IPv6:3ffe:400:8d0:301:200:92ff:fe9b:20e7]) (authenticated bits=0) i67A0JaI089143 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Wed, 7 Jul 2004 12:00:20 +0200 (CEST) (envelope-from ticso@cicely12.cicely.de) Received: from cicely12.cicely.de (cicely12.cicely.de [IPv6:3ffe:400:8d0:301::12]) by cicely5.cicely.de (8.12.10/8.12.10) with ESMTP id i679xpUi004734 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 7 Jul 2004 11:59:51 +0200 (CEST) (envelope-from ticso@cicely12.cicely.de) Received: from cicely12.cicely.de (localhost [127.0.0.1]) by cicely12.cicely.de (8.12.11/8.12.11) with ESMTP id i679xo7F021809; Wed, 7 Jul 2004 11:59:50 +0200 (CEST) (envelope-from ticso@cicely12.cicely.de) Received: (from ticso@localhost) by cicely12.cicely.de (8.12.11/8.12.11/Submit) id i679xoKj021808; Wed, 7 Jul 2004 11:59:50 +0200 (CEST) (envelope-from ticso) Date: Wed, 7 Jul 2004 11:59:50 +0200 From: Bernd Walter To: Poul-Henning Kamp Message-ID: <20040707095949.GF12877@cicely12.cicely.de> References: <20040707091311.GE12877@cicely12.cicely.de> <33631.1089191774@critter.freebsd.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <33631.1089191774@critter.freebsd.dk> X-Operating-System: FreeBSD cicely12.cicely.de 5.2-CURRENT alpha User-Agent: Mutt/1.5.6i X-Spam-Status: No, hits=-4.9 required=3.0 tests=BAYES_00 autolearn=ham version=2.63 X-Spam-Report: * -4.9 BAYES_00 BODY: Bayesian spam probability is 0 to 1% * [score: 0.0000] X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on cicely12.cicely.de cc: FreeBSD current users cc: mycroft@netbsd.org cc: ticso@cicely.de cc: Julian Elischer Subject: Re: speeding up ugen by an order of magnitude. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: ticso@cicely.de List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Jul 2004 10:00:27 -0000 On Wed, Jul 07, 2004 at 11:16:14AM +0200, Poul-Henning Kamp wrote: > In message <20040707091311.GE12877@cicely12.cicely.de>, Bernd Walter writes: > >On Tue, Jul 06, 2004 at 04:32:28PM -0700, Julian Elischer wrote: > > >What about those options: > >- limit the allocated memory to the user request so we don't take the > > whole 128k if not reuired. > >- Do interleaving with 2 or more xfers if the read request is known to > > take more xfers. > > I would consider ugen to be a primary candidate to use physio like > I belive scsi-tape drives do ? I don't really know the points between physio and the current way. The story with USB bulk transfers is that legal transfers can have a data size of even down to 0 bytes and a lot a typical clients do small transfers - just depends on the designers needs. In the current code it seems that short transfers are already broken at least I don't see where short transfers can break out of the while loop so the knowledge about the real transfers size is lost. Under normal conditions we should break out on short transfers and return the so far transfered size. We should also be able to do interleaving some day. If you think that the requirements wouldn't collide with physio then OK. Nevertheless I see ugen more as a quick and dirty way to test drive a device from userland with all it's great debugging capabilities before writing a specific kernel driver. The requirement that ugen has to be generic is often bad for performance sensitive applications. -- B.Walter BWCT http://www.bwct.de bernd@bwct.de info@bwct.de