From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id n45UErTd22MixwAAbAwnHQ (envelope-from ) for ; Thu, 02 Feb 2023 16:58:44 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id xc5mEbTd22PuWgAA9RJhRA (envelope-from ) for ; Thu, 02 Feb 2023 16:58:44 +0100 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 C275F1239E for ; Thu, 2 Feb 2023 16:58:43 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pNbyH-0003EO-Tk; Thu, 02 Feb 2023 10:57:57 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pNbyG-0003Dn-1a for emacs-orgmode@gnu.org; Thu, 02 Feb 2023 10:57:56 -0500 Received: from mail-wm1-x32b.google.com ([2a00:1450:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pNby8-0000NR-Iy for emacs-orgmode@gnu.org; Thu, 02 Feb 2023 10:57:55 -0500 Received: by mail-wm1-x32b.google.com with SMTP id f47-20020a05600c492f00b003dc584a7b7eso4054312wmp.3 for ; Thu, 02 Feb 2023 07:57:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=/yBEputSS/nyJ0HRwbm876qlaUkraL9ecRWCgBp93UU=; b=Mr0qY3n3+ajtkux0s3do+MRaUZlYAvU6v8xsOGsJd5GlvQhjqY1mXdpNxfaRHa+e03 w+84Pm4eFD5TxmSgLBFr2CvIfG8iIcRRpVJ+o82cugPsulqoUNHl8cS8dfqjJF3f/NJg NDDFKM1EYjqVbap1bjzJKfHLu48Tdvbm+b4Y6HVcrliN147pboFXO+a/oZUGOZLNAhQt sdz5ratn0EdreAWoE/JcRlm/9e8m5znQuidAjyCKV71Q9UEWmZ6GJDFpSSzsd/S2dB+x /1Dicw9p+Zn5Dd0yVCgFUc+cmMLkGJmWP754E2oSo7apKvnk6VvhCuMJX61D2WXHEhV7 chpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=/yBEputSS/nyJ0HRwbm876qlaUkraL9ecRWCgBp93UU=; b=PJYwR8qKjVRMuG+BPD5gKukDJBpWeXIfiEjpexhwVftFq6994nc9c000ZiGHvbb2c4 YCgiMZDhPmAYqbHlgfzyXuryDY1jAiFridiKtAVmjQPztsnJpruLAPa5CfhK0vhbNs7F IfwfMTvo35HrkcfgL9pgBQM3pNtc8E8+EuvnGxnGIKDWGENqaDTJpLFLZ8ZJmzgyYQmM 1bqFSAqgKl3Rupaohxh8cT65cJScMjzQrJibAts2nGWXyo3z1YHB/NpT83GVWf2FpSxC s29xa+xAVNuBruwu2if2zHhFDvNBdyuj5KhNRhpnjc06aHdAbCI1oWLwNU8QicA/I/sQ 95Qw== X-Gm-Message-State: AO0yUKX6oXizaai8nhvYByoPYce/b2OXQYlXnxmQh4UhgsjgHci1+TmT AeVbMwqwstUBtt09qXvYnnlQTfTeldbnOi+1m/g= X-Google-Smtp-Source: AK7set+e9ABrfE0EN0mLeiKNIMRI6XFk8IHBlZ115TtJFZho2UTi5Kphg7IjGMp0INZcXOIsqfA5HjVviEPH1Byxk4s= X-Received: by 2002:a05:600c:1912:b0:3d7:fa4a:6827 with SMTP id j18-20020a05600c191200b003d7fa4a6827mr183359wmq.188.1675353465937; Thu, 02 Feb 2023 07:57:45 -0800 (PST) MIME-Version: 1.0 References: <87bkmdjurf.fsf@localhost> In-Reply-To: <87bkmdjurf.fsf@localhost> From: Tijs Mallaerts Date: Thu, 2 Feb 2023 16:57:34 +0100 Message-ID: Subject: Re: org-clock-sum-today performance To: Ihor Radchenko Cc: emacs-orgmode@gnu.org Content-Type: multipart/alternative; boundary="00000000000035e1ea05f3b9a04a" Received-SPF: pass client-ip=2a00:1450:4864:20::32b; envelope-from=tijs.mallaerts@gmail.com; helo=mail-wm1-x32b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, T_SPF_HELO_TEMPERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Seal: i=1; s=key1; d=yhetil.org; t=1675353524; a=rsa-sha256; cv=none; b=Em738Akeky8pdKaTpS5fcwnd0b6VUtx8eOtl4nWKVueUoCISvQapWF6Ymk5wGMAh0pZw6+ /tiLlw13r5JWctxI97thXnhHb8Ffha7au40ADYRYJqowL9co7itEVHyZcduEPtevUdoZo1 lj/u1LQ6Y6VcbUAXVDlcybfORQg0zNuu8Uiuq5jNpW+0Lh7rPjTLukNJHkwgXZuPXrflNG rh3hzZrPlD+tr75jU275/XDoQDWwdgjegl21RyWk4//zXtWJEHStLk9yg6CjwFt0KKtacc a8cgImMsLqgCOIfYn50ltJtr1rLgTUphj3YgDOf5ZZQbf2tX4mWz0MUr4Wp43A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=Mr0qY3n3; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1675353524; 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:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=/yBEputSS/nyJ0HRwbm876qlaUkraL9ecRWCgBp93UU=; b=VwUb9iQyLVvLVp5H7HhD1/ug/BHnozwaStYNA1yEH5vsL1Qsdph+G05V+O/7atdugIUosl yfYVN7R9ReNh7QIZuq40k6AURd2Q+1nQ2+/pt6g6Gd6ShTKNY19PG9yZHDvd6rpkPHIn/T 4VPIUDWt6nRGthzwZbnJmWxPktcp10TyBJRz/W129BVYHmjrU8Tw4d+85EwiTCZX4PwsEh TKYXsH0jYDCpMYKUSVDn4qX45LVE/1cqh7ZgqpCZe1eurAFZCb/FD/AlKjMTtBZE2xOJJg fmYGx9AuhJKHp3HxDxllNLhxQv7PL3ESJ8qu+wZHCCr7v7dlxdjYBPvhNJkvkA== X-Migadu-Scanner: scn1.migadu.com X-Migadu-Spam-Score: -4.77 X-Spam-Score: -4.77 X-Migadu-Queue-Id: C275F1239E Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=Mr0qY3n3; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com X-TUID: F7PPKjHcUCjD --00000000000035e1ea05f3b9a04a Content-Type: text/plain; charset="UTF-8" Hello Ihor, This is the profiler report: [profiler-profile "28.1" cpu #s(hash-table size 65 test equal rehash-size 1.5 rehash-threshold 0.8125 data ([nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil] 11 ["#" auto-revert-buffers--buffer-list-filter apply auto-revert-buffers apply timer-event-handler nil nil nil nil nil nil nil nil nil nil] 12 ["#" apply timer-event-handler nil nil nil nil nil nil nil nil nil nil nil nil nil] 7 ["#" execute-extended-command--shorter "#" apply timer-event-handler nil nil nil nil nil nil nil nil nil nil nil] 19 ["#" completion--some completion--nth-completion completion-try-completion execute-extended-command--shorter "#" apply timer-event-handler nil nil nil nil nil nil nil nil] 20 [completion-pcm--find-all-completions completion-pcm-try-completion "#" completion--some completion--nth-completion completion-try-completion execute-extended-command--shorter "#" apply timer-event-handler nil nil nil nil nil nil] 36 [completion-pcm--merge-try completion-pcm-try-completion "#" completion--some completion--nth-completion completion-try-completion execute-extended-command--shorter "#" apply timer-event-handler nil nil nil nil nil nil] 4 ["#" "#" apply timer-event-handler nil nil nil nil nil nil nil nil nil nil nil nil] 1 [read--expression byte-code command-execute nil nil nil nil nil nil nil nil nil nil nil nil nil] 4 [byte-code command-execute nil nil nil nil nil nil nil nil nil nil nil nil nil nil] 39 ["#" apply timer-event-handler read--expression byte-code command-execute nil nil nil nil nil nil nil nil nil nil] 1 [auto-revert-handler auto-revert-buffer "#" auto-revert-buffers--buffer-list-filter apply auto-revert-buffers apply timer-event-handler read--expression byte-code command-execute nil nil nil nil nil] 7 [internal-timer-start-idle read--expression byte-code command-execute nil nil nil nil nil nil nil nil nil nil nil nil] 3 [org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil nil nil] 55 [org-element--current-element org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil] 376 [org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil nil] 196 [org-parse-time-string org-element-timestamp-parser org-element-clock-parser org-element--current-element org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil] 92 [org-element-clock-parser org-element--current-element org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil] 246 [org-element-timestamp-parser org-element-clock-parser org-element--current-element org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil] 108 [org-get-limited-outline-regexp org-element--current-element org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil] 4 [org-element-section-parser org-element--current-element org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil] 32 [org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil nil nil nil nil] 4 [derived-mode-p org-get-limited-outline-regexp org-element--current-element org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil] 4 [org-element--cache-put org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil] 7 [org-time-string-to-seconds org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil nil nil] 8 [org-time-string-to-time org-time-string-to-seconds org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil nil] 4 [org-element-headline-parser org-element--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expression funcall-interactively command-execute nil nil nil nil nil nil nil nil] 4 ["#" "#" all-completions complete-with-action "#" all-completions ivy--reset-state ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil] 10 [complete-with-action "#" all-completions ivy--reset-state ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil nil] 20 [all-completions complete-with-action "#" all-completions ivy--reset-state ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil] 8 ["#" all-completions complete-with-action "#" all-completions ivy--reset-state ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil] 4 [read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil nil nil nil nil] 58 [ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil nil nil nil nil nil] 14 ["#" cl-delete cl-remove ivy--re-filter ivy--filter ivy--update-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil] 21 [cl--position cl-position ivy--recompute-index ivy--filter ivy--update-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil] 4 [ivy--insert-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil nil] 8 ["#" cl-remove ivy--re-filter ivy--filter ivy--update-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil] 43 [ivy--re-filter ivy--filter ivy--update-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil] 17 [cl-remove ivy--re-filter ivy--filter ivy--update-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil] 22 ["#" apply timer-event-handler read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil nil] 12 ["#" auto-revert-buffers--buffer-list-filter apply auto-revert-buffers apply timer-event-handler read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil] 3 [ad-Advice-delete-backward-char apply delete-backward-char funcall-interactively call-interactively ivy-backward-delete-char funcall-interactively command-execute read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil] 4 [delete-selection-pre-hook read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil nil nil nil] 2 [undo-auto--ensure-boundary undo-auto--boundaries undo-auto--add-boundary read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil nil] 2 [ivy--insert-prompt ivy--insert-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-command byte-code command-execute nil nil nil nil nil] 3 [funcall-interactively command-execute nil nil nil nil nil nil nil nil nil nil nil nil nil nil] 3 [funcall-interactively command-execute execute-extended-command funcall-interactively command-execute nil nil nil nil nil nil nil nil nil nil nil] 4 [Automatic\ GC] 440)) (25563 56485 293720 164000) nil] Thanks! Tijs Op wo 1 feb. 2023 om 15:59 schreef Ihor Radchenko : > Tijs Mallaerts writes: > > > After building emacs from the master branch (with Org mode version 9.6 > > release_9.6-81-g563a43) I noticed the org-clock-sum-today function takes > > much more time compared to my previous emacs build (with Org mode version > > 9.5.4 release_9.5.4-19-g4dff42) in a large org buffer. > > > > Are there any settings that could speed up the calculation? > > May you please > 1. run M-x profiler-start cpu > 2. Run org-clock-sum-today > 3. M-x profiler-report > 4. M-x profiler-report-write-profile > 5. Share the saved profile > > -- > Ihor Radchenko // yantar92, > Org mode contributor, > Learn more about Org mode at . > Support Org development at , > or support my work at > --00000000000035e1ea05f3b9a04a Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hello Ihor,

This is the prof= iler report:

[profiler-profile "28.1" cpu #s(hash-t= able size 65 test equal rehash-size 1.5 rehash-threshold 0.8125 data ([nil = nil nil nil nil nil nil nil nil nil nil nil nil nil nil nil] 11 ["#<= ;subr auto-revert-buffers>" auto-revert-buffers--buffer-list-filter= apply auto-revert-buffers apply timer-event-handler nil nil nil nil nil ni= l nil nil nil nil] 12 ["#<subr F616e6f6e796d6f75732d6c616d626461_an= onymous_lambda_9>" apply timer-event-handler nil nil nil nil nil ni= l nil nil nil nil nil nil nil] 7 ["#<compiled 0x1a044bbfab7c2ab2>= ;" execute-extended-command--shorter "#<compiled -0x20b067094a= 388be>" apply timer-event-handler nil nil nil nil nil nil nil nil n= il nil nil] 19 ["#<compiled 0x7850c1edb66e883>" completion-= -some completion--nth-completion completion-try-completion execute-extended= -command--shorter "#<compiled -0x20b067094a388be>" apply ti= mer-event-handler nil nil nil nil nil nil nil nil] 20 [completion-pcm--find= -all-completions completion-pcm-try-completion "#<compiled 0x7850c1= f5dbee883>" completion--some completion--nth-completion completion-= try-completion execute-extended-command--shorter "#<compiled -0x20b= 067094a388be>" apply timer-event-handler nil nil nil nil nil nil] 3= 6 [completion-pcm--merge-try completion-pcm-try-completion "#<compi= led 0x7850c1f5dbee883>" completion--some completion--nth-completion= completion-try-completion execute-extended-command--shorter "#<com= piled -0x20b067094a388be>" apply timer-event-handler nil nil nil ni= l nil nil] 4 ["#<compiled 0x11470000ec98926f>" "#<c= ompiled -0x20b067094a388be>" apply timer-event-handler nil nil nil = nil nil nil nil nil nil nil nil nil] 1 [read--expression byte-code command-= execute nil nil nil nil nil nil nil nil nil nil nil nil nil] 4 [byte-code c= ommand-execute nil nil nil nil nil nil nil nil nil nil nil nil nil nil] 39 = ["#<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_9>&q= uot; apply timer-event-handler read--expression byte-code command-execute n= il nil nil nil nil nil nil nil nil nil] 1 [auto-revert-handler auto-revert-= buffer "#<subr auto-revert-buffers>" auto-revert-buffers--b= uffer-list-filter apply auto-revert-buffers apply timer-event-handler read-= -expression byte-code command-execute nil nil nil nil nil] 7 [internal-time= r-start-idle read--expression byte-code command-execute nil nil nil nil nil= nil nil nil nil nil nil nil] 3 [org-element-at-point org-clock-sum org-clo= ck-sum-today eval-expression funcall-interactively command-execute nil nil = nil nil nil nil nil nil nil nil] 55 [org-element--current-element org-eleme= nt--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-ex= pression funcall-interactively command-execute nil nil nil nil nil nil nil = nil] 376 [org-element--parse-to org-element-at-point org-clock-sum org-cloc= k-sum-today eval-expression funcall-interactively command-execute nil nil n= il nil nil nil nil nil nil] 196 [org-parse-time-string org-element-timestam= p-parser org-element-clock-parser org-element--current-element org-element-= -parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-expre= ssion funcall-interactively command-execute nil nil nil nil nil] 92 [org-el= ement-clock-parser org-element--current-element org-element--parse-to org-e= lement-at-point org-clock-sum org-clock-sum-today eval-expression funcall-i= nteractively command-execute nil nil nil nil nil nil nil] 246 [org-element-= timestamp-parser org-element-clock-parser org-element--current-element org-= element--parse-to org-element-at-point org-clock-sum org-clock-sum-today ev= al-expression funcall-interactively command-execute nil nil nil nil nil nil= ] 108 [org-get-limited-outline-regexp org-element--current-element org-elem= ent--parse-to org-element-at-point org-clock-sum org-clock-sum-today eval-e= xpression funcall-interactively command-execute nil nil nil nil nil nil nil= ] 4 [org-element-section-parser org-element--current-element org-element--p= arse-to org-element-at-point org-clock-sum org-clock-sum-today eval-express= ion funcall-interactively command-execute nil nil nil nil nil nil nil] 32 [= org-clock-sum-today eval-expression funcall-interactively command-execute n= il nil nil nil nil nil nil nil nil nil nil nil] 4 [derived-mode-p org-get-l= imited-outline-regexp org-element--current-element org-element--parse-to or= g-element-at-point org-clock-sum org-clock-sum-today eval-expression funcal= l-interactively command-execute nil nil nil nil nil nil] 4 [org-element--ca= che-put org-element--parse-to org-element-at-point org-clock-sum org-clock-= sum-today eval-expression funcall-interactively command-execute nil nil nil= nil nil nil nil nil] 7 [org-time-string-to-seconds org-clock-sum org-clock= -sum-today eval-expression funcall-interactively command-execute nil nil ni= l nil nil nil nil nil nil nil] 8 [org-time-string-to-time org-time-string-t= o-seconds org-clock-sum org-clock-sum-today eval-expression funcall-interac= tively command-execute nil nil nil nil nil nil nil nil nil] 4 [org-element-= headline-parser org-element--parse-to org-element-at-point org-clock-sum or= g-clock-sum-today eval-expression funcall-interactively command-execute nil= nil nil nil nil nil nil nil] 4 ["#<compiled -0xf5c4e2a00a29a80>= " "#<compiled 0x4c7cc2751b00e55>" all-completions comp= lete-with-action "#<subr F616e6f6e796d6f75732d6c616d626461_anonymou= s_lambda_54>" all-completions ivy--reset-state ivy-read ivy-complet= ing-read read-extended-command-1 read-extended-command byte-code command-ex= ecute nil nil nil] 10 [complete-with-action "#<subr F616e6f6e796d6f= 75732d6c616d626461_anonymous_lambda_54>" all-completions ivy--reset= -state ivy-read ivy-completing-read read-extended-command-1 read-extended-c= ommand byte-code command-execute nil nil nil nil nil nil] 20 [all-completio= ns complete-with-action "#<subr F616e6f6e796d6f75732d6c616d626461_a= nonymous_lambda_54>" all-completions ivy--reset-state ivy-read ivy-= completing-read read-extended-command-1 read-extended-command byte-code com= mand-execute nil nil nil nil nil] 8 ["#<compiled 0x4c7cc2751b00e55&= gt;" all-completions complete-with-action "#<subr F616e6f6e796= d6f75732d6c616d626461_anonymous_lambda_54>" all-completions ivy--re= set-state ivy-read ivy-completing-read read-extended-command-1 read-extende= d-command byte-code command-execute nil nil nil nil] 4 [read-from-minibuffe= r ivy-read ivy-completing-read read-extended-command-1 read-extended-comman= d byte-code command-execute nil nil nil nil nil nil nil nil nil] 58 [ivy-re= ad ivy-completing-read read-extended-command-1 read-extended-command byte-c= ode command-execute nil nil nil nil nil nil nil nil nil nil] 14 ["#<= ;compiled 0x1eb9ec24af2045a5>" cl-delete cl-remove ivy--re-filter i= vy--filter ivy--update-minibuffer ivy--exhibit ivy--queue-exhibit read-from= -minibuffer ivy-read ivy-completing-read read-extended-command-1 read-exten= ded-command byte-code command-execute nil] 21 [cl--position cl-position ivy= --recompute-index ivy--filter ivy--update-minibuffer ivy--exhibit ivy--queu= e-exhibit read-from-minibuffer ivy-read ivy-completing-read read-extended-c= ommand-1 read-extended-command byte-code command-execute nil nil] 4 [ivy--i= nsert-minibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-r= ead ivy-completing-read read-extended-command-1 read-extended-command byte-= code command-execute nil nil nil nil nil nil] 8 ["#<compiled -0xabf= 49e5c423277c>" cl-remove ivy--re-filter ivy--filter ivy--update-min= ibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-c= ompleting-read read-extended-command-1 read-extended-command byte-code comm= and-execute nil nil] 43 [ivy--re-filter ivy--filter ivy--update-minibuffer = ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy-completin= g-read read-extended-command-1 read-extended-command byte-code command-exec= ute nil nil nil nil] 17 [cl-remove ivy--re-filter ivy--filter ivy--update-m= inibuffer ivy--exhibit ivy--queue-exhibit read-from-minibuffer ivy-read ivy= -completing-read read-extended-command-1 read-extended-command byte-code co= mmand-execute nil nil nil] 22 ["#<subr F616e6f6e796d6f75732d6c616d6= 26461_anonymous_lambda_9>" apply timer-event-handler read-from-mini= buffer ivy-read ivy-completing-read read-extended-command-1 read-extended-c= ommand byte-code command-execute nil nil nil nil nil nil] 12 ["#<su= br auto-revert-buffers>" auto-revert-buffers--buffer-list-filter ap= ply auto-revert-buffers apply timer-event-handler read-from-minibuffer ivy-= read ivy-completing-read read-extended-command-1 read-extended-command byte= -code command-execute nil nil nil] 3 [ad-Advice-delete-backward-char apply = delete-backward-char funcall-interactively call-interactively ivy-backward-= delete-char funcall-interactively command-execute read-from-minibuffer ivy-= read ivy-completing-read read-extended-command-1 read-extended-command byte= -code command-execute nil] 4 [delete-selection-pre-hook read-from-minibuffe= r ivy-read ivy-completing-read read-extended-command-1 read-extended-comman= d byte-code command-execute nil nil nil nil nil nil nil nil] 2 [undo-auto--= ensure-boundary undo-auto--boundaries undo-auto--add-boundary read-from-min= ibuffer ivy-read ivy-completing-read read-extended-command-1 read-extended-= command byte-code command-execute nil nil nil nil nil nil] 2 [ivy--insert-p= rompt ivy--insert-minibuffer ivy--exhibit ivy--queue-exhibit read-from-mini= buffer ivy-read ivy-completing-read read-extended-command-1 read-extended-c= ommand byte-code command-execute nil nil nil nil nil] 3 [funcall-interactiv= ely command-execute nil nil nil nil nil nil nil nil nil nil nil nil nil nil= ] 3 [funcall-interactively command-execute execute-extended-command funcall= -interactively command-execute nil nil nil nil nil nil nil nil nil nil nil]= 4 [Automatic\ GC] 440)) (25563 56485 293720 164000) nil]

Thanks!
Tijs

Op wo 1 feb. 2023 om 15:59 schreef = Ihor Radchenko <yantar92@posteo.n= et>:
Tijs= Mallaerts <tijs.mallaerts@gmail.com> writes:

> After building emacs from the master branch (with Org mode version 9.6=
> release_9.6-81-g563a43) I noticed the org-clock-sum-today function tak= es
> much more time compared to my previous emacs build (with Org mode vers= ion
> 9.5.4 release_9.5.4-19-g4dff42) in a large org buffer.
>
> Are there any settings that could speed up the calculation?

May you please
1. run M-x profiler-start <RET> cpu <RET>
2. Run org-clock-sum-today
3. M-x profiler-report
4. M-x profiler-report-write-profile
5. Share the saved profile

--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,=
or support my work at <https://liberapay.com/yantar92>
--00000000000035e1ea05f3b9a04a--