http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50862
--- Comment #1 from basz <bartosz.szurgot at pwr dot wroc.pl> 2011-10-25 10:28:09 UTC --- Created attachment 25611 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25611 patch fixing the problem unlocking local mutex, before locking back user's lock solves the problem.