From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id 8DRgJUvOjGNQLQEAbAwnHQ (envelope-from ) for ; Sun, 04 Dec 2022 17:43:55 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id EJ+LJEvOjGMtggAAG6o9tA (envelope-from ) for ; Sun, 04 Dec 2022 17:43:55 +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 42B48459A7 for ; Sun, 4 Dec 2022 17:43:55 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p1s4u-0004mZ-8f; Sun, 04 Dec 2022 11:42:56 -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 1p1nre-0001Xk-Lq for emacs-orgmode@gnu.org; Sun, 04 Dec 2022 07:12:58 -0500 Received: from mail-yw1-x1141.google.com ([2607:f8b0:4864:20::1141]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p1nrd-0003uM-0H for emacs-orgmode@gnu.org; Sun, 04 Dec 2022 07:12:58 -0500 Received: by mail-yw1-x1141.google.com with SMTP id 00721157ae682-3e78d07ab4fso22309187b3.9 for ; Sun, 04 Dec 2022 04:12:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=RUEVeS4hNSC4ywOTMa5Gqd11RlCgMnZB6L0pJPD7LOk=; b=m286Wnllh7Dg60Sh3LLV+mi16/gTv4NWnz0ozcNme7/inkkMaxWiWyt12BjA4mvZ/g i7jGW50wceheDk0YV+QfVudw4/hvg5MPmBOI07pbE2mks+36mYNM9df4im+o6ZFJoPf2 8b2FBZAWHw/FasNhJ4NJiMfhyWzpwWettFOZMt+sM+l1nHm3uFhS7ZHhcda/8/qb4isU jLsn0KdfOt1WITgEWE1+ldhKUVPhfjm3UqHbkNWpGldsJmYupbhE0GDnJPaKnNT+e6rP /t2Uw8M3Fe7HZaEJ2Qkny2etJJIS0mRHBlswKvhTm6jMYYw4u12+pv+kgvPgbbK4xGsG Ea3g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=RUEVeS4hNSC4ywOTMa5Gqd11RlCgMnZB6L0pJPD7LOk=; b=C5qHNSyAx0uPy0OKLpK1ufjD38xG/Twu711EPr5c8TaFCv7Mx5hYMirf+0WR7U7HlO 6lrNkbEgviuDcig4Ut5fj88Cs1JIKGDtvnVTt/Yg98GR0H5/V69YW+f1QCJ7ba4rzirq txXUi1KE8WFr+IuQzKwBaUc4luUgilwSzlbyUtlOc8i6z6CL4kDEqq24l5RuU337NQVh kF+PG1oTp5C8lRPVdQgt7Q+iPAc60LRDfrDZBPe4BxstmPLtJVsHIKEiDkxv4xnMovJs ws50Fm1qky0UDlc7kT9bL7wn0JHwtTMQ3UFEbhqx7ARb5wgJYsqGfFCK8z0Ew8eaatru iVNg== X-Gm-Message-State: ANoB5pn7E2aLRY88t62YHkRKdIhrCEej73GfNxcpURLaOLRiDB7T11Ae qya1ViRTrJ9LlLxmI+4aAhc/mSHu5b7MCuUz4h2zifdErWdU0Y12qmI= X-Google-Smtp-Source: AA0mqf5WSqobHn1aXTfose9civlOERUWr+ler4zrFMlOmyOTwPA8fWXfDwkGv5x2E1KMjkfCkwDKZTNurKCW55PW+rY= X-Received: by 2002:a81:9143:0:b0:3d3:c9b1:fc50 with SMTP id i64-20020a819143000000b003d3c9b1fc50mr20690293ywg.218.1670155975385; Sun, 04 Dec 2022 04:12:55 -0800 (PST) MIME-Version: 1.0 From: Eli Qian Date: Sun, 4 Dec 2022 20:12:44 +0800 Message-ID: Subject: Clocking in is pretty slow in version 9.6 when the item has a large To: emacs-orgmode@gnu.org Content-Type: multipart/alternative; boundary="000000000000a1e6eb05eeff7d98" Received-SPF: pass client-ip=2607:f8b0:4864:20::1141; envelope-from=eli.q.qian@gmail.com; helo=mail-yw1-x1141.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_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Sun, 04 Dec 2022 11:42:55 -0500 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-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1670172235; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=RUEVeS4hNSC4ywOTMa5Gqd11RlCgMnZB6L0pJPD7LOk=; b=WphIEJj5V6/Y15HdFFfaE2sNx4IDxLDyvpQAiRKNsELJzgKB6/FkBOByWu29U2ofbTsFZY 294ZEPhe8H3ATGABkbOxM4SySWdciyfbFSPJQ8vTThdm1RbgKHIkjlIwMm23a6cMQGo431 PHdd52hN5Ex2+JmiqgBXCz3j3YZo2tWnabgSyWXMBliU45NN/oY4WM5N9W8LhpSumwcJMP UXu4Pa3HzYITaEC1YgsjYUhMRmrDC13oJSMPVJ6G005GQVWkWN9naFQ1Ia/6nGAcsorkAz FRuBKJXVjdKjCuqX6A9whXRwsWbP9+NuDBzz7tetKkn/SClwXM03LlkvJH8waQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1670172235; a=rsa-sha256; cv=none; b=cPWp3lNn7InhE65OP0A8uIdlWyZroWfHiT6IDpPqcOl9hI1LoZWE+XSfsbCadMupKfY6qw 3reMxJ9GISXUtOOsH3AgcEZDFtHP2QZ/CY2J+qgYp60FSl03ksIcKn4H0a99EL9EQ7IRZJ /ri1lLIdjfder7yW7I5ofNXan62tAgA6gYWVRXfi8ncN446ixHp53x+xHvdaA3MibiOg0t JCXhSE8hKZRSpCBDKxk6cp0ZqUxRpxlQMDYIcKShWm5LSGbuaWw9NmJOqOJk7O4oIgEDDP BtGg12+5wWTZp9JZBLIIf9YJatTFBtoOzDiDRrnqECYL9bk5buqvuIohyVzBzA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=m286Wnll; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Spam-Score: -2.46 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=m286Wnll; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Queue-Id: 42B48459A7 X-Spam-Score: -2.46 X-Migadu-Scanner: scn1.migadu.com X-TUID: FXub7dNWBqIm --000000000000a1e6eb05eeff7d98 Content-Type: text/plain; charset="UTF-8" I use the following method to get the time taken for `org-clocl-in`: (benchmark 1 '(org-clock-sum (org-clock-get-sum-start))) In my case, the item has 1400+ entries in its logbook, clocking in will cost 1-2s to finish(benchmark results: "Elapsed time: 1.689801s (0.527506s in 7 GCs)"). That's abnormal because it is done very quickly in version 9.5.5.(benchmark result: "Elapsed time: 0.057270s") After investigation by using profiler, I found the problem is caused by `org-element-at-point`, which was added to `org-clock-sum` in version 9.6. Any idea about speeding up clocking in? --000000000000a1e6eb05eeff7d98 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I use the following method to get the time taken for `org-= clocl-in`:
(benchmark 1 '(org-clock-sum (org-clock-get-sum-start)))<= br>
In my case, the item has 1400+ entries in its logbook, =C2=A0clockin= g in will cost
1-2s to finish(benchmark results: "Elapsed time: 1.6= 89801s (0.527506s in 7
GCs)"). That's abnormal because it is do= ne very quickly in version
9.5.5.(benchmark result: "Elapsed time: = 0.057270s")

After investigation by using profiler, I found the = problem is caused by
`org-element-at-point`, which was added to `org-clo= ck-sum` in version 9.6.

Any idea about speeding up clocking in?
<= /div> --000000000000a1e6eb05eeff7d98--