From: Nadav Rotem Date: Wed, 19 Dec 2012 18:02:36 +0000 (+0000) Subject: DOC: document the use of O2, O3 and Os with -fvectorize. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8f4a6cced2212dae2ab15ad665a26a204ccf4612;p=platform%2Fupstream%2Fllvm.git DOC: document the use of O2, O3 and Os with -fvectorize. llvm-svn: 170567 --- diff --git a/llvm/docs/Vectorizers.rst b/llvm/docs/Vectorizers.rst index 84fef67..9507fd69 100644 --- a/llvm/docs/Vectorizers.rst +++ b/llvm/docs/Vectorizers.rst @@ -18,7 +18,11 @@ command line flag: .. code-block:: console - $ clang -fvectorize file.c + $ clang -fvectorize -O3 file.c + +If the ``-fvectorize`` flag is used then the loop vectorizer will be enabled +when running with ``-O3``, ``-O2``. When ``-Os`` is used, the loop vectorizer +will only vectorize loops that do not require a major increase in code size. We plan to enable the Loop Vectorizer by default as part of the LLVM 3.3 release. @@ -194,7 +198,7 @@ Performance This section shows the the execution time of Clang on a simple benchmark: `gcc-loops `_. This benchmarks is a collection of loops from the GCC autovectorization -`page `_ by Dorit Nuzman._ +`page `_ by Dorit Nuzman. The chart below compares GCC-4.7, ICC-13, and Clang-SVN at -O3, running on a Sandybridge. The Y-axis shows time in msec. Lower is better.