From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 135E46DE034D for ; Fri, 16 Jun 2017 08:34:07 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -0.12 X-Spam-Level: X-Spam-Status: No, score=-0.12 tagged_above=-999 required=5 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id syMckmes811q for ; Fri, 16 Jun 2017 08:34:06 -0700 (PDT) Received: from mail-it0-f51.google.com (mail-it0-f51.google.com [209.85.214.51]) by arlo.cworth.org (Postfix) with ESMTPS id 5B39B6DE0164 for ; Fri, 16 Jun 2017 08:34:06 -0700 (PDT) Received: by mail-it0-f51.google.com with SMTP id m47so29518781iti.0 for ; Fri, 16 Jun 2017 08:34:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=NR0+Cr328nLvvd9M5+WbhSOXtwV/mMpqh4hxaFGAcSk=; b=bYFWVhoYEIaI1CUWiztSutB9XcOndCcMvK277zEAN1hdNr+ntYoqKtyXrq1QBzU7QS 99s4WFI8gKj9gAZnImiKK6cc6rOSYmj4MNORqLVQVDOnBRrniXQvE+sp/L0neFpBk8X3 8tvR94HE6NhEuTb+H1tb3pOWdwjNkvek/Imz34xiheGzoU+8CKlvBHUhaS5yhA98mSxL CXqRABdl6xcX3c4Af0GCKK3u4iDpk6TfzPDO7/ewaffgpcb20HH11+jDp1Tdu4y8VLu4 VzLG1rWEiITnxPvwsKsqs29ajxL/MqbHMTGrbW+5Hp5uBE3bJ+saQecy77GBlBMOfAuV gtLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=NR0+Cr328nLvvd9M5+WbhSOXtwV/mMpqh4hxaFGAcSk=; b=orPjZfYdxDSFS67ddTGHFHpX2m1VQSUQYBuSjLE3lfX9ROHrLm3BcMr8koHM15eFkx 5Mqax6sgM0aTiAavzh8TYi1SxzDWyMT4b05hM23LqCsSAOYnzgp+39bTyXhyPUNxUY0u SkWEZWPgxlZ0NmpQQbQ74Bg+Et76/HD4cxBqmBwmTtIMBRVPZw0n2VKZWpDrf9ZKXfCt rmtcJZh+dMDW6JToZsdnSoCFEREn4rPFCOOWt5waW9B6527j6LpobpM09SBzWM7HbvNk js21eIQd0pnMgqhmmhgXgXUwpFRUV3t3BkAS9JiqtRZ1RcmrY3tXNtHMX8VI0bIaDDqs ppKA== X-Gm-Message-State: AKS2vOx8dZvdXYqmO6Z+jveiI+QCWQF+PpCm27vdQ5yY0iSOfnIPGWn8 9e0NgMWXlQINQY8yHIp4fUN/nvyn+5rT X-Received: by 10.36.189.5 with SMTP id x5mr8705381ite.95.1497627245288; Fri, 16 Jun 2017 08:34:05 -0700 (PDT) MIME-Version: 1.0 Received: by 10.79.35.219 with HTTP; Fri, 16 Jun 2017 08:34:04 -0700 (PDT) From: Piotr Trojanek Date: Fri, 16 Jun 2017 16:34:04 +0100 Message-ID: Subject: High CPU usage on Tree View with many emails To: notmuch@notmuchmail.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Jun 2017 15:34:07 -0000 Hi, I am trying notmuch + notmuch-emacs version 0.23.5-1~bpo8+1 from debian jessie backports, and reproduced this issue with both emacs 24.4 (jessie) and 24.5+1-6~bpo8+1 (jessie backports). When I make a query that gives many results (e.g. "review", which hits ~2200 emails with my Gerrit reviews) and want to display them in Tree View, the CPU usage stays high for several seconds. While this happens, the Emacs window flickers, like it was busy with redisplaying the buffer. If I pull the horizontal scroll of the Emacs buffer down, I can see that the buffer grows (like messages being inserted there). The Emacs profiler says that more than 50% of CPU time is spend in notmuch-tree-insert-forest-thread. Interestingly, the in the non-tree view the same query is processed in no time. Any idea? -- Piotr Trojanek