From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Antipov Newsgroups: gmane.emacs.devel Subject: Re: immediate strings #2 Date: Tue, 29 Nov 2011 09:29:51 +0400 Message-ID: <4ED46DCF.3010107@yandex.ru> References: <4ED35057.8010103@yandex.ru> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1322544582 28944 80.91.229.12 (29 Nov 2011 05:29:42 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 29 Nov 2011 05:29:42 +0000 (UTC) Cc: Stefan Monnier To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Nov 29 06:29:38 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RVGG9-0007Th-V9 for ged-emacs-devel@m.gmane.org; Tue, 29 Nov 2011 06:29:38 +0100 Original-Received: from localhost ([::1]:50177 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RVGG9-0001ME-Ab for ged-emacs-devel@m.gmane.org; Tue, 29 Nov 2011 00:29:37 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:38213) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RVGG6-0001M7-BX for emacs-devel@gnu.org; Tue, 29 Nov 2011 00:29:35 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RVGG5-00009C-C6 for emacs-devel@gnu.org; Tue, 29 Nov 2011 00:29:34 -0500 Original-Received: from mail-bw0-f41.google.com ([209.85.214.41]:43716) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RVGG5-00008x-66 for emacs-devel@gnu.org; Tue, 29 Nov 2011 00:29:33 -0500 Original-Received: by bke17 with SMTP id 17so10824106bke.0 for ; Mon, 28 Nov 2011 21:29:32 -0800 (PST) Original-Received: by 10.204.34.148 with SMTP id l20mr42653161bkd.55.1322544571861; Mon, 28 Nov 2011 21:29:31 -0800 (PST) Original-Received: from [192.168.0.171] ([78.153.153.8]) by mx.google.com with ESMTPS id f14sm34565743bkv.3.2011.11.28.21.29.30 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 28 Nov 2011 21:29:31 -0800 (PST) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:8.0) Gecko/20111115 Thunderbird/8.0 In-Reply-To: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.214.41 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:146336 Archived-At: On 11/28/2011 09:33 PM, Stefan Monnier wrote: > It's great to see that it can speed up compilation, tho (although > the 1.3% difference could just as well be due to noise). This noise is quite repetitive, and it should be even more repetitive and visible after fitting Lisp_String within 32 (or 16, on 32-bit) bytes. > You might want to check what proportion of those strings have a > NULL `intervals' field. I believe it's typical to have 20-50 intervals for 10000 strings, so it's worth trying to store string intervals separately (in a kind of hash table, for example). On the other side, there is a reason to have extra sizeof(void *) bytes at the beginning of Lisp_String - to use by NEXT_FREE_LISP_STRING. Dmitry