Closed Barsonax closed 6 years ago
In the micro benchmarks for MaxHeap we went from:
To: Which is a solid improvement over the old situation.
Real life benchmarks showed that the AstarAlgorithm is now also slightly (10-20%) faster than it used to be.
Summary
The MaxHeap plays a major role in the performance of the pathfinding algorithms as its used as a priority queue. Some micro benchmarking has shown that storing the result of a property in a local variable can significantly increase performance of the MaxHeap. The compiler probably cannot guarantee the values of the properties do not change and thus cannot optimize them properly.
See if there are any redundant property accesses and optimize these away. Microbenchmarks already have shown significant improvement so measure the result by measuring the performance gains in the pathfind algorithms.