<div><p>Hello everyone.</p><p>This patch introduces flag <span><strong>--max-macro-exploc-depth=<value></strong>,</span> which allows to set maximum depth of expansion, on which expansion locations will be evaluated. So, if expansion goes deeper than that, no expansion locations are evaluated, which has following features:</p><ul><li>time isn't wasted on location creations</li><li>source locations are saved (running out of source locations will be less frequent)</li></ul><p>Not passing this flag just gives standard clang.</p><p>Example of successful compilation with this flag and unsuccessful otherwise:</p><p>clang -c -ftemplate-depth-32 -O3 -finline-functions -Wno-inline -Wall -pedantic -Wno-variadic-macros -pedantic-errors -std=c++11 -I $BOOST_1_61_HOME <span>-max-macro-exploc-depth=0</span>$BOOST_1_61_HOME/libs/vmd/test/test_doc_modifiers_return_type.cpp</p><p>Here is thread about this and some other proposals.<br /><a href="http://clang-developers.42468.n3.nabble.com/Re-llvm-dev-Clang-Preprocessor-Speed-Up-tt4050728.html">http://clang-developers.42468.n3.nabble.com/Re-llvm-dev-Clang-Preprocessor-Speed-Up-tt4050728.html</a></p><p>I attach preprocessing time for boost statistics so it's possible to see profit gained using new flag. All times there are measured in microseconds. </p></div><div> </div><div>-- </div><div>Regards,<br /> Andrei Serebro</div><div>tel. +79111758381</div><div> </div>