From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?UTF-8?B?QW5kcmVhcyBSw7ZobGVy?= Newsgroups: gmane.emacs.devel Subject: Re: web-mode.el and speed Date: Wed, 09 Oct 2013 13:04:59 +0200 Message-ID: <5255385B.7030207@online.de> References: <8338oc6e4y.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1381316573 10902 80.91.229.3 (9 Oct 2013 11:02:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 9 Oct 2013 11:02:53 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Oct 09 13:02:56 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 1VTrXb-0006cg-Kp for ged-emacs-devel@m.gmane.org; Wed, 09 Oct 2013 13:02:55 +0200 Original-Received: from localhost ([::1]:41167 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VTrXa-0006sC-Tx for ged-emacs-devel@m.gmane.org; Wed, 09 Oct 2013 07:02:54 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36859) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VTrXT-0006rv-0K for emacs-devel@gnu.org; Wed, 09 Oct 2013 07:02:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VTrXM-0001dD-1N for emacs-devel@gnu.org; Wed, 09 Oct 2013 07:02:46 -0400 Original-Received: from moutng.kundenserver.de ([212.227.126.187]:60548) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VTrXL-0001cs-Mg for emacs-devel@gnu.org; Wed, 09 Oct 2013 07:02:39 -0400 Original-Received: from purzel.sitgens (brln-4db91913.pool.mediaWays.net [77.185.25.19]) by mrelayeu.kundenserver.de (node=mrbap3) with ESMTP (Nemesis) id 0LxOmo-1Vslt910bC-016xd1; Wed, 09 Oct 2013 13:02:37 +0200 User-Agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.0 In-Reply-To: X-Provags-ID: V02:K0:5rUqD6MaEKxd2/eKsVP4052vUvFeHguctaRbCSB09O7 t+v7CMTTpb40vkBxwXXHazsF56thlqM306+ieSR7modo+ZypcM mDDOSIQp1KZXtypXOyhMq3IN+qJG3t7VJIBk82X231MhAXqSp+ JpvW09Ew87cJfyJoMghTKjupvI4qjOyXEdPAO2Am5WlyQKQWiQ XVOfmPqLUr9dSNLhSDC+9HpDH4SF2OikVxhejTYYU0G16zXuJQ 6RFWvh4PrytR/60O8u+se+4JF7TdyXavQ1aWp9+u2sNZOnVFcd oh1IU5gcKi9nz9hFO7sswv82G/Vy0ebmJqNyXapX7Lwpf1sIoI pMhdnFbfhoDOYyq+hoLY= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 212.227.126.187 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:164034 Archived-At: Am 07.10.2013 22:21, schrieb Bois Francois-Xavier: > I think that a function that would not rely on regexp could improve > drastically the performance. > For seconds are needed to load the html5-spec page. And most of the time is > spent identifying tags. So any micro optimization can have a huge impact. > > (I have previously won 20% in perfomance when I modified the tag attributes > parser function to use chars instead of strings. I would have never thought > that the gain would be so large) > > > On Mon, Oct 7, 2013 at 10:05 PM, Eli Zaretskii wrote: > >>> From: Bois Francois-Xavier >>> Date: Mon, 7 Oct 2013 21:29:42 +0200 >>> >>> I think that using a search-chars-forward (native) function could improve >>> the performance >>> (search-chars-foward '(?\< ?\>)) >> >> What's wrong with skip-chars-forward? >> > As it was said: skip-chars-forward there is still the string/comment issue, where it probably shouldn't match (while (and (< 0 (abs (skip-chars-forward CHARS)))(nth 8 (syntax-ppss))))