aboutsummaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorNadav Rotem <nrotem@apple.com>2012-12-19 18:02:36 +0000
committerNadav Rotem <nrotem@apple.com>2012-12-19 18:02:36 +0000
commit3e6da7e0dc7f264578203315272721919023a1b1 (patch)
treee8ce2f0dbcb2f2b228d74800062f86d3775cfc08 /docs
parent91223a41ef0f5b469b1230919cba9012beb6f321 (diff)
downloadexternal_llvm-3e6da7e0dc7f264578203315272721919023a1b1.zip
external_llvm-3e6da7e0dc7f264578203315272721919023a1b1.tar.gz
external_llvm-3e6da7e0dc7f264578203315272721919023a1b1.tar.bz2
DOC: document the use of O2, O3 and Os with -fvectorize.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@170567 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'docs')
-rw-r--r--docs/Vectorizers.rst8
1 files changed, 6 insertions, 2 deletions
diff --git a/docs/Vectorizers.rst b/docs/Vectorizers.rst
index 84fef67..9507fd6 100644
--- a/docs/Vectorizers.rst
+++ b/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 <http://llvm.org/viewvc/llvm-project/test-suite/trunk/SingleSource/UnitTests/Vectorizer/>`_.
This benchmarks is a collection of loops from the GCC autovectorization
-`page <http://gcc.gnu.org/projects/tree-ssa/vectorization.html>`_ by Dorit Nuzman._
+`page <http://gcc.gnu.org/projects/tree-ssa/vectorization.html>`_ 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.