Bug #33304 Test 'func_group' hangs on Mac OS X 10.4 PowerPC 64-bit
Submitted: 17 Dec 2007 23:50 Modified: 27 Mar 2008 19:29
Reporter: Kent Boortz Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: DML Severity:S3 (Non-critical)
Version:5.0.54 OS:MacOS (10.4 PowerPC 64-bit)
Assigned to: Ramil Kalimullin CPU Architecture:Any

[17 Dec 2007 23:50] Kent Boortz
Description:
Test 'func_group' hangs on Mac OS X 10.4 PowerPC 64-bit
hangs in query

  SELECT (SELECT SLEEP(0) FROM t1 ORDER BY AVG(DISTINCT a) ) 
    as x FROM t1 GROUP BY x

At least that is the last query visible in the server query log.

How to repeat:
Build a 64 bit binary, and run the test on Mac OS X 10.4 PowerPC.
You can configure like

CC="ccache gcc" \ 
CFLAGS="-Os -arch ppc64 -fno-common" \ 
CXX="ccache gcc" \ 
CXXFLAGS="-Os -arch ppc64 -felide-constructors -fno-common" \ 
LDFLAGS="-arch ppc64" \ 
./configure \ 
--enable-thread-safe-client \ 
--enable-local-infile \ 
--with-pic \ 
--with-client-ldflags="-static" \ 
--with-mysqld-ldflags="-static" \ 
--with-zlib-dir=bundled \ 
--with-big-tables \ 
--with-yassl \ 
--with-libedit \ 
--with-archive-storage-engine \ 
--with-blackhole-storage-engine \ 
--with-csv-storage-engine \ 
--with-example-storage-engine \ 
--without-falcon \ 
--with-federated-storage-engine \ 
--without-innodb \ 
--with-extra-charsets=complex
[15 Feb 2008 7:04] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/42329

ChangeSet@1.2570, 2008-02-15 11:04:11+04:00, ramil@mysql.com +1 -0
  Fix for bug #33304: Test 'func_group' hangs on Mac OS X 10.4 PowerPC 64-bit
  
  Problem: SLEEP(0) never returns on 64-bit Mac OS X due to a bug in 
  pthread_cond_timedwait().
  
  Fix: when given a very short timeout just return immediately.
[15 Feb 2008 12:04] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/42348

ChangeSet@1.2570, 2008-02-15 16:03:54+04:00, ramil@mysql.com +1 -0
  Fix for bug #33304: Test 'func_group' hangs on Mac OS X 10.4 PowerPC 64-bit
  
  Problem: SLEEP(0) never returns on 64-bit Mac OS X due to a bug in 
  pthread_cond_timedwait().
  
  Fix: when given a very short timeout just return immediately.
[27 Mar 2008 11:21] Bugs System
Pushed into 5.0.60
[27 Mar 2008 11:22] Bugs System
Pushed into 5.1.24-rc
[27 Mar 2008 17:54] Bugs System
Pushed into 6.0.5-alpha
[27 Mar 2008 19:29] Paul DuBois
Noted in 5.0.60, 5.1.24, 6.0.5 changelogs.
[2 Apr 2008 15:57] Jon Stephens
Also noted fix in 5.1.23-ndb-6.3.11 changelog.