Bug #59607 Remove the fno-implicit-templates compilation flag
Description:
The fno-implicit-templates compilation flag actually makes
mysqld bigger, so let's remove it.
It also forces us to write un-necessary code like:
#ifdef HAVE_EXPLICIT_TEMPLATE_INSTANTIATION
template class List<String>;
template class List_iterator<String>;
#endif
It also forces us to play extra tricks in some CMakeFile's
extra/yassl/CMakeLists.txt: #Remove -fno-implicit-templates
unittest/gunit/CMakeLists.txt: # Remove -fno-implicit-templates, gunit sources cannot be compiled with it.
How to repeat:
Compile with/without fno-implicit-templates
optimized, with gcc (GCC) 4.4.2
size with fno... 47278223
size without fno... 47023929
Running nm on the binares, I see that with fno-implicit
we get explicit instantiations of lots of functons
000000000053ce60 W List_iterator<Alter_drop>::ref()
000000000053cd20 W List_iterator<Alter_drop>::init(List<Alter_drop>&)
000000000053db00 W List_iterator<Alter_drop>::after(Alter_drop*)
000000000053cde0 W List_iterator<Alter_drop>::remove()
000000000053cdd0 W List_iterator<Alter_drop>::rewind()
000000000053cd60 W List_iterator<Alter_drop>::replace(Alter_drop*)
000000000053cd70 W List_iterator<Alter_drop>::replace(List<Alter_drop>&)
000000000053ccc0 W List_iterator<Alter_drop>::List_iterator(List<Alter_drop>&)
000000000053cd00 W List_iterator<Alter_drop>::List_iterator()
000000000053cca0 W List_iterator<Alter_drop>::List_iterator(List<Alter_drop>&)
000000000053cce0 W List_iterator<Alter_drop>::List_iterator()
000000000053cd40 W List_iterator<Alter_drop>::operator++(int)
....
....
All this stuff is optimized away when removing the flag.
Suggested fix:
Remove it.
Portions of this website are copyright © 2001, 2002 The PHP Group
Page generated in 0.048 sec. using MySQL 8.4.7-u6-cloud
Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the
respective copyright holders.
It is not reviewed in advance
by Oracle and does not necessarily represent the opinion of
Oracle or any other party.