ComputationalRadiationPhysics / graybat

Graph Approach for Highly Generic Communication Schemes Based on Adaptive Topologies :satellite:
Other
8 stars 4 forks source link

Unittest dont run #114

Closed fabian-jung closed 7 years ago

fabian-jung commented 7 years ago

Initilization of Zmqconfig Object throws runtime exception.

` [Thread debugging using libthread_db enabled] Using host libthread_db library "/usr/lib/libthread_db.so.1". terminate called after throwing an instance of 'std::logic_error' what(): basic_string::_M_construct null not valid

Program received signal SIGABRT, Aborted. 0x00007ffff5c3204f in raise () from /usr/lib/libc.so.6 (gdb) bt

0 0x00007ffff5c3204f in raise () from /usr/lib/libc.so.6

1 0x00007ffff5c3347a in abort () from /usr/lib/libc.so.6

2 0x00007ffff65494bd in __gnu_cxx::__verbose_terminate_handler () at /build/gcc-multilib/src/gcc/libstdc++-v3/libsupc++/vterminate.cc:95

3 0x00007ffff6547276 in cxxabiv1::terminate (handler=) at /build/gcc-multilib/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:47

4 0x00007ffff65472c1 in std::terminate () at /build/gcc-multilib/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:57

5 0x00007ffff65474d8 in cxxabiv1::cxa_throw (obj=obj@entry=0x7f7c80, tinfo=0x7ffff6832a38 , dest=0x7ffff655cc80 std::logic_error::~logic_error())

at /build/gcc-multilib/src/gcc/libstdc++-v3/libsupc++/eh_throw.cc:87

6 0x00007ffff6570c6f in std::throw_logic_error (s=__s@entry=0x7ffff65f4630 "basic_string::_M_construct null not valid") at /build/gcc-multilib/src/gcc/libstdc++-v3/src/c++11/functexcept.cc:74

7 0x00007ffff65de364 in std::cxx11::basic_string<char, std::char_traits, std::allocator >::_M_construct<char const*> (this=this@entry=0x7fffffffdfd0, beg=__beg@entry=0x0,

__end=<optimized out>) at /build/gcc-multilib/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/include/bits/basic_string.tcc:212

8 0x00007ffff65de51c in std::__cxx11::basic_string<char, std::char_traits, std::allocator >::_M_construct_aux<char const*> (end=, beg=0x0, this=0x7fffffffdfd0)

at /build/gcc-multilib/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/include/bits/basic_string.h:196

9 std::cxx11::basic_string<char, std::char_traits, std::allocator >::_M_construct<char const*> (end=, __beg=0x0, this=0x7fffffffdfd0)

at /build/gcc-multilib/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/include/bits/basic_string.h:215

10 std::__cxx11::basic_string<char, std::char_traits, std::allocator >::basic_string (this=0x7fffffffdfd0, s=0x0, a=...)

at /build/gcc-multilib/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/include/bits/basic_string.h:456

11 0x000000000052f534 in __static_initialization_and_destruction_0(int, int) ()

12 0x000000000052fa99 in _GLOBAL__sub_I__ZN32graybat_cage_point_to_point_test9zmqConfigE ()

13 0x000000000059bedd in __libc_csu_init ()

14 0x00007ffff5c1f220 in __libc_start_main () from /usr/lib/libc.so.6

15 0x000000000052a4ea in _start ()

`

erikzenker commented 7 years ago

Can you specify how you run the unit test and which unit test you run? The exceptions says that a string was initialized with null. If you have a look at the construction of ZMQConfig here then this can happen if you do not run the excutable within an mpi environment which provides you the OMPI_COMM_WORLD_SIZE environment variable.

fabian-jung commented 7 years ago

Running unittests with mpi, solved the problem.