From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Loading souce Elisp faster Date: Sun, 24 Feb 2013 20:40:37 -0500 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1361756441 29447 80.91.229.3 (25 Feb 2013 01:40:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 25 Feb 2013 01:40:41 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Feb 25 02:41:05 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1U9n3v-00035L-DN for ged-emacs-devel@m.gmane.org; Mon, 25 Feb 2013 02:41:03 +0100 Original-Received: from localhost ([::1]:49417 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9n3a-00059k-PC for ged-emacs-devel@m.gmane.org; Sun, 24 Feb 2013 20:40:42 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:52412) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9n3Y-00059J-JB for emacs-devel@gnu.org; Sun, 24 Feb 2013 20:40:41 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U9n3X-0006gI-KG for emacs-devel@gnu.org; Sun, 24 Feb 2013 20:40:40 -0500 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.182]:50432) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9n3X-0006gC-Fg for emacs-devel@gnu.org; Sun, 24 Feb 2013 20:40:39 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AsoGABK/CFHO+KLv/2dsb2JhbABEtyKHbBdzgntyJhgNiEigC6EijWGDKQOIYZwZgV6DFQ X-IPAS-Result: AsoGABK/CFHO+KLv/2dsb2JhbABEtyKHbBdzgntyJhgNiEigC6EijWGDKQOIYZwZgV6DFQ X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="2228962" Original-Received: from 206-248-162-239.dsl.teksavvy.com (HELO fmsmemgm.homelinux.net) ([206.248.162.239]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 24 Feb 2013 20:40:37 -0500 Original-Received: by fmsmemgm.homelinux.net (Postfix, from userid 20848) id 36A1AAE2C6; Sun, 24 Feb 2013 20:40:37 -0500 (EST) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.182 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:157299 Archived-At: It used to be the case that compiling one's .emacs was silly because it provided no measurable speed difference. But nowadays this is not true any more: loading a source Elisp file is significantly slower because it goes through load-with-code-conversion. For source files in utf-8 encoding this does not need to be the case: we could load them without going through load-with-code-conversion. And given that utf-8 should be the standard encoding for Elisp files (if not quite now, surely in some not too distant future), this is an important case. So basically, all we need to do is to be able to easily recognize "Elisp source in utf-8 encoding". One way to do that would be to use a BOM-like marker, e.g. start utf-8 Elisp files with "\ufeff" either at the very beginning of the file or right after a semi-colon (for better backward compatibility). Stefan