[vlc-devel] [PATCH 1/5] modules: module_list_cap sort list using the name argument
remi at remlab.net
Thu Jun 4 10:52:37 CEST 2015
Le 2015-06-04 11:34, Thomas Guillem a écrit :
> Now, if you specify ":codec=hwdecoder2,hwdecoder1,any" in the name
> arguments (or any compatible shortcuts), the list will be sorted like
> As the list is fully sorted, you know that you could try hwdecoder1
> hwdecoder2 fails. See the next patch.
Optimizing that would make sense if we had a large list of names, or a
large list of plugins matching a name. In practice, this patch makes
everything slower in the real-life situations:
- not matching any name, or
- matching only one or very few names.
It seems to me that you would need qsort_r() to keep the code
digestible. Regardless I still don't see how this optmization fits with
the rest of the patch series.
More information about the vlc-devel