https://bugs.freedesktop.org/show_bug.cgi?id=44532
Bug #: 44532
Summary: pa_database_next() is inefficient for the "simple"
pa_database implementation
Classification: Unclassified
Product: PulseAudio
Version: unspecified
Platform: Other
OS/Version: All
Status: NEW
Severity: minor
Priority: medium
Component: core
AssignedTo: [email protected]
ReportedBy: [email protected]
QAContact: [email protected]
CC: [email protected]
If I want to iterate through a database with pa_database_next(), it will have
O(n*n) time complexity with the "simple" pa_database implementation, because
pa_database_next() will every time search for the next item by iterating the
backing pa_hashmap from the beginning.
I'm not sure what would be the best way to fix this. Maybe the pa_database
iteration interface could be changed to match pa_hashmap_iterate()?
In normal use cases I don't see this inefficiency causing any trouble, because
the databases don't tend to be very big. It's just annoying to have this kind
of stuff in the code...
--
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA Contact for the bug.
You are the assignee for the bug.
_______________________________________________
pulseaudio-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-bugs