Date: Mon, 17 Nov 2014 10:30:04 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-threads@FreeBSD.org Subject: [Bug 195098] New: pthread lock performance degradation Message-ID: <bug-195098-16@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=195098 Bug ID: 195098 Summary: pthread lock performance degradation Product: Base System Version: 10.0-RELEASE Hardware: amd64 OS: Any Status: Needs Triage Severity: Affects Some People Priority: --- Component: threads Assignee: freebsd-threads@FreeBSD.org Reporter: ueno@gnu.org Created attachment 149508 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=149508&action=edit test case It is known that Gnulib's test for its 'lock' module sometimes takes long time to complete. As the module is a thin wrapper around pthreads, I've rewritten the test with pthreads functions to isolate the problem, and reproduced the same problem. The test basically does: - for 50000 rounds: - initialize a variable PERFORMED to 0 - create 10 threads - in each thread, try to increase PERFORMED by one, through pthread_once - check PERFORMED is 1 The symptoms I observed are: - when the test completes in time, ~1000-3000 rounds are performed per second - when the test takes long time, only ~10 rounds are performed per second I'm attaching the test program, which also prints timestamp for each iteration. See also: https://lists.gnu.org/archive/html/bug-gnulib/2014-09/msg00025.html for the original bug report. -- You are receiving this mail because: You are the assignee for the bug.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-195098-16>