emms-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[emms-help] Fixing slow track info queries


From: Pierre Neidhardt
Subject: [emms-help] Fixing slow track info queries
Date: Sat, 07 Apr 2018 17:26:04 +0530
User-agent: mu4e 1.0; emacs 25.3.1

When emms-info-asynchronously is non-nil, the track information queries
is extremely slow: when adding a new album to Emms, it takes 0.5s for
each track to be displayed properly (that is, for Emms for retrieve the
metadata).

This is because of `later-do-interval`, which defaults to 0.5s.

When emms-info-asynchronously is nil, Emms can fetch hundreds of track
metadata per second.
If there are too many tracks (such as with a complete music library),
this could effectively freeze Emacs until Emms is finished.

It would be nice to improve the asynchronous performance so that the
user would not have to care about running in asynchronous mode or not.

Two suggestions:

- Set up an idle timer that runs every S seconds and process N tracks of a
  queue (new defvar).  With N>100, this would be much faster and it
  would not hang Emacs.  Problem is, it's an extra timer.

- Be more data-driven: refactor emms-source-file.el so that functions
  work on lists of tracks.  This is much better design in my opinion,
  but it would require significant work.

What do you think?

-- 
Pierre Neidhardt

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]