From benchmarks, most of the work done in the component is in parsing through the XML file rather than in geometry creation. This is particularly noticeable in the Way component given it must traverse all Node and Way types. Options for improvement could include
For Way parsing: walk through the way nodes first, then route back to the nodes for faster checking if they are relevant
Multi-threading the walk through nodes
Micro-optimisations within the loop structures
Hybridising between the different processor approaches (e.g. Ling and XMLDoc) to use each for what it is fastest at
Skip duplication checks if only parsing a single XML file
Translating from latlon to XY with some sort of mass vector transformation
From benchmarks, most of the work done in the component is in parsing through the XML file rather than in geometry creation. This is particularly noticeable in the Way component given it must traverse all
Node
andWay
types. Options for improvement could includeway
nodes first, then route back to thenodes
for faster checking if they are relevantlatlon
toXY
with some sort of mass vector transformation