public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug libitm/57643] New: libitm.c/reentrant.c hangs on POWER8 with HTM @ 2013-06-18 19:05 bergner at gcc dot gnu.org 2013-06-19 7:14 ` [Bug libitm/57643] " torvald at gcc dot gnu.org ` (2 more replies) 0 siblings, 3 replies; 4+ messages in thread From: bergner at gcc dot gnu.org @ 2013-06-18 19:05 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57643 Bug ID: 57643 Summary: libitm.c/reentrant.c hangs on POWER8 with HTM Product: gcc Version: 4.9.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libitm Assignee: unassigned at gcc dot gnu.org Reporter: bergner at gcc dot gnu.org The libitm.c/reentrant.c test case hangs on POWER8 hardware with HTM. The symptoms I'm seeing are my tbegin. instruction succeeds, but we fail the test (meaning someone has the write lock) at beginend.cc:200: if (unlikely(serial_lock.is_write_locked())) htm_abort(); ...so we abort the transaction. The failure is not persistent, so we do not break out of the loop due to: if (!htm_abort_should_retry(ret)) break; We then fall into the following code, where we hang trying to get the read lock: serial_lock.read_lock(tx); If I hack the call to htm_abort_should_retry(ret) so that we break of of the loop and fallback to SW TM, then the test case executes correctly. Andreas Krebbel said this fails on S390 as well. Andreas Kleen said this works on X86 with RTM. It's unknown whether on X86 whether its hw txn fails or succeeds or whether if it does fail over to sw txn, whether it skips the code we're hanging in. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libitm/57643] libitm.c/reentrant.c hangs on POWER8 with HTM 2013-06-18 19:05 [Bug libitm/57643] New: libitm.c/reentrant.c hangs on POWER8 with HTM bergner at gcc dot gnu.org @ 2013-06-19 7:14 ` torvald at gcc dot gnu.org 2013-06-24 15:57 ` bergner at gcc dot gnu.org 2014-03-03 22:14 ` bergner at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: torvald at gcc dot gnu.org @ 2013-06-19 7:14 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57643 torvald at gcc dot gnu.org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |ASSIGNED Last reconfirmed| |2013-06-19 CC| |torvald at gcc dot gnu.org Assignee|unassigned at gcc dot gnu.org |torvald at gcc dot gnu.org Ever confirmed|0 |1 ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libitm/57643] libitm.c/reentrant.c hangs on POWER8 with HTM 2013-06-18 19:05 [Bug libitm/57643] New: libitm.c/reentrant.c hangs on POWER8 with HTM bergner at gcc dot gnu.org 2013-06-19 7:14 ` [Bug libitm/57643] " torvald at gcc dot gnu.org @ 2013-06-24 15:57 ` bergner at gcc dot gnu.org 2014-03-03 22:14 ` bergner at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: bergner at gcc dot gnu.org @ 2013-06-24 15:57 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57643 Peter Bergner <bergner at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED --- Comment #1 from Peter Bergner <bergner at gcc dot gnu.org> --- This was confirmed fixed (on Power and S390) with Torvald's two patches: http://gcc.gnu.org/ml/gcc-patches/2013-06/msg01132.html (revision 200250) http://gcc.gnu.org/ml/gcc-patches/2013-06/msg01188.html (revision 200251) ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug libitm/57643] libitm.c/reentrant.c hangs on POWER8 with HTM 2013-06-18 19:05 [Bug libitm/57643] New: libitm.c/reentrant.c hangs on POWER8 with HTM bergner at gcc dot gnu.org 2013-06-19 7:14 ` [Bug libitm/57643] " torvald at gcc dot gnu.org 2013-06-24 15:57 ` bergner at gcc dot gnu.org @ 2014-03-03 22:14 ` bergner at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: bergner at gcc dot gnu.org @ 2014-03-03 22:14 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57643 --- Comment #2 from Peter Bergner <bergner at gcc dot gnu.org> --- Author: bergner Date: Mon Mar 3 22:13:28 2014 New Revision: 208295 URL: http://gcc.gnu.org/viewcvs?rev=208295&root=gcc&view=rev Log: Backport from mainline 2013-06-20 Torvald Riegel <triegel@redhat.com> * query.cc (_ITM_inTransaction): Abort when using the HTM fastpath. (_ITM_getTransactionId): Same. * config/x86/target.h (htm_transaction_active): New. 2013-06-20 Torvald Riegel <triegel@redhat.com> PR libitm/57643 * beginend.cc (gtm_thread::begin_transaction): Handle reentrancy in the HTM fastpath. Modified: branches/gcc-4_8-branch/libitm/ChangeLog branches/gcc-4_8-branch/libitm/beginend.cc branches/gcc-4_8-branch/libitm/config/x86/target.h branches/gcc-4_8-branch/libitm/query.cc ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-03-03 22:14 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2013-06-18 19:05 [Bug libitm/57643] New: libitm.c/reentrant.c hangs on POWER8 with HTM bergner at gcc dot gnu.org 2013-06-19 7:14 ` [Bug libitm/57643] " torvald at gcc dot gnu.org 2013-06-24 15:57 ` bergner at gcc dot gnu.org 2014-03-03 22:14 ` bergner at gcc dot gnu.org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).