Slow speed dial
Posted: Wed Sep 24, 2014 12:39 pm
Hi,
I've noticed a huge slowdown in qlcplus in some cases, and investigated a little.
When pushing a slider on a usb interface, connected to a vcspeeddial, qlcplus can eat a LOT of cpu power.
The widget really eating all the cpu is vccuelist.
Whenever it receives a Doc::functionChanged() signal concerning either the vccuelist's chaser, or any function in the chaser, VCCueList::updateStepList() is called.
And VCCueList::updateStepList() erases the whole widget tree and recreates it.
It can happen 100 times when pushing a slider from the bottom to the top !
So yeah, really slow.
See the attached workspace.
I've been working on a fix ( squashed here https://github.com/plugz/qlcplus/commit ... 595c8d72d4 ), it involves changing the Function::changed() signal to send both the function id and a mask containing the changes made in the function.
It makes it possible to update the parts of the vccuelist we need to update, and not destroying the whole list at every little speed change in a function.
It's not polished yet, but the speed improvement is here and noticeable !
I just want to know if it is worth continuing working down this path, or if you don't want the Function::changed() signal to change.
Regards.
Edit: Also, attached is a screenshot of the changed vccuelist: a common speed is not displayed at each line (update can then take some time too)
I've noticed a huge slowdown in qlcplus in some cases, and investigated a little.
When pushing a slider on a usb interface, connected to a vcspeeddial, qlcplus can eat a LOT of cpu power.
The widget really eating all the cpu is vccuelist.
Whenever it receives a Doc::functionChanged() signal concerning either the vccuelist's chaser, or any function in the chaser, VCCueList::updateStepList() is called.
And VCCueList::updateStepList() erases the whole widget tree and recreates it.
It can happen 100 times when pushing a slider from the bottom to the top !
So yeah, really slow.
See the attached workspace.
I've been working on a fix ( squashed here https://github.com/plugz/qlcplus/commit ... 595c8d72d4 ), it involves changing the Function::changed() signal to send both the function id and a mask containing the changes made in the function.
It makes it possible to update the parts of the vccuelist we need to update, and not destroying the whole list at every little speed change in a function.
It's not polished yet, but the speed improvement is here and noticeable !
I just want to know if it is worth continuing working down this path, or if you don't want the Function::changed() signal to change.
Regards.
Edit: Also, attached is a screenshot of the changed vccuelist: a common speed is not displayed at each line (update can then take some time too)