Well, looks like I've proven myself wrong! I've been doing some profiling.
Playing a single track with no effects active the EngineEffectChain::m_groupStatus map's operator[] method accounts for 14% of time spent in EngineMaster::process. The bulk of time spent is in QString::operator<.
Switching to a QHash drops this to 5.9% but just shifts the bulk of the work into qHash(QString).
Switching to searching a QLinkedList drops this to 4% and the bulk of the work is in QString::operator==.
If we solved this bug by giving every GroupHandle an incremental integer (starting at zero) then we could probably use a QVarLengthArray and index directly. I would guess the time spent doing lookups would be negligible in that case.
> I'm happy to be proven otherwise
Well, looks like I've proven myself wrong! I've been doing some profiling.
Playing a single track with no effects active the EngineEffectCha in::m_groupStat us map's operator[] method accounts for 14% of time spent in EngineMaster: :process. The bulk of time spent is in QString::operator<.
Switching to a QHash drops this to 5.9% but just shifts the bulk of the work into qHash(QString). :operator= =.
Switching to searching a QLinkedList drops this to 4% and the bulk of the work is in QString:
If we solved this bug by giving every GroupHandle an incremental integer (starting at zero) then we could probably use a QVarLengthArray and index directly. I would guess the time spent doing lookups would be negligible in that case.