Re: [PATCH v4 08/16] reorganize indexing of multipart/signed and multipart/encrypted
[notmuch-archives.git] / ca / aae1e2b616d9d51c73c1318f5a311cba3c66b6
1 Return-Path: <olly@survex.com>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5  by arlo.cworth.org (Postfix) with ESMTP id 23BCB6DE02B5\r
6  for <notmuch@notmuchmail.org>; Thu,  7 Apr 2016 17:03:15 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at cworth.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -2.421\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-2.421 tagged_above=-999 required=5\r
12  tests=[AWL=-0.120, RCVD_IN_DNSWL_MED=-2.3, SPF_PASS=-0.001]\r
13  autolearn=disabled\r
14 Received: from arlo.cworth.org ([127.0.0.1])\r
15  by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)\r
16  with ESMTP id zCKOoGFKIfci for <notmuch@notmuchmail.org>;\r
17  Thu,  7 Apr 2016 17:03:07 -0700 (PDT)\r
18 X-Greylist: delayed 2244 seconds by postgrey-1.35 at arlo;\r
19  Thu, 07 Apr 2016 17:03:06 PDT\r
20 Received: from atreus.tartarus.org (atreus.tartarus.org [80.252.125.10])\r
21  by arlo.cworth.org (Postfix) with ESMTPS id CF23C6DE0134\r
22  for <notmuch@notmuchmail.org>; Thu,  7 Apr 2016 17:03:06 -0700 (PDT)\r
23 Received: from olly by atreus.tartarus.org with local (Exim 4.69)\r
24  (envelope-from <olly@survex.com>)\r
25  id 1aoJIw-0002w0-2y; Fri, 08 Apr 2016 00:25:38 +0100\r
26 Date: Fri, 8 Apr 2016 00:25:38 +0100\r
27 From: Olly Betts <olly@survex.com>\r
28 To: David Bremner <david@tethera.net>\r
29 Cc: notmuch@notmuchmail.org, xapian-discuss@lists.xapian.org\r
30 Subject: Re: slowdown in notmuch perf suite with xapian 1.3.5\r
31 Message-ID: <20160407232537.GB29434@survex.com>\r
32 Reply-To: Xapian Discussion <xapian-discuss@lists.xapian.org>\r
33 Mail-Followup-To: David Bremner <david@tethera.net>,\r
34  notmuch@notmuchmail.org, xapian-discuss@lists.xapian.org\r
35 References: <87twjd639d.fsf@zancas.localnet>\r
36 MIME-Version: 1.0\r
37 Content-Type: text/plain; charset=us-ascii\r
38 Content-Disposition: inline\r
39 In-Reply-To: <87twjd639d.fsf@zancas.localnet>\r
40 User-Agent: Mutt/1.5.21 (2010-09-15)\r
41 X-BeenThere: notmuch@notmuchmail.org\r
42 X-Mailman-Version: 2.1.20\r
43 Precedence: list\r
44 List-Id: "Use and development of the notmuch mail system."\r
45  <notmuch.notmuchmail.org>\r
46 List-Unsubscribe: <https://notmuchmail.org/mailman/options/notmuch>,\r
47  <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
48 List-Archive: <http://notmuchmail.org/pipermail/notmuch/>\r
49 List-Post: <mailto:notmuch@notmuchmail.org>\r
50 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
51 List-Subscribe: <https://notmuchmail.org/mailman/listinfo/notmuch>,\r
52  <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
53 X-List-Received-Date: Fri, 08 Apr 2016 00:03:15 -0000\r
54 \r
55 On Thu, Apr 07, 2016 at 08:56:46AM -0300, David Bremner wrote:\r
56 > I hadn't noticed any interactive slowdown, but when I got around to\r
57 > running the notmuch performance suite, there seems to be some noticable\r
58 > slowdown with the glass backend (default in Xapian 1.3.5) compared to\r
59 > chert (using xapian 1.2.22)\r
60 \r
61 Some of this is pretty much expected, though other parts I don't\r
62 entirely understand.\r
63 \r
64 One of the big changes in glass is how the position table is structured.\r
65 In chert, it is ordered by (document,term) but in glass that has been\r
66 changed to (term,document).\r
67 \r
68 This change makes a huge difference to phrase searches in cases where\r
69 a lot of phrase data is needed, but it has an indexing time cost -\r
70 adding a new document can no longer just append a load of entries to\r
71 the position table, but instead we need to buffer up the changes, and\r
72 then merge the entries within the existing table.\r
73 \r
74 The trade-off isn't ideal for everyone, but the cases of slow phrase\r
75 searches were a real pain point that needed addressing.  The plan is\r
76 to optimise indexing speed in other ways to regain this loss - some\r
77 of that has been done but there's a lot more to do still.\r
78 \r
79 So the T00-new.sh numbers make sense - there's more work to do, and\r
80 we need to read existing positional data more to insert the new stuff,\r
81 so the increased reads and writes make sense.\r
82 \r
83 But guessing at what the other two tests do, I wouldn't expect them to\r
84 be affected by this.\r
85 \r
86 I'm also a bit puzzled by how glass can manage not to read any data\r
87 for "dump *", and several tests seem to not read or write anything\r
88 for either backend.  What exactly are the "In/Out" numbers?\r
89 \r
90 Cheers,\r
91     Olly\r