kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #30205
Re: Perf HighlightConnectionAtPosition
Personally, I think your proposal sounds quite sensible, and I'm not
aware of any reason they _must_ be in a vector. Care to try it out and
see if it works?
On Tue, Aug 01, 2017 at 01:52:28AM +0530, Gaurav Juvekar wrote:
> Hi all,
>
> I was just playing around and found that the highlight net tool is visibly slow. I delved into the code, and saw that finding connected NETLIST_OBJECT involves needlessly looping over NETLIST_OBJECTS.
>
> Is there any performance consideration behind having the NETLIST_OBJECTS as a std::vector? Would it be better to have an std::unordered_map from the net codes to a std::vector of all NETLIST_OBJECT with that net code?
>
> Rudimentary instrumentation with callgrind shows that most of the time is spent in SCH_SHEET_PATH comparisons.
>
> --
> Regards,
> Gaurav Juvekar
>
> _______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to : kicad-developers@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help : https://help.launchpad.net/ListHelp
Follow ups
References