From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1Ihc6I-0006EB-Il for garchives@archives.gentoo.org; Tue, 16 Oct 2007 02:24:07 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.14.1/8.14.0) with SMTP id l9G2CuYU002058; Tue, 16 Oct 2007 02:12:56 GMT Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by robin.gentoo.org (8.14.1/8.14.0) with ESMTP id l9G2AtJo032174 for ; Tue, 16 Oct 2007 02:10:56 GMT Received: from localhost (localhost [127.0.0.1]) by smtp.gentoo.org (Postfix) with ESMTP id 2C533651C8 for ; Tue, 16 Oct 2007 02:10:55 +0000 (UTC) X-Virus-Scanned: amavisd-new at gentoo.org X-Spam-Score: -0.018 X-Spam-Level: X-Spam-Status: No, score=-0.018 required=5.5 tests=[AWL=0.514, BAYES_00=-2.599, RCVD_NUMERIC_HELO=2.067] Received: from smtp.gentoo.org ([127.0.0.1]) by localhost (smtp.gentoo.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0PHUN6K9oE6z for ; Tue, 16 Oct 2007 02:10:48 +0000 (UTC) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTP id 4E23765049 for ; Tue, 16 Oct 2007 02:10:47 +0000 (UTC) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1Ihbt9-0008Qw-Av for gentoo-dev@gentoo.org; Tue, 16 Oct 2007 02:10:31 +0000 Received: from 82.153.64.56 ([82.153.64.56]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 16 Oct 2007 02:10:31 +0000 Received: from slong by 82.153.64.56 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 16 Oct 2007 02:10:31 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: gentoo-dev@lists.gentoo.org From: Steve Long Subject: [gentoo-dev] Re: Re: Re: [gentoo-commits] gentoo-x86 commit in app-misc/note: ChangeLog note-1.3.3.ebuild Date: Tue, 16 Oct 2007 03:14:12 +0100 Message-ID: References: <20071015074250.GG23990@supernova> <200710150956.05673.bo.andresen@zlin.dk> <1192437335.1277.1.camel@uberlaptop.development.ltl> <20071015084353.GF30883@gentoo.org> <1192439259.1277.9.camel@uberlaptop.development.ltl> <1192492093.31537.2.camel@su.perronet.esiee.net> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Reply-to: gentoo-dev@lists.gentoo.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 82.153.64.56 User-Agent: KNode/0.10.4 Sender: news X-Archives-Salt: 80dd8c2b-0fb7-4704-95a6-eb2650ce641f X-Archives-Hash: 564085f282a7f547d2b7651acc78016c Gilles Dartiguelongue wrote: > I haven't reread the fine mans for a while but iirc, + could lead you to > hit the argument buffer limit of your shell. xargs has --max-args to get > around that and is also way faster than any -exec variant (at least > that's what the bench I did on a PIV2.6Ghz showed me about 4 months ago) > It doesn't: find will just execute the command as many times as needed (each time with an argument length maximally less than ARG_MAX. Well, it did when we tested this a couple of months ago.) So it's optimal in that sense. I have no idea on the timing measurements, but I don't like pipes and subshells as a rule (externals are bad enough!;>) It'd be interesting to see measurements over 100000 loops with long argument lists requiring multiple invocations per pass, I suppose. An array expansion can lead to an argument length greater than ARG_MAX however, eg funcToFix "${list[@]}" (I'd be kind of perturbed if the last case were infeasible since it would imply poor memory handling in BASH, and limit the scope of its usability.) -- gentoo-dev@gentoo.org mailing list