[Cmake-commits] CMake branch, next, updated. v3.0.0-rc3-1787-gec4e2a1

Robert Maynard robert.maynard at kitware.com
Thu Apr 3 11:39:18 EDT 2014


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  ec4e2a1dd1f165f9e25335505cca54bacb2248b6 (commit)
       via  01eaffdeb07dd3aa24667afd93185f0ee32c43fe (commit)
      from  0db2409e341e88e62e3844c6d3ed3a730f6bf476 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=ec4e2a1dd1f165f9e25335505cca54bacb2248b6
commit ec4e2a1dd1f165f9e25335505cca54bacb2248b6
Merge: 0db2409 01eaffd
Author:     Robert Maynard <robert.maynard at kitware.com>
AuthorDate: Thu Apr 3 11:39:17 2014 -0400
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Thu Apr 3 11:39:17 2014 -0400

    Merge topic 'Qt4moc_perf' into next
    
    01eaffde QT4_CREATE_MOC_COMMAND is now a function.

diff --cc Modules/Qt4Macros.cmake
index aca8996,5ada030..23c4fc0
--- a/Modules/Qt4Macros.cmake
+++ b/Modules/Qt4Macros.cmake
@@@ -141,10 -141,10 +141,10 @@@ function (QT4_CREATE_MOC_COMMAND infil
    set(_moc_extra_parameters_file @${_moc_parameters_file})
    add_custom_command(OUTPUT ${outfile}
                        COMMAND Qt4::moc ${_moc_extra_parameters_file}
 -                      DEPENDS ${infile}
 +                      DEPENDS ${infile} ${_moc_parameters_file}
                        ${_moc_working_dir}
                        VERBATIM)
- endmacro ()
+ endfunction ()
  
  
  macro (QT4_GENERATE_MOC infile outfile )

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=01eaffdeb07dd3aa24667afd93185f0ee32c43fe
commit 01eaffdeb07dd3aa24667afd93185f0ee32c43fe
Author:     Robert Maynard <robert.maynard at kitware.com>
AuthorDate: Thu Apr 3 11:27:58 2014 -0400
Commit:     Robert Maynard <robert.maynard at kitware.com>
CommitDate: Thu Apr 3 11:27:58 2014 -0400

    QT4_CREATE_MOC_COMMAND is now a function.
    
    When we parse a large string ( moc_flags ) that has generator expressions
    while inside a macro it has poor performance. This is due to the fact
    that the because we are in a macro we have to evaluate the contents of the
    string. By moving to a function we eliminate the need to evaluate the entire
    contents of the string, and increase the performance.
    
    In non scientific testing I have seen a 10x performance increase by moving
    QT4_CREATE_MOC_COMMAND to being a function.

diff --git a/Modules/Qt4Macros.cmake b/Modules/Qt4Macros.cmake
index 8baf896..5ada030 100644
--- a/Modules/Qt4Macros.cmake
+++ b/Modules/Qt4Macros.cmake
@@ -103,7 +103,7 @@ endmacro()
 
 
 # helper macro to set up a moc rule
-macro (QT4_CREATE_MOC_COMMAND infile outfile moc_flags moc_options moc_target)
+function (QT4_CREATE_MOC_COMMAND infile outfile moc_flags moc_options moc_target)
   # For Windows, create a parameters file to work around command line length limit
   # Pass the parameters in a file.  Set the working directory to
   # be that containing the parameters file and reference it by
@@ -144,7 +144,7 @@ macro (QT4_CREATE_MOC_COMMAND infile outfile moc_flags moc_options moc_target)
                       DEPENDS ${infile}
                       ${_moc_working_dir}
                       VERBATIM)
-endmacro ()
+endfunction ()
 
 
 macro (QT4_GENERATE_MOC infile outfile )

-----------------------------------------------------------------------

Summary of changes:
 Modules/Qt4Macros.cmake |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list