From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Thien-Thi Nguyen Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] use tail pointer for LOOP Date: Thu, 17 Jun 2010 12:12:43 +0200 Message-ID: <87eig655no.fsf@ambire.localdomain> References: <4C018D79.7040409@censorshipresearch.org> <4C018FD3.1020305@censorshipresearch.org> <4C01AA28.6030002@censorshipresearch.org> <9718A5AD-7A74-470B-A32D-DA14266506A3@raeburn.org> <4C01B609.6070303@censorshipresearch.org> <20100616174420.GA2847@tomas> <87fx0msv9z.fsf@lola.goethe.zz> <20100617051021.GA26623@tomas> <87mxuu5dq3.fsf@ambire.localdomain> <20100617092232.GA27846@tomas> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1276769738 30662 80.91.229.12 (17 Jun 2010 10:15:38 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 17 Jun 2010 10:15:38 +0000 (UTC) Cc: emacs-devel@gnu.org To: tomas@tuxteam.de Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jun 17 12:15:36 2010 connect(): No such file or directory Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OPC8D-0000Wb-9i for ged-emacs-devel@m.gmane.org; Thu, 17 Jun 2010 12:15:33 +0200 Original-Received: from localhost ([127.0.0.1]:49251 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OPC89-0008GX-AN for ged-emacs-devel@m.gmane.org; Thu, 17 Jun 2010 06:15:29 -0400 Original-Received: from [140.186.70.92] (port=38687 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OPC7m-0008D0-0u for emacs-devel@gnu.org; Thu, 17 Jun 2010 06:15:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OPC7k-0008MZ-FW for emacs-devel@gnu.org; Thu, 17 Jun 2010 06:15:05 -0400 Original-Received: from smtp204.alice.it ([82.57.200.100]:45300) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OPC7k-0008M3-5q for emacs-devel@gnu.org; Thu, 17 Jun 2010 06:15:04 -0400 Original-Received: from ambire.localdomain (95.244.66.34) by smtp204.alice.it (8.5.124.05) id 4C0E61C000973F73; Thu, 17 Jun 2010 12:15:01 +0200 Original-Received: from ttn by ambire.localdomain with local (Exim 4.69) (envelope-from ) id 1OPC5U-0002AC-61; Thu, 17 Jun 2010 12:12:44 +0200 In-Reply-To: <20100617092232.GA27846@tomas> (tomas@tuxteam.de's message of "Thu, 17 Jun 2010 11:22:32 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:126073 Archived-At: () tomas@tuxteam.de () Thu, 17 Jun 2010 11:22:32 +0200 Oops, i didn't look at this carefully before: (defun do-benchmark (n) (let ((lst)) (while (> n 0) (setq lst (cons n lst) n (1- n))) (garbage-collect) (message (concat "copy1: %S\n" "copy2: %S\n" "copy3: %S\n") (benchmark-run (copy1 lst)) (benchmark-run (copy2 lst)) (benchmark-run (copy3 lst))))) Probably for more meaningful results, you should =E2=80=98garbage-collect= =E2=80=99 prior to each =E2=80=98benchmark-run=E2=80=99. Otherwise, each run is disa= dvantaged (less memory "easily" available) with respect to its predecessor. A standard benchmarking principle (useful in other disciplines, too) is to eliminate these differences. thi