Boost logo

Boost Users :

Subject: Re: [Boost-users] [BGL] premature termination in dijkstra using visitor
From: Andrew Sutton (andrew.n.sutton_at_[hidden])
Date: 2009-10-06 21:28:42


On Tue, Oct 6, 2009 at 10:38 AM, Ralf Goertz
<R_Goertz_at_[hidden]>wrote:

> I managed to create a visitor now, however, instead of speeding things
> up dijkstra_shortest_paths now runs several orders of magnitudes slower!
> I created the visitor according to the bfs_name_printer example in the
> BGL User Guide and Reference Book page 11.
> The code seems to do what I want, all dists are either 0,1,2,3 or
>

> numeric_limits<unsigned>::max(). But for a graph with 15000 edges it
> takes a few ms to run dijkstra without a visitor but with it it takes 14
> seconds. What am I doing wrong?
>

Are you compiling in debug mode? It can cause dramatic slowdowns with the
BGL.

Andrew Sutton
andrew.n.sutton_at_[hidden]



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net