From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20986 invoked by alias); 1 Oct 2013 09:24:41 -0000 Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: glibc-bugs-owner@sourceware.org Received: (qmail 20526 invoked by uid 48); 1 Oct 2013 09:24:37 -0000 From: "siddhesh at redhat dot com" To: glibc-bugs@sourceware.org Subject: [Bug nptl/15988] New: tst-mutexpi8 test case failure on non-x86 systems Date: Tue, 01 Oct 2013 09:24:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: nptl X-Bugzilla-Version: unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: siddhesh at redhat dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: siddhesh at redhat dot com X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter cc Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2013-10/txt/msg00000.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=15988 Bug ID: 15988 Summary: tst-mutexpi8 test case failure on non-x86 systems Product: glibc Version: unspecified Status: NEW Severity: normal Priority: P2 Component: nptl Assignee: siddhesh at redhat dot com Reporter: siddhesh at redhat dot com CC: drepper.fsp at gmail dot com tst-mutexpi8 test case fails on non-x86 boxes (tested s390 and got a similar report for ppc) for recursive mutexes. Here's a reproducer that produces the same failure. #include #include #include #include pthread_mutex_t mutex; pthread_mutexattr_t attr; pthread_cond_t cond; pthread_t tid; void *callback(void *arg){ for (;;){ sleep(2); pthread_mutex_lock(&mutex); printf("Wake up!\n"); pthread_cond_broadcast(&cond); pthread_mutex_unlock(&mutex); } } int main(){ pthread_mutexattr_init(&attr); pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); pthread_mutexattr_setprotocol(&attr, PTHREAD_PRIO_INHERIT); pthread_mutex_init(&mutex, &attr); pthread_cond_init(&cond, NULL); pthread_mutex_lock(&mutex); pthread_create(&tid, NULL, callback, &cond); printf("Going to sleep\n"); for(;;){ pthread_cond_wait(&cond, &mutex); printf("OK\n"); exit(0); } } Actual results: Going to sleep Wake up! Wake up! Wake up! Wake up! Wake up! Wake up! Wake up! Wake up! Wake up! Wake up! Wake up! Wake up! ... Expected Result: Going to sleep Wake up! OK Patch coming soon. -- You are receiving this mail because: You are on the CC list for the bug.