From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Bastien Newsgroups: gmane.emacs.devel Subject: Re: Compiled regexp? Date: Thu, 31 Jan 2013 15:11:44 +0100 Message-ID: <871ud1h273.fsf@bzg.ath.cx> References: <87lib9ii8a.fsf@bzg.ath.cx> <87vcad5ttp@ch.ristopher.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1359641516 13190 80.91.229.3 (31 Jan 2013 14:11:56 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 31 Jan 2013 14:11:56 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Jan 31 15:12:16 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 1U0usB-0000nm-Ux for ged-emacs-devel@m.gmane.org; Thu, 31 Jan 2013 15:12:16 +0100 Original-Received: from localhost ([::1]:45293 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U0urt-0007Os-P7 for ged-emacs-devel@m.gmane.org; Thu, 31 Jan 2013 09:11:57 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:34710) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U0urq-0007Oa-9F for emacs-devel@gnu.org; Thu, 31 Jan 2013 09:11:55 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U0urk-00028w-Vd for emacs-devel@gnu.org; Thu, 31 Jan 2013 09:11:54 -0500 Original-Received: from mail-we0-x22d.google.com ([2a00:1450:400c:c03::22d]:48618) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U0urk-00028j-Or for emacs-devel@gnu.org; Thu, 31 Jan 2013 09:11:48 -0500 Original-Received: by mail-we0-f173.google.com with SMTP id r5so2055690wey.4 for ; Thu, 31 Jan 2013 06:11:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:from:to:subject:in-reply-to:references:user-agent :date:message-id:mime-version:content-type; bh=iisQJfAqL8EnaitBOEi+xo6aLAw1KeF5FIqtnMtX74U=; b=C79GRh7MtS2b7LGLzdf9elCBMTSspsWPxET67r3TUiv5Cd4YgRMjL2TS4W4ztiXV2l 2Mcr9McUJpY3ZYxKDSE4OnR4RUSK1HdGmGpkzzqVYzUWSOi+MK44HRybBlAePWDViun5 n//1q55junnEzd87rDq5kkkmZ9vSREGYsVoFXs7rwB2FhnTSCPQBE7uc9kSIfWahcFi9 0z7gTAkeqLoSgnAQg7gwuzaaAuHh2UPIGseh/hqle+zU5lj5cMgKHUegX4tM+1WnlHQ9 Uv/ni1eZDGUWnf3yKCmLTRW40drXWGqPeOhTnjje1BPn71lCvCUKF8Qt9AkaiDaZ6rw4 dqaw== X-Received: by 10.180.85.103 with SMTP id g7mr15345555wiz.29.1359641507833; Thu, 31 Jan 2013 06:11:47 -0800 (PST) Original-Received: from bzg.localdomain (mar75-2-81-56-68-112.fbx.proxad.net. [81.56.68.112]) by mx.google.com with ESMTPS id fa15sm15305637wid.7.2013.01.31.06.11.45 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 31 Jan 2013 06:11:46 -0800 (PST) Original-Received: by bzg.localdomain (Postfix, from userid 1000) id F272B1C20D61; Thu, 31 Jan 2013 15:11:44 +0100 (CET) In-Reply-To: <87vcad5ttp@ch.ristopher.com> (Christopher Schmidt's message of "Thu, 31 Jan 2013 14:08:02 +0000 (GMT)") User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c03::22d 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:156733 Archived-At: Christopher Schmidt writes: > We discussed how cached compiled regexps are looked up, i.e. per object > or per content. If the former were true, (re-search-forward (concat "^" > my-partial-pattern) ...) would result in the regular expression being > compiled each and every time because concat returns a new lisp object. > That's slow. Yes, that's what I tried to say, thanks for clarifying it. -- Bastien