[Bug c++/71541] destructor of condition_variable_any crashes with static linkage

2016-07-03 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71541 Andrew Pinski changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

[Bug c++/71541] destructor of condition_variable_any crashes with static linkage

2016-06-17 Thread gcc_bugzilla at haphi dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71541 --- Comment #6 from Hans Philipp Annen --- > -Wl,--whole-archive -lpthread -Wl,--no-whole-archive This did help. Without it, the destructor of condition_variable just jumps to nowhere: > Dump of assembler code for function

[Bug c++/71541] destructor of condition_variable_any crashes with static linkage

2016-06-17 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71541 --- Comment #5 from Jonathan Wakely --- It does for Fedora and Red Hat-derived systems. Try: -Wl,--whole-archive -lpthread -Wl,--no-whole-archive

[Bug c++/71541] destructor of condition_variable_any crashes with static linkage

2016-06-16 Thread gcc_bugzilla at haphi dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71541 --- Comment #4 from gcc_bugzilla at haphi dot de --- (In reply to Jonathan Wakely from comment #3) > You need to link to libpthread to use std::condition_variable_any. Adding -lpthread doesn't change the situation.

[Bug c++/71541] destructor of condition_variable_any crashes with static linkage

2016-06-15 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71541 --- Comment #3 from Jonathan Wakely --- You need to link to libpthread to use std::condition_variable_any.

[Bug c++/71541] destructor of condition_variable_any crashes with static linkage

2016-06-15 Thread gcc_bugzilla at haphi dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71541 --- Comment #2 from gcc_bugzilla at haphi dot de --- Created attachment 38702 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38702=edit preprocessed file of trivial repro case

[Bug c++/71541] destructor of condition_variable_any crashes with static linkage

2016-06-15 Thread gcc_bugzilla at haphi dot de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71541 --- Comment #1 from gcc_bugzilla at haphi dot de --- compiled with: > gcc -static -o trivial_repro_case trivial_repro_case.cpp > ./trivial_repro_case > Segmentation fault (core dumped) output of gcc -v: > Using built-in specs. > COLLECT_GCC=gcc