soundmanager pushBuffer is inefficient

Bug #682527 reported by Owen Williams
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mixxx
Fix Released
High
Owen Williams
1.8
Fix Released
High
Owen Williams
1.9
Fix Released
High
Owen Williams

Bug Description

Based on gprof data, the pushBuffer function in soundmanager.cpp is inefficient. Calls to chanGroup.getChannelCount() and chanGroup.getChannelBase() number in the millions after less than a minute of use. Flipping the loop, to iterate through inputs then frames, instead of frames then inputs, results in massive cpu load reduction.

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

Nice catch Owen! There's an identical loop in SoundDevicePortAudio::callbackProcess and this inversion was done in trunk, but the pushBuffer version of the loop was not done.

I backported your patch to 1.8 (since we're going to do a 1.8.2) and also backported the SoundDevicePortAudio::callbackProcess to lp:mixxx/1.8 as well.

Changed in mixxx:
status: New → Fix Committed
importance: Undecided → High
assignee: nobody → Owen Williams (ywwg)
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/5683

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.