From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: How to make agenda generation faster Date: Fri, 19 Oct 2018 00:48:02 +0200 Message-ID: <87r2gm6fdp.fsf@nicolasgoaziou.fr> References: <87h8hy1ho5.fsf@mbork.pl> <87o9c34ocl.fsf@alphapapa.net> <877eirdrqt.fsf@nicolasgoaziou.fr> <87ftx5fx3n.fsf@alphapapa.net> <87pnw8engh.fsf@nicolasgoaziou.fr> <87h8hkqtfb.fsf@alphapapa.net> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44007) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gDH5Q-0003qy-Tk for emacs-orgmode@gnu.org; Thu, 18 Oct 2018 18:48:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gDH5K-0007YI-3K for emacs-orgmode@gnu.org; Thu, 18 Oct 2018 18:48:10 -0400 Received: from relay1-d.mail.gandi.net ([217.70.183.193]:36355) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gDH5J-0007We-JZ for emacs-orgmode@gnu.org; Thu, 18 Oct 2018 18:48:05 -0400 In-Reply-To: <87h8hkqtfb.fsf@alphapapa.net> (Adam Porter's message of "Wed, 17 Oct 2018 14:12:08 -0500") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Adam Porter Cc: emacs-orgmode@gnu.org Hello, Adam Porter writes: > Org is welcome to take any of the org-ql or org-ql-agenda code you think > would be useful. Thank you. > However, before it could be suitable as a possible replacement, it will > likely require more optimization. Some queries, especially more complex > ones, are slower than the equivalent searches and agendas in the current > Org Agenda code. This is because of the way the queries run predicates > on each heading. Despite the current Org Agenda code's complexity, it > is well optimized and hard to beat. Are you saying that queries are turned into regexp searches within Org files? If so, I don't think they should. Queries should only operate on the output of the data extraction, possibly a list of defstructs. I.e., you first extract all meaningful data from the document (during idle time, with cache, or whatever optimization would be chosen), store it in an appropriate format, then query it. WDYT? Regards, -- Nicolas Goaziou