X-Loop: help-debbugs@HIDDEN Subject: bug#33641: guile-2.9.1 multi-threading crash Resent-From: Linas Vepstas <linasvepstas@HIDDEN> Original-Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> Resent-CC: bug-guile@HIDDEN Resent-Date: Thu, 06 Dec 2018 02:42:01 +0000 Resent-Message-ID: <handler.33641.B.154406406527245 <at> debbugs.gnu.org> Resent-Sender: help-debbugs@HIDDEN X-GNU-PR-Message: report 33641 X-GNU-PR-Package: guile X-GNU-PR-Keywords: To: 33641 <at> debbugs.gnu.org X-Debbugs-Original-To: bug-guile@HIDDEN Reply-To: linasvepstas@HIDDEN Received: via spool by submit <at> debbugs.gnu.org id=B.154406406527245 (code B ref -1); Thu, 06 Dec 2018 02:42:01 +0000 Received: (at submit) by debbugs.gnu.org; 6 Dec 2018 02:41:05 +0000 Received: from localhost ([127.0.0.1]:34863 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>) id 1gUjb7-00075M-6n for submit <at> debbugs.gnu.org; Wed, 05 Dec 2018 21:41:05 -0500 Received: from eggs.gnu.org ([208.118.235.92]:60857) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from <linasvepstas@HIDDEN>) id 1gUjb5-00074m-IZ for submit <at> debbugs.gnu.org; Wed, 05 Dec 2018 21:41:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <linasvepstas@HIDDEN>) id 1gUjay-00042N-Mq for submit <at> debbugs.gnu.org; Wed, 05 Dec 2018 21:40:58 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:46565) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from <linasvepstas@HIDDEN>) id 1gUjaw-0003wl-Q7 for submit <at> debbugs.gnu.org; Wed, 05 Dec 2018 21:40:56 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:42171) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from <linasvepstas@HIDDEN>) id 1gUjau-0006I6-K5 for bug-guile@HIDDEN; Wed, 05 Dec 2018 21:40:54 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from <linasvepstas@HIDDEN>) id 1gUjap-0003mm-OH for bug-guile@HIDDEN; Wed, 05 Dec 2018 21:40:52 -0500 Received: from mail-io1-xd2b.google.com ([2607:f8b0:4864:20::d2b]:39995) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from <linasvepstas@HIDDEN>) id 1gUjad-0003kK-Up for bug-guile@HIDDEN; Wed, 05 Dec 2018 21:40:39 -0500 Received: by mail-io1-xd2b.google.com with SMTP id n9so18457570ioh.7 for <bug-guile@HIDDEN>; Wed, 05 Dec 2018 18:40:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:reply-to:from:date:message-id:subject:to; bh=zQQSP6ksOwEPwZYcf77bp0dnA7cet9wMp23TWNjk/0g=; b=dUoR9wlytGmaXsqiykUobyqVUnd8S2fDjXvPTwXygLoOtmefQEiKXcUoQKsErEXugW 9ACyOLHpmexYzdeaF2qT2o5WkGCKoJmI8sOFvs0nHnaDEFcg4uLJ9D3XQtROab2OaLsV VfZFKnrGQp1ktT9kJz/fXLQNDnQHfyN/k1iCnTrbz59UdRjHSPN6W4RsOG05dXMyijcx /WeK2xXgxycbSuTzE+hDSClFGdVkZTzv2YG7FCB19g247dXLQTwyTeCtQcKp7nGbNexN DPYO1FsHEGScrd0XEK9Yr9z9YId9ELKSauHk0dBBeUgSqsUS16OkJWLNpJDCpwv8eQJB nLug== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:reply-to:from:date:message-id :subject:to; bh=zQQSP6ksOwEPwZYcf77bp0dnA7cet9wMp23TWNjk/0g=; b=tCNwfwOPtbq5/k2HKemZna9KcN8zhlZQqeAsATmeRj6r9Ar4/iFyleLgQyUzsPwH8w vCPAronDEi1kMBWW1VY10qTObxWPSAIfgF8gO3+sgLuaCu9QJf7YZ9/QyW4zh7VMTsrE ybSlKePKH+9FISk4bm+p1zbsNPk4pz3NeXgKxRmt2gUwDozgY10w7HeyLCIsZN43H5KL dm12/LsL6xWX7luW1lhrIWCvoqgx5RgORiVsPwTKQMo6UKAASyZNwQWyG+XTR9Dg8C9q hvVSEscCZ6rPT233HDApX6UKcq48A1Able0+4PZsQ17pK29PW3a0gQRhQcfu+xpt6hGm MxQQ== X-Gm-Message-State: AA+aEWbJwqY/WZMagztZeuhdkJIEbxYiAIwsnpcuzE8AnsuEgDXf9At2 UH6/NfjZwSak/m0gCW3JTkwCM4MTMLL2+dfGuBZ1G9CS X-Google-Smtp-Source: AFSGD/UmCGDDo/5cbLaRwVet0OWxbxzL5E3ocGyi392bdqWD0HhbnkEfxkLi/lidBzlMZ9siDpT0H5NTSBKefFZ5ybs= X-Received: by 2002:a5e:8618:: with SMTP id z24mr14430699ioj.35.1544064034431; Wed, 05 Dec 2018 18:40:34 -0800 (PST) MIME-Version: 1.0 From: Linas Vepstas <linasvepstas@HIDDEN> Date: Wed, 5 Dec 2018 20:40:20 -0600 Message-ID: <CAHrUA37oy7NgytspabAPPCzZhbQLEHVZGL-EgYyJZbG+S0DkLQ@HIDDEN> Content-Type: multipart/alternative; boundary="00000000000048672d057c516c22" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-BeenThere: debbugs-submit <at> debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: <debbugs-submit.debbugs.gnu.org> List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe> List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/> List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org> List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help> List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe> Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org> X-Spam-Score: -5.0 (-----) --00000000000048672d057c516c22 Content-Type: text/plain; charset="UTF-8" The following bug report is informal, without any simple test, right now. Very reproducible, though. I have a unit test (it passes with guile-2.2) that creates 120 threads and races them as fast as possible, each thread launched from C++, entering guile, and then from guile, calling some wrappered C++ code. With 2.9.1, the test crashes about half the time, always with the same stack trace ``` (gdb) info threads Id Target Id Frame 1 Thread 0x7ffff7fdcbc0 (LWP 24595) "MultiThreadUTes" 0x00007ffff7bc298d in pthread_join (threadid=140737247344384, thread_return=0x0) at pthread_join.c:90 ``` and most of the rest in `__lll_lock_wait` (that my c++ code asks for) or `pthread_cond_wait@@GLIBC_2.3.2` from GC_wait_marker. The stack trace itself is useless; the core issue is the `thread_return=0x0` above. ``` (gdb) bt #0 0x00007ffdb03c7040 in ?? () #1 0x0000000000000001 in ?? () #2 0x00007ffff40a553c in __GI___libc_free (mem=<optimized out>) at malloc.c:2968 #3 0x0000000000000000 in ?? () ``` Its hard to see what this has to do with guile, other than that this test has been run thousands of times on guile-2.2 without issues. (Reproducible by running the "MultiThreadUTest" of https://github.com/opencog/atomspace) -- Linas -- cassette tapes - analog TV - film cameras - you --00000000000048672d057c516c22 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div dir=3D"ltr"><div dir=3D"ltr"><div dir=3D"ltr"><div><b= r></div>The following bug report is informal, without any simple test, righ= t now. Very reproducible, though. <br><br>I have a unit test (it passes wit= h guile-2.2) that creates 120 threads and races them as fast as possible, e= ach thread launched from C++, entering guile, and then from guile, calling = some wrappered C++ code. With 2.9.1, the test crashes about half the time, = always with the same stack trace<br>```<br>(gdb) info threads<br>=C2=A0 Id= =C2=A0=C2=A0 Target Id=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 Fram= e<br>=C2=A0 1=C2=A0=C2=A0=C2=A0 Thread 0x7ffff7fdcbc0 (LWP 24595) "Mul= tiThreadUTes"<br>0x00007ffff7bc298d in pthread_join (threadid=3D140737= 247344384,<br>thread_return=3D0x0)<br>=C2=A0=C2=A0=C2=A0 at pthread_join.c:= 90<br>```<br>and most of the rest in `__lll_lock_wait` (that my c++ code as= ks for) or `pthread_cond_wait@@GLIBC_2.3.2` from GC_wait_marker. The stack = trace itself is useless; the core issue is the `thread_return=3D0x0` above.= <br>```<br>(gdb) bt<br>#0=C2=A0 0x00007ffdb03c7040 in ?? ()<br>#1=C2=A0 0x0= 000000000000001 in ?? ()<br>#2=C2=A0 0x00007ffff40a553c in __GI___libc_free= (mem=3D<optimized out>)<br>=C2=A0=C2=A0=C2=A0 at malloc.c:2968<br>#3= =C2=A0 0x0000000000000000 in ?? ()<br>```<br>Its hard to see what this has = to do with guile, other than that this test has been run thousands of times= on guile-2.2 without issues.<br><br></div><div>(Reproducible by running th= e "MultiThreadUTest" of <a href=3D"https://github.com/opencog/ato= mspace">https://github.com/opencog/atomspace</a>)<br><br clear=3D"all"></di= v><div dir=3D"ltr"><div>-- Linas<br></div><div>-- <br><div dir=3D"ltr" clas= s=3D"gmail_signature"><div dir=3D"ltr">cassette tapes - analog TV - film ca= meras - you<br></div></div></div></div></div></div></div> --00000000000048672d057c516c22--
Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) Content-Type: text/plain; charset=utf-8 X-Loop: help-debbugs@HIDDEN From: help-debbugs@HIDDEN (GNU bug Tracking System) To: linasvepstas@HIDDEN Subject: bug#33641: Acknowledgement (guile-2.9.1 multi-threading crash) Message-ID: <handler.33641.B.154406406527245.ack <at> debbugs.gnu.org> References: <CAHrUA37oy7NgytspabAPPCzZhbQLEHVZGL-EgYyJZbG+S0DkLQ@HIDDEN> X-Gnu-PR-Message: ack 33641 X-Gnu-PR-Package: guile Reply-To: 33641 <at> debbugs.gnu.org Date: Thu, 06 Dec 2018 02:42:02 +0000 Thank you for filing a new bug report with debbugs.gnu.org. This is an automatically generated reply to let you know your message has been received. Your message is being forwarded to the package maintainers and other interested parties for their attention; they will reply in due course. Your message has been sent to the package maintainer(s): bug-guile@HIDDEN If you wish to submit further information on this problem, please send it to 33641 <at> debbugs.gnu.org. Please do not send mail to help-debbugs@HIDDEN unless you wish to report a problem with the Bug-tracking system. --=20 33641: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D33641 GNU Bug Tracking System Contact help-debbugs@HIDDEN with problems
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd,
1994-97 Ian Jackson.