Improve library performance on large collections

Bug #672762 reported by RAFFI TEA
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Mixxx
Fix Released
Medium
RAFFI TEA

Bug Description

On large music collections (> 50.000 files) and slower computers the library becomes unresponsive. During the SQL query process the GUI freezes for some seconds.

Revision history for this message
RAFFI TEA (raffitea) wrote :

This is really interesting and might contribute to the problem.

When selecting playlists, crates or other root models, BaseSqlModel::select() is called 3-4 times. This is inefficient for <LibraryFeature>TableModels that hold large data sets.

How to reproduce:
* Add a qDebug() to BaseSqlModel::select()
* Execute Mixxx and click on some playlists, crates, etc

This is probably because Mixxx does also call restoreSearch() on sidebar item changes which fires a select as well.

RAFFI TEA (raffitea)
Changed in mixxx:
importance: Undecided → Medium
status: New → Confirmed
Revision history for this message
RAFFI TEA (raffitea) wrote :

I traced back the issue to WTrackTableView::loadTrackModel(QAbstractItemModel *model)

Lines 105 and 108 call method setHorizontalHeader(). Transforming these lines into comments increase performance significantly. Only once select per sidebar item click instead of 4

Rryan: I probably break some functionality with that approach. Could you have a quick look or may be fix the bug? Any comments that directs me in the right directions are welcome.

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

Hey Tobias,

Yea, the select()'s are a problem. Uncommenting that select() debug is a good way to track the selects down. I did this a while back, but it's possible we regressed on how many select()'s we do.

Unfortunately Qt had a very nasty bug in WTrackTableViewHeader that made it so that columns would not update when you changed the QTableView's model. I don't know if it's fixed yet. If you comment out that setHorizontalHeader and everything still works (try switching modes to different views, try adding removing columns in one view and then switching back) then it might be fixed. We can remove it as long as it's fixed on recent Ubuntu versions and the version of Qt we use for Mac / Windows.

RJ

Revision history for this message
RAFFI TEA (raffitea) wrote :

The question is which version we use for 1.9 for Windows and Mac? Still our customized 4.5.3?

Revision history for this message
RAFFI TEA (raffitea) wrote :

Fix is in our features_library branch!
Only one line of code!!

Changed in mixxx:
assignee: nobody → RAFFI TEA (raffitea)
status: Confirmed → Fix Committed
milestone: none → 1.9.0
Revision history for this message
Albert Santoni (gamegod) wrote : Re: [Bug 672762] Re: Improve library performance on large collections

I can use 4.7.1 for our next OS X packages. Not sure if that's viable
or not for Windows - Sean?

On Fri, Nov 12, 2010 at 12:53 PM, RAFFI TEA <email address hidden> wrote:
> Fix is in our features_library branch!
> Only one line of code!!
>
> ** Changed in: mixxx
>     Assignee: (unassigned) => RAFFI TEA (raffitea)
>
> ** Changed in: mixxx
>       Status: Confirmed => Fix Committed
>
> ** Changed in: mixxx
>    Milestone: None => 1.9.0
>
> --
> Improve library performance on large collections
> https://bugs.launchpad.net/bugs/672762
> You received this bug notification because you are a member of Mixxx
> Development Team, which is subscribed to Mixxx.
>

Revision history for this message
Sean M. Pappalardo (pegasus-renegadetech) wrote :

I can use latest Qt as well on Windows unless there are still graphics problems with it.

RJ Skerry-Ryan (rryan)
Changed in mixxx:
status: Fix Committed → Fix Released
Revision history for this message
Swiftb0y (swiftb0y) wrote :

Mixxx now uses GitHub for bug tracking. This bug has been migrated to:
https://github.com/mixxxdj/mixxx/issues/5643

lock status: Metadata changes locked and limited to project staff
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.