RS485/LogisticsPipes — pull request #340 by AartBluestoke (2013-01-01 08:25:53+00:00)
Title: Routing update - major server efficency improvements

replacing _routeCosts with a list
cache pipe access.

cpu load decreases about 30%, calculating the routes for 800 nodes falls from 2.6 to 1.7 seconds.

both changes need testing smp (seem fine single player)

_externalRoutersByCost is just a copy of _routeCosts, so have
CreateRouteTable just make the right sorted list to begin with -
concurrent access is handled by just handing out a pointer to a list
that is never modified.

IRouter.getRoutersByCost was modified to accept any list, because there
is no reason to actually use a linkedList, as it is neither created, or
modified randomly.

also, added in the _myPipeCache pipe cache - passing items to a
non-ticking pipe seems to have no effect (i walked in and out of range
of my pipe network several times, and it didn't seem to have any effect;
(nothing miss-routed that i could see, nothing in the error log, no
items dropped), but has not been tested SMP.