- CN_CONNECTIVITY_ALGO::ForEachItem
move implementation to header, so that a lambda can be inlined by the
compiler. improves iteration performance x2
- CN_ITEM::Net
move implementation to header, so that it can be inlined by the
compiler.
- CONNECTIVITY_DATA::GetNetItems
don't use std::set to filter out duplicates. use std::unique on sorted
vector. use a bitset to perform type check.
With pads, we should check available anchor points for each connection,
increasing probability of finding connection to match fill algorithm
Fixes: lp:1844661
* https://bugs.launchpad.net/kicad/+bug/1844661
Pads not on copper layers now do not have a netname, and are no longer taken in account in connectivity.
Especially it avoid creating useless rats-nests for these pads.
Give the user the option of cancelling a file open if there are
segment zones; otherwise they're converted to polygon fills.
Fixes: lp:1823087
* https://bugs.launchpad.net/kicad/+bug/1823087
It is possible for an async thread to simply be deferred if not
specifically set to async. In which case, until the return value is
requested, the loop may simply wait.
By decoupling from std::thread, we can avoid the wait/sleep cycle in
checking the std::atomic completion variable. The std::future variables
are immediately returning without the additional atomic check cycle.
This minimizes the thread usage, particularly during online actions such
as moving items and routing.
UpdateRatsnest: Minimized the number of atomics by utilizing future
promise. Avoided updating node-less nets. Node-less nets are common in
the dynamic ratsnest because the net vector is created from the board
nets by value but only populated with a subset. So the dynamic ratsnest
calculation always saw every net as dirty and spun up extra threads.
searchConnections: ParallelThreadCount is no longer lower bounded.
Small item counts are handled inline rather than with a separate thread.
Locks protect the std::set in each item. Devolving the mutex to the
CN_ITEM allows multiple threads to make simultaneous connections to
different items where they do not conflict.
The connectivity files were unwieldy. This separates them logically
into data, algo and items where the items classes are those that hold,
surprise, surprise, the items, lists and clusters.