RFC: jemalloc: qdbus sigsegv in malloc_init

Dimitry Andric dim at FreeBSD.org
Mon May 21 09:03:19 UTC 2012


On 2012-05-21 04:54, David Xu wrote:
...
> As I said, it depends on ordering the global objects are destructed, if 
> the object which deleting
> the current_thread_data_key is destructed lastly, the problem wont 
> happen, but now
> it is destructed too early. I believe there is no specification said 
> that which C++ object should be
> destructed first if they are in different compiled module and then are 
> linked together to generated
> a shared object, .so file.

Indeed, the order in which global constructors or destructors are called
is undefined.  Depending on the order is a bug (a.k.a. the "static
initialization order fiasco").


More information about the freebsd-current mailing list