Hi everyone,

[ CMake + TRE ]
I was able to make CMake use TRE, by changing the RegularExpression.{cxx,hxx.in} files.

I ran the CMake tests, and 100% pass. See the attached log file. 
(NOTE: Bootstrap, complex, complexOne were initially not aware of TRE dependency, but I fixed that easily).


[ Impact of using CMake + TRE on our builds ]
We picked one of our build machines and replaced the ctest binary on it.
The impact on the build time is pretty dramatic:
     CMake: 7h39m
     CMake + TRE: 1h06m       

This is a machine that has two cores.

On machines that have more cores, the impact is even greater.  On my 8 core machine, running a particular build task:
     CMake: 19m57s
     CMake + TRE:  1m30s       


[ Regular expressions syntax ]
In terms of regular expressions syntax, the only difference that I've seen is that TRE treats the curly brackets "{" and "}" as special characters, because it uses them for its "approximate matching".  Details here:

The only CMake component that uses curly brackets in a regexp is:
    Modules/FindJNI.cmake
but it was trivial to fix because they were used as mere delimiters.

As mentioned earlier, after this change 100% of the tests pass.


[ Implications ]
Note that CTast is *not* the only component that would benefit from faster regular expressions.

I've found at least one other reported case when regular _expression_ were too slow in CMake:

Since Glob uses RegularExpression, I would not be surprised if CMake+TRE will be faster on large code bases.


CONCLUSION: 
  - TRE is fast, benefits build times immensely

QUESTION:
  - Does anyone see a problem if we add TRE in CMake the same way as ZLIB, CURL, etc? (i.e. in ./Utilities/) 


sincerely,
Alex Ciobanu

Attachment: time.ctest.alex.log
Description: Binary data

--

Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers

Reply via email to