I now this is a question asked many times. However, I cannot find a solution for my specific problem.
I have implemented the Fast Marching Method (really similar to Dijkstra) in C++11 and two different variants: with Fibonacci heap and Binary Heap. For this, I have used the Boost 1.55 heap implementations (Fibonacci and D_ary, D=2).
It is expected the binary heap to be faster in small grids and the Fibonacci's to be faster in huge grids. However, the binary heap is always faster (and there is a "huge" difference). For example:
200x200 grid:
Binary: 16 ms
Fibonacci: 24 ms
300x300 grid:
Binary: 38 ms
Fibonacci: 50 ms
500x500 grid:
Binary: 113 ms
Fibonacci: 148 ms
1000x1000 grid:
Binary: 504 ms
Fibonacci: 642 ms
I am using -Ofast -fno-finite-math-only
flags in G++ 4.8.
The main point is that I can assure that a few weeks ago exactly the same implementation returned expected results.
Can anybody give me some light on this please?
Thank you!