Bug #38727 BUILD/compile-solaris-* scripts should compile MySQL with libmtmalloc
Submitted: 11 Aug 2008 19:08 Modified: 17 Oct 2008 18:24
Reporter: Neel Nadgir Email Updates:
Status: Closed Impact on me:
Category:MySQL Server: Compiling Severity:S5 (Performance)
Version:6.0 bzr, 5.1 OS:Solaris
Assigned to: Davi Arnaut CPU Architecture:Any
Tags: performance

[11 Aug 2008 19:08] Neel Nadgir
We have data that demonstrates mtmalloc to be faster than libc malloc for MySQL (and other multithreaded) programs. Please modify the BUILD/compile-solaris* scripts to use mtmalloc. Currently only BUILD/compile-solaris-amd64 uses it.

How to repeat:
Download the source; run ./BUILD/compile-solaris-sparc. Once done, 
"ldd sql/mysqld |grep mtmalloc" should not return any results.

Suggested fix:
Just add the following line to the scripts.
[11 Aug 2008 19:23] Valeriy Kravchuk
Thank you for a reasonable feature request.
[30 Sep 2008 20:58] 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:


2748 Davi Arnaut	2008-09-30
      Bug#38727: BUILD/compile-solaris-* scripts should compile MySQL with libmtmalloc
      Link with mtmalloc on Solaris as it is done in our release builds.
      Replace deprecated flag with the newer option as already done in
      other scripts.
[30 Sep 2008 21:01] Neel Nadgir
If you are looking for numbers, please see http://mikaelronstrom.blogspot.com/2008/03/speeding-up-mysql-by-36-on-t2000.html. Mikael got 8.1% boost with libmtmalloc
[30 Sep 2008 21:24] Davi Arnaut
Queued to 5.1-bugteam
[9 Oct 2008 18:06] Bugs System
Pushed into 5.1.30  (revid:davi.arnaut@sun.com-20080930205748-nwy2f2nr5yr9n93s) (version source revid:davi.arnaut@sun.com-20080930205748-nwy2f2nr5yr9n93s) (pib:4)
[15 Oct 2008 15:09] Paul DuBois
This is actually pushed to 5.1.29, not 5.1.30.
[15 Oct 2008 17:52] Paul DuBois
Noted in 5.1.29 changelog.

The BUILD/compile-solaris-* scripts now compile MySQL with the
mtmalloc library rather than malloc. 

Setting report to NDI pending push into 6.0.x.
[17 Oct 2008 16:45] Bugs System
Pushed into 6.0.8-alpha  (revid:davi.arnaut@sun.com-20080930205748-nwy2f2nr5yr9n93s) (version source revid:patrick.crews@sun.com-20081001020816-ye5etpbfjw4431qe) (pib:5)
[17 Oct 2008 18:24] Paul DuBois
Noted in 6.0.8 changelog.
[28 Oct 2008 21:04] Bugs System
Pushed into 5.1.29-ndb-6.2.17  (revid:davi.arnaut@sun.com-20080930205748-nwy2f2nr5yr9n93s) (version source revid:tomas.ulin@sun.com-20081028140209-u4emkk1xphi5tkfb) (pib:5)
[28 Oct 2008 22:23] Bugs System
Pushed into 5.1.29-ndb-6.3.19  (revid:davi.arnaut@sun.com-20080930205748-nwy2f2nr5yr9n93s) (version source revid:tomas.ulin@sun.com-20081028194045-0353yg8cvd2c7dd1) (pib:5)
[1 Nov 2008 9:49] Bugs System
Pushed into 5.1.29-ndb-6.4.0  (revid:davi.arnaut@sun.com-20080930205748-nwy2f2nr5yr9n93s) (version source revid:jonas@mysql.com-20081101082305-qx5a1bj0z7i8ueys) (pib:5)