On 2/24/2017 11:42 AM, Chris Pavlina wrote: > On Fri, Feb 24, 2017 at 11:38:26AM -0500, Wayne Stambaugh wrote: >> On 2/24/2017 11:29 AM, Chris Pavlina wrote: >>> Hi all and Wayne, >>> >>> Since the addition of SCH_PLUGIN, enumerating all symbols (done by the >>> component selector) has become dog slow on Windows and macOS. I've >>> tracked this down to the excursion from an alias list to a list of >>> strings and back to an alias list, because the only functions SCH_PLUGIN >>> provides to access the aliases are by name. >>> >>> This is why the component selector now takes literally five seconds to >>> appear on Windows. >>> >>> I have a patch in progress that adds parallels to these API functions >>> that directly populate a list of LIB_ALIASes rather than their names. >>> I'm in the process of testing it on all three platforms. It is a fairly >>> minor addition, but I don't want to touch SCH_PLUGIN without permission >>> since Wayne is working on it. >>> >>> Wayne, are you okay with a patch that adds SCH_LEGACY_PLUGIN:: >>> EnumerateSymbolLib( std::vector<LIB_ALIAS*>&, ... )? This is the only >>> place it touches the plugin API, plus a couple places in PART_LIB and >>> several in the component chooser. >>> >> >> If it temporarily resolves this issue, then I'm OK with it. It would be >> nice to be able to limit the exposure of this plugin call for just the >> current PART_LIBS implementation which will have to remain forever to >> support legacy symbol lookup. Once symbol lookup by path goes away with >> the symbol library table (in progress), this will not be necessary since >> there will always be a one to one mapping of the symbol to a given >> library. In other words there will be no symbol lookup. All symbol >> access will be done by a full qualified LIB_ID. > > I'm not sure if I understand what you mean, but okay thanks, I'll push > it soon :) > > How does symbol access "by a fully qualified LIB_ID" help for > enumerating an entire library, such as what a component selector has to > do in order to filter and sort and search through the library? Is there > some sort of wildcard LIB_ID that returns a collection of symbols?
I was referring to the current look up of symbols when the schematic is loaded. In this case, a vector of LIB_ALIAS pointers makes sense. > >> >> >> _______________________________________________ >> Mailing list: https://launchpad.net/~kicad-developers >> Post to : kicad-developers@lists.launchpad.net >> Unsubscribe : https://launchpad.net/~kicad-developers >> More help : https://help.launchpad.net/ListHelp _______________________________________________ Mailing list: https://launchpad.net/~kicad-developers Post to : kicad-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~kicad-developers More help : https://help.launchpad.net/ListHelp