emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* [RFC PATCH 0/2] Make org-babel-tangle usable in after-save-hook on large org buffers
@ 2022-02-07 12:31 Ihor Radchenko
  2022-02-07 12:31 ` [RFC PATCH 1/2] org-babel-tangle-single-block: Do not create comment link when not requested Ihor Radchenko
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Ihor Radchenko @ 2022-02-07 12:31 UTC (permalink / raw)
  To: emacs-orgmode; +Cc: Ihor Radchenko

I would like to send an experimental patch improving performance of
org-babel-tangle.  The patch contains two major changes:
1. org-babel-tangle-single-block will not try to parse LINK to src
   block when :comments is set to "no" and simple return nil in
   relevant slot of the parsed src block structure.
2. org-babel-expand-noweb-references cache will be saved between the
   function calls (reset on buffer edits)

Because I am not very familiar with org-babel internals, I would like
more knowledgeable people to review the changes and let me know if I
overlooked some unexpected side-effects.

Also, testing tangle performance on real Org files with many code
blocks would be appreciated. On my side, the tangling time has been
reduced from >6 sec down to 0.1-0.2 sec (with this patch and
org-element-cache combined).

Best,
Ihor

Ihor Radchenko (2):
  org-babel-tangle-single-block: Do not create comment link when not
    requested
  org-babel-expand-noweb-references: Cache block info

 lisp/ob-core.el   | 225 ++++++++++++++++++++++++++--------------------
 lisp/ob-tangle.el |  24 ++---
 2 files changed, 141 insertions(+), 108 deletions(-)

-- 
2.34.1



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-07-31  6:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-07 12:31 [RFC PATCH 0/2] Make org-babel-tangle usable in after-save-hook on large org buffers Ihor Radchenko
2022-02-07 12:31 ` [RFC PATCH 1/2] org-babel-tangle-single-block: Do not create comment link when not requested Ihor Radchenko
2022-02-07 12:31 ` [RFC PATCH 2/2] org-babel-expand-noweb-references: Cache block info Ihor Radchenko
2022-07-31  6:43 ` [RFC PATCH 0/2] Make org-babel-tangle usable in after-save-hook on large org buffers Ihor Radchenko

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).