From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id IL6oOmIcR2EgDQEAgWs5BA (envelope-from ) for ; Sun, 19 Sep 2021 13:17:54 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id yBjkNWIcR2GzXAAA1q6Kng (envelope-from ) for ; Sun, 19 Sep 2021 11:17:54 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 480D5F90E for ; Sun, 19 Sep 2021 13:17:54 +0200 (CEST) Received: from localhost ([::1]:35496 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mRupU-0007U8-Vv for larch@yhetil.org; Sun, 19 Sep 2021 07:17:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:34162) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mRuou-0007Tq-8W for emacs-orgmode@gnu.org; Sun, 19 Sep 2021 07:17:16 -0400 Received: from mail-pl1-x62d.google.com ([2607:f8b0:4864:20::62d]:35359) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mRuos-0006iz-Iv for emacs-orgmode@gnu.org; Sun, 19 Sep 2021 07:17:15 -0400 Received: by mail-pl1-x62d.google.com with SMTP id bb10so9192407plb.2 for ; Sun, 19 Sep 2021 04:17:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version:content-transfer-encoding; bh=7q+oPbJWNSKHS2uNEjdLdHiSKDXFcHF3ZEXmKdjb30E=; b=bYh9BEqmNOMLmQ0K0DZfKAoOVzJ+ySi7duYkaaK0gObKBH9uSGRoqEqOlNmOpq4lH6 wcw4yUsSb9Ma3Ih+bwrB0ctkS8npM78ASYNsHpiEtesxLoE4zxzmq9WA6xkw6uaGWmjp EjDvpPaZAIqq9DxEXisstxUvyU9msa1QQOH34y80xT6l5Zb1gStyFA45ugfDLSIe2AhM cWhBTj+V6qFRK6lINT82ZR0bhbx51sK79mx1uZ/Ty1RxdQpDeVdSlfMC60pid2i3V31A vhARvBG8aB9rtFHTNxaB8x/mlCN5lJ7SExG1dfua1iD9WDcUpguL+qkw1fD6dwzc9+MF aUtA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:in-reply-to:references:date :message-id:mime-version:content-transfer-encoding; bh=7q+oPbJWNSKHS2uNEjdLdHiSKDXFcHF3ZEXmKdjb30E=; b=HkWVraP1pRj5HcplFHZreCvImk9HMAtR3mjPEbxE8w3+51jPmw4+MmdgzhYzHVCfgC t43uv21AyuqJs0B88KtThxI0KS9RjPWW5jeE/y7mkRSpAL7hC58P2UaZOUyqMEKjl7V9 TDorZJ9kI4QKnmZK3z+FT7RGk7FFaEf2CkPCdQUulg4r02rFf5jFyfQpjnkgZIMqtAZu apboa1i/H797o/NkNBtIFDb/pOq/LGaCwdy+3UL90FSwnbtziXr2FL5AWqOqfqxwZjIJ x/8lg5bkyevry2LLw8cncV2Q7xUxnVlOBTw0UvnZNXcsO9GFdw7UTNhzBkrR5YQSJwUV GVEA== X-Gm-Message-State: AOAM533QTRK6jdpcRGSonmhqCZ2siJMj3+vL7xMAJqz9dWpNvO2ahsXR y1qGGaO9W8Wn6dWKVPG8bcY= X-Google-Smtp-Source: ABdhPJwQ4UBY4FUrnADN2qjX/x6pkLdymssCCZvMfUV1p6IwuQzp9iyMAwRscWSrq9VVY+NsjhL9cg== X-Received: by 2002:a17:90a:1904:: with SMTP id 4mr8242646pjg.191.1632050232819; Sun, 19 Sep 2021 04:17:12 -0700 (PDT) Received: from localhost ([160.202.160.104]) by smtp.gmail.com with ESMTPSA id t3sm12235434pgo.51.2021.09.19.04.17.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 19 Sep 2021 04:17:12 -0700 (PDT) From: Ihor Radchenko To: Timothy Subject: Re: [feature proposal] Headline caching via org-element-cache = up to 2.5x performance boost In-Reply-To: <87a6k8esrl.fsf@gmail.com> References: <87bl4p6n0m.fsf@localhost> <87a6k8esrl.fsf@gmail.com> Date: Sun, 19 Sep 2021 19:18:27 +0800 Message-ID: <878rzs7r0c.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::62d; envelope-from=yantar92@gmail.com; helo=mail-pl1-x62d.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: emacs-orgmode@gnu.org Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1632050274; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=7q+oPbJWNSKHS2uNEjdLdHiSKDXFcHF3ZEXmKdjb30E=; b=Qz4jNxGpUQT5AMaCpNGOOaRsJx24BEoC9MZ0DHjHQswSmlqLqP+y47UW7PZKx64HF7VKRJ g6mga8o7yTDossSgij8+lMCzF47Rp+4Tc5692A0Ih7vQsH+j8+KUqEpcaVFUnr2hWL1yVp lxwGkwm7fII4md85A77ZiEKIVkYd+q01yfX0S3saSLg0vk5PA6TLsLOVcGPsHQUh7pFoLL gvH1lFU+orN1JYg2QjB4e3Y1u8O/U7AzL9LVJ8LspJwVyV0xJas75RhiVfXJSu2Brj1D+k GWDCUb/HvwZ4XL6l6JkT/6beSrATiP9MhKuatmY70N60LXc6ozrxYxb7s2TcKQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1632050274; a=rsa-sha256; cv=none; b=MjzAO/DVZnRUi+kLTJ19ZfNdcQxQJP6OrI295Z//fTN2SDRDJ7oae5FYJYqSJJP2D74RBD CgO9JQheS9jq0H8bCjJSO8UwQSiSIAB5G1jkDNweqRhrVvpimVrmrWlUOd7IAJDxJlekch LgJoBEqKuEB8iNwLll3wWXsrEsSIdHNiO2qQNx8FgWtq7IpfYWeXptIEAnsoOo6bbKLaDR 5p5tEU3zlI9ca2KRvIteEzA2NRdgQjEVai9bFkALBwW5Yy7i1Q+wgMJDc6FsJjqcI9zCvx 6o5T0ebm1crDM9OJ4dPdz1b+4vuXAEG1ndWb+mVHJqWluLmA41AF95QHA2G7iQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=bYh9BEqm; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -2.59 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=bYh9BEqm; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 480D5F90E X-Spam-Score: -2.59 X-Migadu-Scanner: scn0.migadu.com X-TUID: LBZTHQXYkW6F Timothy writes: > p.s. I=E2=80=99m marking this as a patch on the tracker, since it is one = :P This is not a real patch. I just separated changes I made in org-element.el. Other changes include cache support across Org code and tests. In total it looks roughly like: 12 files changed, 2584 insertions(+), 1140 deletions(-) However, I did not directly base the patch on master, but rather on (hopefully-to-be-merged-at-some-point org-fold branch :'/). I am not too interested in porting the patch onto master. At least not until I get feedback on parser and API changes. > As someone who tangles massive literate config this sounds like it could = make > quite a noticeable improvement. To test this, do I need to do anything mo= re than > just apply your patch? Applying the patch will not work. As I said, it is mostly for reference to show the changes to parser and API. If you want to test it, you can use https://github.com/yantar92/org. That repo includes the org-fold branch and the new cache implementation. Best, Ihor