From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Nicolaescu Newsgroups: gmane.emacs.devel Subject: Re: BASE_PURESIZE Date: Sat, 24 Oct 2009 10:27:40 -0700 (PDT) Message-ID: <200910241727.n9OHReEu007324@godzilla.ics.uci.edu> References: <8363a6gytm.fsf@gnu.org> <834opqgpzs.fsf@gnu.org> <83skd9f6ok.fsf@gnu.org> <83ljj1exq6.fsf@gnu.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1256405486 29970 80.91.229.12 (24 Oct 2009 17:31:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 24 Oct 2009 17:31:26 +0000 (UTC) Cc: Andreas Schwab , emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Oct 24 19:31:19 2009 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.50) id 1N1kST-0003gY-Hq for ged-emacs-devel@m.gmane.org; Sat, 24 Oct 2009 19:31:17 +0200 Original-Received: from localhost ([127.0.0.1]:38058 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N1kST-0001iS-1E for ged-emacs-devel@m.gmane.org; Sat, 24 Oct 2009 13:31:17 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1N1kSO-0001hw-K4 for emacs-devel@gnu.org; Sat, 24 Oct 2009 13:31:12 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1N1kSK-0001gQ-Up for emacs-devel@gnu.org; Sat, 24 Oct 2009 13:31:12 -0400 Original-Received: from [199.232.76.173] (port=58310 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N1kSK-0001gK-Nz for emacs-devel@gnu.org; Sat, 24 Oct 2009 13:31:08 -0400 Original-Received: from paul-mcgann-v0.ics.uci.edu ([128.195.1.147]:57262) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1N1kSI-0006Kf-30; Sat, 24 Oct 2009 13:31:06 -0400 Original-Received: from godzilla.ics.uci.edu (godzilla.ics.uci.edu [128.195.10.101]) by paul-mcgann-v0.ics.uci.edu (8.13.8/8.13.8) with ESMTP id n9OHRfDO008278; Sat, 24 Oct 2009 10:27:41 -0700 Original-Received: (from dann@localhost) by godzilla.ics.uci.edu (8.13.8+Sun/8.13.6/Submit) id n9OHReEu007324; Sat, 24 Oct 2009 10:27:40 -0700 (PDT) In-Reply-To: <83ljj1exq6.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 24 Oct 2009 15:18:57 +0200") Original-Lines: 45 X-ICS-MailScanner-Information: Please send mail to helpdesk@ics.uci.edu or more information X-ICS-MailScanner-ID: n9OHRfDO008278 X-ICS-MailScanner: Found to be clean X-ICS-MailScanner-SpamCheck: not spam, SpamAssassin (not cached, score=-1.44, required 5, autolearn=disabled, ALL_TRUSTED -1.44) X-ICS-MailScanner-From: dann@godzilla.ics.uci.edu X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) 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:116368 Archived-At: Eli Zaretskii writes: > > From: Andreas Schwab > > Cc: emacs-devel@gnu.org > > Date: Sat, 24 Oct 2009 12:37:19 +0200 > > > > Eli Zaretskii writes: > > > > > For the record, the extra use of purecopy caused the pure_bytes_used > > > value to go up by 52KB on 32-bit Windows, and by 92KB on 64-bit > > > GNU/Linux. So it looks like the ratio is actually closer to 9/5 than > > > to either the old 10/6 or the new 11/7. Or maybe I'm missing > > > something. > > > > It all depends on the ratio of string data vs. lisp object pure storage. > > I made some measurements. The ratio of 11/7 seems to work pretty > well, but there are two additional problems: > > . The default value of SYSTEM_PURESIZE_EXTRA is zero, and is not > increased for GUI builds. This causes a --without-x build to waste > some 100KB. If we want to handle this, the basic constant in > BASE_PURESIZE can be as low as 1290000 and SYSTEM_PURESIZE_EXTRA > should have its default at 140000 for GUI builds, zero otherwise. > > . The amount of pure storage used by load-history depends on the > length of the filename of the directory where Emacs is dumped. In > my case, I have 32 characters before the "emacs/lisp/" part, so I'm > guessing that's the main reason the value of 1430000 was too small > for me. We have 2 more problems with load-history: although in loadup.el is purecopied, something still seems to maintain references to the file name strings, they are still present as non-pure strings in the dumped image both as absolute file names and as the arguments passed to load (see the simple patch I posted yesterday to dump strings). So we are still wasting memory on those. It would be great if load-history would be constructed in pure memory from the beginning when dumping (instead of purecopying later). Maybe someone that understands that code could do that... > We could decide that we don't care too much about the --without-x IMHO --without-x is completely unimportant.