mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-12-22 09:24:54 +01:00
notmuch-tag: don't sort messages before applying tag changes
It's not neccessary to sort the results before we apply tags. Xapian contributor Olly Betts says that savings might be bigger with a cold file cache and (as unsorted implies really sorted by document id) a better cache locality when applying tags to messages. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
This commit is contained in:
parent
aadb15a002
commit
40ff2ab62a
1 changed files with 3 additions and 0 deletions
|
@ -107,6 +107,9 @@ notmuch_tag_command (void *ctx, unused (int argc), unused (char *argv[]))
|
|||
return 1;
|
||||
}
|
||||
|
||||
/* tagging is not interested in any special sort order */
|
||||
notmuch_query_set_sort (query, NOTMUCH_SORT_UNSORTED);
|
||||
|
||||
for (messages = notmuch_query_search_messages (query);
|
||||
notmuch_messages_valid (messages) && !interrupted;
|
||||
notmuch_messages_move_to_next (messages))
|
||||
|
|
Loading…
Reference in a new issue