On 4/1/11 5:51 AM, Tor Didriksen wrote:
> #At file:///export/home/didrik/repo/trunk-implicit-template/ based on
> revid:mattias.jonsson@stripped
>
> 3351 Tor Didriksen 2011-04-01
> Bug 11929733 - 59607: REMOVE THE FNO-IMPLICIT-TEMPLATES COMPILATION FLAG
>
> Explicit template instantiations introduces extra code maintenance,
> and actually yields code bloat with modern gcc compilers/linkers:
> - we instantiate code which is un-used
> - we disable optimization of common code for pointer-based templates
>
> The mysqld executable size shrinks with about 200Kb with this patch.
OK to push. One minor comment below.
> === modified file 'cmake/ssl.cmake'
> --- a/cmake/ssl.cmake 2010-07-19 14:17:07 +0000
> +++ b/cmake/ssl.cmake 2011-04-01 08:51:25 +0000
> @@ -1,4 +1,4 @@
> -# Copyright (C) 2009 Sun Microsystems, Inc
> +# Copyright (c) 2009, 2011, Oracle and/or its affiliates. All rights reserved.
> #
> # This program is free software; you can redistribute it and/or modify
> # it under the terms of the GNU General Public License as published by
> @@ -27,13 +27,7 @@ MACRO (MYSQL_USE_BUNDLED_SSL)
> SET(SSL_INTERNAL_INCLUDE_DIRS ${CMAKE_SOURCE_DIR}/extra/yassl/taocrypt/mySTL)
> SET(SSL_DEFINES "-DHAVE_YASSL -DYASSL_PURE_C -DYASSL_PREFIX -DHAVE_OPENSSL
> -DYASSL_THREAD_SAFE")
> CHANGE_SSL_SETTINGS("bundled")
> - #Remove -fno-implicit-templates
> - #(yassl sources cannot be compiled with it)
> SET(SAVE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
> - IF(CMAKE_CXX_FLAGS)
> - STRING(REPLACE "-fno-implicit-templates" "" CMAKE_CXX_FLAGS
> - ${CMAKE_CXX_FLAGS})
> - ENDIF()
> ADD_SUBDIRECTORY(extra/yassl)
> ADD_SUBDIRECTORY(extra/yassl/taocrypt)
> SET(CMAKE_CXX_FLAGS ${SAVE_CXX_FLAGS})
I don't think we need to save and restore CMAKE_CXX_FLAGS anymore.
Could you check?
Regards,
Davi