
Hi, compiling and linking the following program on a opteron with the following command and the operating system red hat 3 (current enterprise server version) gcc-3.2.2 -c -I. -I../source -I./boost_1_32_0 -O2 -m64 boosttest.cc -o boosttest.o gcc-3.2.2 -m64 -o boosttest boosttest.o -lstdc++ will cause, that the program runs into an endles loop. I figured out, that the pointer in VIter which is compared when comparing VIter and VIterEnd is damaged. With a lot of differen gcc versions and also in 32 bit mode and with lower optimization it works fine. The problem is, I have to run it also compiled with gcc 3.2.2. Is it an optimization bug in the compiler or any mistake I made or a problem in the boost? I was looking for a hint on the net but without success. Can anybody help? Thanks ------------------------------------------------------------------------------- int main (int argc, char **argv) { typedef boost::adjacency_list < boost::listS, boost::listS, boost::undirectedS
my_graph2_t;
my_graph2_t MyGraph2; boost::graph_traits<my_graph2_t>::vertex_descriptor MyVDescriptor; boost::graph_traits<my_graph2_t>::vertex_descriptor MyNextVDescriptor; MyVDescriptor = boost::add_vertex(MyGraph2); MyNextVDescriptor = boost::add_vertex(MyGraph2); boost::add_edge(MyVDescriptor, MyNextVDescriptor, MyGraph2); boost::graph_traits<my_graph2_t>::adjacency_iterator VIter; boost::graph_traits<my_graph2_t>::adjacency_iterator VIterEnd; tie(VIter, VIterEnd) = boost::adjacent_vertices(MyVDescriptor, MyGraph2); while ( VIter != VIterEnd ) { std::cout << "loop ..." << std::endl; ++VIter; } return 0; } --------------------------------------------------------------------------------