List:Packagers« Previous MessageNext Message »
From:Lenz Grimmer Date:May 3 2006 7:32pm
Subject:Re: serious bloat in mysql 5.0.x
View as plain text  
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi Tom,

thanks for your message!

On Tue, 2 May 2006, Tom Lane wrote:

> Has anyone else noticed serious bloat in a lot of the mysql utility
> programs from 5.0.18 to 5.0.19?
> 
> An example is
> -rwxr-xr-x   1 root     root      1166272 Mar 15 14:07 ./usr/bin/mysql_tzinfo_to_sql
> vs 5.0.18
> -rwxr-xr-x   1 root     root       110880 Feb  9 15:23 ./usr/bin/mysql_tzinfo_to_sql
> 
> It looks to me like the culprit is this change
> 
> diff -c -r mysql-5.0.18/mysys/my_init.c mysql-5.0.21/mysys/my_init.c
> *** mysql-5.0.18/mysys/my_init.c	Wed Dec 21 14:39:25 2005
> --- mysql-5.0.21/mysys/my_init.c	Wed Apr 26 14:30:38 2006
> ***************
> *** 152,157 ****
> --- 152,158 ----
>         DBUG_PRINT("error",("%s",errbuff[0]));
>       }
>     }
> +   free_charsets();
>     my_once_free();
>   
>     if ((infoflag & MY_GIVE_INFO) || print_info)
> 
> which causes the *entire* character set support logic and constant
> tables to be sucked into everything that calls my_init.
> 
> I know disk space is cheap, but bandwidth not so much ... was it
> really intentional to bloat these programs an extra megabyte apiece?
> 
> The above is probably worst case, since it's from builds with
> 	--with-extra-charsets=all
> but I'd think that even the typical "complex" set would be most
> of this.

Thanks for pointing this out. Sergey, any comment on this? It seems like the
above change was made by you in this ChangeSet:

[SNIP]
ChangeSet 1.1960.61.1 2005/12/01 23:43:37 SergeyV@selena.
  Fixes bug #11892. When MyODBC or any other client do my_init()/my_end()
  several times, it was causing corruption of charset data stored in once_mem_pool. 
  my_end() deallocated once_mem pool, but did not put a flag that charsets have
  to be reloaded. The fix addresses this problem.
[SNIP]

Is there maybe a better fix for that without causing the unnecessary bloat?

Bye,
	LenZ
- -- 
 Lenz Grimmer <lenz@stripped>
 Community Relations Manager, EMEA
 MySQL GmbH, http://www.mysql.de/, Hamburg, Germany
 Visit the MySQL Forge at http://forge.mysql.com/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: For info see http://quantumlab.net/pine_privacy_guard/

iD8DBQFEWQVqSVDhKrJykfIRAsQfAJ4kYFiQe7VAw/tFTEglSj7gMdeDbwCggI5H
aH9lxD+j28wvtjVmmW8RT50=
=TStn
-----END PGP SIGNATURE-----
Thread
serious bloat in mysql 5.0.xTom Lane3 May
  • Re: serious bloat in mysql 5.0.xLenz Grimmer3 May