Rockbox

  • Status Closed
  • Percent Complete
    100%
  • Task Type Bugs
  • Category Playlists
  • Assigned To No-one
  • Operating System All players
  • Severity Low
  • Priority Very Low
  • Reported Version Daily build (which?)
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by PaulJam - 2008-05-24
Last edited by jdgordon - 2008-06-16

FS#9032 - "Create Playlist" doesn't work as expected anymore

Hi,

the entry “Playlists⇒Create Playlist” now appends the songs to the playlist instead of overwriting the old playlist, so the root.m3u8 has many duplicates when you don’t remove it manually before running “Create Playlist”.
This behaviour started with revision 17352.

Also the creation of the playlist takes a little longer now.
H300 with ~3000 songs (dircache on, disk not spinning):
r17351: ~5s
r17352 & r17622: ~9s

Closed by  jdgordon
2008-06-16 07:37
Reason for closing:  Not a Bug
Additional comments about closing:   Warning: Undefined array key "typography" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 371 Warning: Undefined array key "camelcase" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 407

refer to the last comment

the first issue is fixed… dunn about the speed problem though

unlikely.. but let me know if this speeds it up at all…

   changes (0.9 KiB)

In r17351, create playlist just did a very simple opendir/readdir loop, writing the result to a file. In r17352, filetree.c functions are used to load the directory. I’d guess that the biggest reason for the slow-down is that after having completed a directory, the parent directory is reloaded.

By the way, I don’t quite like recursive functions having a local MAX_PATH filename buffer (that’s playlist_directory_tracksearch)… The code removed in r17352 managed quite nicely without it. :)

yes, but why have repeated code? if you want to fix it.. rework the svn code to not use the file browser…

Well, I wasn’t complaining about removing the old/duplicated code, just pointing out why I thought the new code was slower. Fixing it would change the order of the files in the playlist though (but when generating recursively, the difference would mainly be in the degree of randomness).

this patch should speed it up, but the created playlist isnt in the sorted order it is now…

e.g…

/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/07 - Lady Deathwish.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/10 - Hall Of Heroes.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/05 - Skeletal Onslaught.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/11 - Balls Of Ice.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/06 - Journey To The Promiseland.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/08 - Curse Of The Lighthouse Keeper.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/01 - Ride Darkhorse Ride.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/02 - Destroy The Orcs.mp3
/music/3 Inches Of Blood/Battlecry Under a Winter Sun - 2002/03 - Headwaters of the River of Blood.mp3

IMO its better to be slow and in order than fast (and really 4s wont hurt anyone…

   changes (3.5 KiB)

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing