From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: YAMAMOTO Mitsuharu Newsgroups: gmane.emacs.devel Subject: Re: Building Emacs overflowed pure space Date: Wed, 19 Jul 2006 18:46:44 +0900 Organization: Faculty of Science, Chiba University Message-ID: References: <7dbe73ed0607180138x35e9d9bft3e42f20cb369795c@mail.gmail.com> <200607181929.k6IJTZN9028639@jane.dms.auburn.edu> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII X-Trace: sea.gmane.org 1153302437 7472 80.91.229.2 (19 Jul 2006 09:47:17 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 19 Jul 2006 09:47:17 +0000 (UTC) Cc: mathias.dahl@gmail.com, Luc Teirlinck , ralphm@members.fsf.org, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Jul 19 11:47:15 2006 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1G38dw-00074t-OV for ged-emacs-devel@m.gmane.org; Wed, 19 Jul 2006 11:47:01 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1G38dw-00074C-B0 for ged-emacs-devel@m.gmane.org; Wed, 19 Jul 2006 05:47:00 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1G38dl-00073H-0b for emacs-devel@gnu.org; Wed, 19 Jul 2006 05:46:49 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1G38dj-00072y-FA for emacs-devel@gnu.org; Wed, 19 Jul 2006 05:46:48 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1G38dj-00072r-9H for emacs-devel@gnu.org; Wed, 19 Jul 2006 05:46:47 -0400 Original-Received: from [133.82.132.2] (helo=mathmail.math.s.chiba-u.ac.jp) by monty-python.gnu.org with esmtp (Exim 4.52) id 1G38gn-0003BE-LU; Wed, 19 Jul 2006 05:49:58 -0400 Original-Received: from church.math.s.chiba-u.ac.jp (church [133.82.132.36]) by mathmail.math.s.chiba-u.ac.jp (Postfix) with ESMTP id B723C2CB4; Wed, 19 Jul 2006 18:46:44 +0900 (JST) Original-To: rms@gnu.org In-Reply-To: User-Agent: Wanderlust/2.14.0 (Africa) SEMI/1.14.6 (Maruoka) FLIM/1.14.6 (Marutamachi) APEL/10.6 Emacs/22.0.50 (sparc-sun-solaris2.8) MULE/5.0 (SAKAKI) 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:57329 Archived-At: >>>>> On Wed, 19 Jul 2006 18:22:44 +0900, YAMAMOTO Mitsuharu said: > Dumped with dolist in subr.el: 1209808 bytes used > dolist in cl.el: >1211000 bytes used (overflow) > dolist in cl.el with the modification > '--cl-dolist-temp-- -> '--dolist-temp-- : > 1209832 bytes used Sorry, I should have not used quote for uninterned symbols. I meant `dolist in cl-macs.el with the modification "--cl-dolist-temp--" -> "--dolist-temp--"'. BTW, I noticed some inefficiency of dolist in subr.el: (defmacro dolist (spec &rest body) "Loop over a list. Evaluate BODY with VAR bound to each car from LIST, in turn. Then evaluate RESULT to get return value, default nil. \(fn (VAR LIST [RESULT]) BODY...)" (declare (indent 1) (debug ((symbolp form &optional form) body))) (let ((temp (make-symbol "--dolist-temp--"))) `(let ((,temp ,(nth 1 spec)) ,(car spec)) (while ,temp (setq ,(car spec) (car ,temp)) (setq ,temp (cdr ,temp)) ,@body) ,@(if (cdr (cdr spec)) `((setq ,(car spec) nil) ,@(cdr (cdr spec))))))) In the above definition, `(setq ,temp (cdr ,temp))' is not placed at the end of the loop body, so it disables the following optimization in byte-opt.el: ;; X: varref-Y ... varset-Y goto-X --> ;; X: varref-Y Z: ... dup varset-Y goto-Z ;; (varset-X goto-BACK, BACK: varref-X --> copy the varref down.) ;; (This is so usual for while loops that it is worth handling). Is it OK to place `(setq ...)' after `,@body' as in the CL-version? YAMAMOTO Mitsuharu mituharu@math.s.chiba-u.ac.jp