mirror of
https://github.com/intel/llvm.git
synced 2026-01-19 01:15:50 +08:00
Adjust documentation for git migration.
This fixes most references to the paths: llvm.org/svn/ llvm.org/git/ llvm.org/viewvc/ github.com/llvm-mirror/ github.com/llvm-project/ reviews.llvm.org/diffusion/ to instead point to https://github.com/llvm/llvm-project. This is *not* a trivial substitution, because additionally, all the checkout instructions had to be migrated to instruct users on how to use the monorepo layout, setting LLVM_ENABLE_PROJECTS instead of checking out various projects into various subdirectories. I've attempted to not change any scripts here, only documentation. The scripts will have to be addressed separately. Additionally, I've deleted one document which appeared to be outdated and unneeded: lldb/docs/building-with-debug-llvm.txt Differential Revision: https://reviews.llvm.org/D57330 llvm-svn: 352514
This commit is contained in:
@@ -139,8 +139,8 @@ Vim Integration
|
||||
|
||||
You can call :program:`clang-rename` directly from Vim! To set up
|
||||
:program:`clang-rename` integration for Vim see
|
||||
`clang-rename/tool/clang-rename.py
|
||||
<https://reviews.llvm.org/diffusion/L/browse/clang-tools-extra/trunk/clang-rename/tool/clang-rename.py>`_.
|
||||
`clang/tools/clang-rename/clang-rename.py
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/tools/clang-rename/clang-rename.py>`_.
|
||||
|
||||
Please note that **you have to save all buffers, in which the replacement will
|
||||
happen before running the tool**.
|
||||
@@ -157,7 +157,7 @@ Emacs Integration
|
||||
You can also use :program:`clang-rename` while using Emacs! To set up
|
||||
:program:`clang-rename` integration for Emacs see
|
||||
`clang-rename/tool/clang-rename.el
|
||||
<https://reviews.llvm.org/diffusion/L/browse/clang-tools-extra/trunk/clang-rename/tool/clang-rename.el>`_.
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/tools/clang-rename/clang-rename.el>`_.
|
||||
|
||||
Once installed, you can point your cursor to symbols you want to rename, press
|
||||
`M-X`, type `clang-rename` and new desired name.
|
||||
|
||||
@@ -127,7 +127,7 @@ style used in the project. For code reviews we mostly use `LLVM Phabricator`_.
|
||||
|
||||
Next, you need to decide which module the check belongs to. Modules
|
||||
are located in subdirectories of `clang-tidy/
|
||||
<https://reviews.llvm.org/diffusion/L/browse/clang-tools-extra/trunk/clang-tidy/>`_
|
||||
<https://github.com/llvm/llvm-project/tree/master/clang-tools-extra/clang-tidy/>`_
|
||||
and contain checks targeting a certain aspect of code quality (performance,
|
||||
readability, etc.), certain coding style or standard (Google, LLVM, CERT, etc.)
|
||||
or a widely used API (e.g. MPI). Their names are same as user-facing check
|
||||
@@ -210,7 +210,7 @@ can further inspect them and report diagnostics.
|
||||
|
||||
(If you want to see an example of a useful check, look at
|
||||
`clang-tidy/google/ExplicitConstructorCheck.h
|
||||
<https://reviews.llvm.org/diffusion/L/browse/clang-tools-extra/trunk/clang-tidy/google/ExplicitConstructorCheck.h>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang-tools-extra/clang-tidy/google/ExplicitConstructorCheck.h>`_
|
||||
and `clang-tidy/google/ExplicitConstructorCheck.cpp
|
||||
<https://reviews.llvm.org/diffusion/L/browse/clang-tools-extra/trunk/clang-tidy/google/ExplicitConstructorCheck.cpp>`_).
|
||||
|
||||
|
||||
@@ -75,7 +75,7 @@ choose the checks to be performed in the Clang Code Model Warnings menu.
|
||||
.. _ReSharper C++: https://www.jetbrains.com/help/resharper/Clang_Tidy_Integration.html
|
||||
.. _Visual Assist: https://docs.wholetomato.com/default.asp?W761
|
||||
.. _Clang Power Tools: https://marketplace.visualstudio.com/items?itemName=caphyon.ClangPowerTools
|
||||
.. _clang-tidy-vs: https://github.com/llvm-mirror/clang-tools-extra/tree/master/clang-tidy-vs
|
||||
.. _clang-tidy-vs: https://github.com/llvm/llvm-project/tree/master/clang-tools-extra/clang-tidy-vs
|
||||
|
||||
`MS Visual Studio`_ has a native clang-tidy-vs_ plugin and also can integrate
|
||||
:program:`clang-tidy` by means of three other tools. The `ReSharper C++`_
|
||||
|
||||
3
clang/.gitignore
vendored
3
clang/.gitignore
vendored
@@ -1,9 +1,6 @@
|
||||
#==============================================================================#
|
||||
# This file specifies intentionally untracked files that git should ignore.
|
||||
# See: http://www.kernel.org/pub/software/scm/git/docs/gitignore.html
|
||||
#
|
||||
# This file is intentionally different from the output of `git svn show-ignore`,
|
||||
# as most of those are useless.
|
||||
#==============================================================================#
|
||||
|
||||
#==============================================================================#
|
||||
|
||||
@@ -69,7 +69,7 @@ Putting it all together
|
||||
Let's look at an example plugin that prints top-level function names. This
|
||||
example is checked into the clang repository; please take a look at
|
||||
the `latest version of PrintFunctionNames.cpp
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/examples/PrintFunctionNames/PrintFunctionNames.cpp?view=markup>`_.
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/examples/PrintFunctionNames/PrintFunctionNames.cpp>`_.
|
||||
|
||||
Running the plugin
|
||||
==================
|
||||
@@ -110,7 +110,7 @@ source tree:
|
||||
-plugin -Xclang print-fns
|
||||
|
||||
Also see the print-function-name plugin example's
|
||||
`README <https://llvm.org/viewvc/llvm-project/cfe/trunk/examples/PrintFunctionNames/README.txt?view=markup>`_
|
||||
`README <https://github.com/llvm/llvm-project/blob/master/clang/examples/PrintFunctionNames/README.txt>`_
|
||||
|
||||
|
||||
Using the clang command line
|
||||
|
||||
@@ -9,22 +9,9 @@ functionality such as fast syntax checking, automatic formatting,
|
||||
refactoring, etc.
|
||||
|
||||
Only a couple of the most basic and fundamental tools are kept in the
|
||||
primary Clang Subversion project. The rest of the tools are kept in a
|
||||
side-project so that developers who don't want or need to build them
|
||||
don't. If you want to get access to the extra Clang Tools repository,
|
||||
simply check it out into the tools tree of your Clang checkout and
|
||||
follow the usual process for building and working with a combined
|
||||
LLVM/Clang checkout:
|
||||
|
||||
- With Subversion:
|
||||
|
||||
- ``cd llvm/tools/clang/tools``
|
||||
- ``svn co https://llvm.org/svn/llvm-project/clang-tools-extra/trunk extra``
|
||||
|
||||
- Or with Git:
|
||||
|
||||
- ``cd llvm/tools/clang/tools``
|
||||
- ``git clone https://llvm.org/git/clang-tools-extra.git extra``
|
||||
primary Clang tree. The rest of the tools are kept in a separate
|
||||
directory tree, ``clang-tools-extra
|
||||
<https://github.com/llvm/llvm-project/tree/master/clang-tools-extra>``_.
|
||||
|
||||
This document describes a high-level overview of the organization of
|
||||
Clang Tools within the project as well as giving an introduction to some
|
||||
|
||||
@@ -196,7 +196,7 @@ those sub-hierarchies need to be (see "Stripping Leading/Trailing Zeros in Bit
|
||||
Vectors" above). The `GlobalLayoutBuilder`_ class is responsible for laying
|
||||
out the globals efficiently to minimize the sizes of the underlying bitsets.
|
||||
|
||||
.. _GlobalLayoutBuilder: https://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Transforms/IPO/LowerTypeTests.h?view=markup
|
||||
.. _GlobalLayoutBuilder: https://github.com/llvm/llvm-project/blob/master/llvm/include/llvm/Transforms/IPO/LowerTypeTests.h
|
||||
|
||||
Alignment
|
||||
~~~~~~~~~
|
||||
@@ -300,7 +300,7 @@ The interleaving scheme, however, can only work with individual virtual tables s
|
||||
In comparison, the old scheme does not require the splitting but it is more efficient when the combined virtual tables have been split.
|
||||
The `GlobalSplit`_ pass is responsible for splitting combined virtual tables into individual ones.
|
||||
|
||||
.. _GlobalSplit: https://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/IPO/GlobalSplit.cpp?view=markup
|
||||
.. _GlobalSplit: https://github.com/llvm/llvm-project/blob/master/llvm/lib/Transforms/IPO/GlobalSplit.cpp
|
||||
|
||||
Order virtual tables by a pre-order traversal of the class hierarchy
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
@@ -1686,7 +1686,7 @@ semantic checking for some attributes, etc.
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
The first step to adding a new attribute to Clang is to add its definition to
|
||||
`include/clang/Basic/Attr.td
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/Attr.td?view=markup>`_.
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/include/clang/Basic/Attr.td>`_.
|
||||
This tablegen definition must derive from the ``Attr`` (tablegen, not
|
||||
semantic) type, or one of its derivatives. Most attributes will derive from the
|
||||
``InheritableAttr`` type, which specifies that the attribute can be inherited by
|
||||
@@ -1748,10 +1748,10 @@ the ``SubjectList``. The diagnostics generated for subject list violations are
|
||||
either ``diag::warn_attribute_wrong_decl_type`` or
|
||||
``diag::err_attribute_wrong_decl_type``, and the parameter enumeration is found
|
||||
in `include/clang/Sema/ParsedAttr.h
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Sema/ParsedAttr.h?view=markup>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/include/clang/Sema/ParsedAttr.h>`_
|
||||
If a previously unused Decl node is added to the ``SubjectList``, the logic used
|
||||
to automatically determine the diagnostic parameter in `utils/TableGen/ClangAttrEmitter.cpp
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/utils/TableGen/ClangAttrEmitter.cpp?view=markup>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/utils/TableGen/ClangAttrEmitter.cpp>`_
|
||||
may need to be updated.
|
||||
|
||||
By default, all subjects in the SubjectList must either be a Decl node defined
|
||||
@@ -1773,7 +1773,7 @@ All attributes must have some form of documentation associated with them.
|
||||
Documentation is table generated on the public web server by a server-side
|
||||
process that runs daily. Generally, the documentation for an attribute is a
|
||||
stand-alone definition in `include/clang/Basic/AttrDocs.td
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/AttdDocs.td?view=markup>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/include/clang/Basic/AttrDocs.td>`_
|
||||
that is named after the attribute being documented.
|
||||
|
||||
If the attribute is not for public consumption, or is an implicitly-created
|
||||
@@ -1824,7 +1824,7 @@ All arguments have a name and a flag that specifies whether the argument is
|
||||
optional. The associated C++ type of the argument is determined by the argument
|
||||
definition type. If the existing argument types are insufficient, new types can
|
||||
be created, but it requires modifying `utils/TableGen/ClangAttrEmitter.cpp
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/utils/TableGen/ClangAttrEmitter.cpp?view=markup>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/utils/TableGen/ClangAttrEmitter.cpp>`_
|
||||
to properly support the type.
|
||||
|
||||
Other Properties
|
||||
@@ -1836,7 +1836,7 @@ document, however a few deserve mention.
|
||||
If the parsed form of the attribute is more complex, or differs from the
|
||||
semantic form, the ``HasCustomParsing`` bit can be set to ``1`` for the class,
|
||||
and the parsing code in `Parser::ParseGNUAttributeArgs()
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Parse/ParseDecl.cpp?view=markup>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/lib/Parse/ParseDecl.cpp>`_
|
||||
can be updated for the special case. Note that this only applies to arguments
|
||||
with a GNU spelling -- attributes with a __declspec spelling currently ignore
|
||||
this flag and are handled by ``Parser::ParseMicrosoftDeclSpec``.
|
||||
@@ -1899,7 +1899,7 @@ semantic attribute class object, with ``public`` access.
|
||||
Boilerplate
|
||||
^^^^^^^^^^^
|
||||
All semantic processing of declaration attributes happens in `lib/Sema/SemaDeclAttr.cpp
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclAttr.cpp?view=markup>`_,
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/lib/Sema/SemaDeclAttr.cpp>`_,
|
||||
and generally starts in the ``ProcessDeclAttribute()`` function. If the
|
||||
attribute is a "simple" attribute -- meaning that it requires no custom semantic
|
||||
processing aside from what is automatically provided, add a call to
|
||||
@@ -1915,11 +1915,11 @@ correct minimum number of arguments are passed, etc.
|
||||
|
||||
If the attribute adds additional warnings, define a ``DiagGroup`` in
|
||||
`include/clang/Basic/DiagnosticGroups.td
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticGroups.td?view=markup>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/include/clang/Basic/DiagnosticGroups.td>`_
|
||||
named after the attribute's ``Spelling`` with "_"s replaced by "-"s. If there
|
||||
is only a single diagnostic, it is permissible to use ``InGroup<DiagGroup<"your-attribute">>``
|
||||
directly in `DiagnosticSemaKinds.td
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/DiagnosticSemaKinds.td?view=markup>`_
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/include/clang/Basic/DiagnosticSemaKinds.td>`_
|
||||
|
||||
All semantic diagnostics generated for your attribute, including automatically-
|
||||
generated ones (such as subjects and argument counts), should have a
|
||||
|
||||
@@ -16,23 +16,16 @@ Step 0: Obtaining Clang
|
||||
=======================
|
||||
|
||||
As Clang is part of the LLVM project, you'll need to download LLVM's
|
||||
source code first. Both Clang and LLVM are maintained as Subversion
|
||||
repositories, but we'll be accessing them through the git mirror. For
|
||||
further information, see the `getting started
|
||||
guide <https://llvm.org/docs/GettingStarted.html>`_.
|
||||
source code first. Both Clang and LLVM are in the same git repository,
|
||||
under different directories. For further information, see the `getting
|
||||
started guide <https://llvm.org/docs/GettingStarted.html>`_.
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
mkdir ~/clang-llvm && cd ~/clang-llvm
|
||||
git clone https://llvm.org/git/llvm.git
|
||||
cd llvm/tools
|
||||
git clone https://llvm.org/git/clang.git
|
||||
cd clang/tools
|
||||
git clone https://llvm.org/git/clang-tools-extra.git extra
|
||||
cd ~/clang-llvm
|
||||
git clone https://github.com/llvm/llvm-project.git
|
||||
|
||||
Next you need to obtain the CMake build system and Ninja build tool. You
|
||||
may already have CMake installed, but current binary versions of CMake
|
||||
aren't built with Ninja support.
|
||||
Next you need to obtain the CMake build system and Ninja build tool.
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
@@ -57,7 +50,7 @@ Okay. Now we'll build Clang!
|
||||
|
||||
cd ~/clang-llvm
|
||||
mkdir build && cd build
|
||||
cmake -G Ninja ../llvm -DLLVM_BUILD_TESTS=ON # Enable tests; default is off.
|
||||
cmake -G Ninja ../llvm -DLLVM_ENABLE_PROJECTS=clang -DLLVM_BUILD_TESTS=ON # Enable tests; default is off.
|
||||
ninja
|
||||
ninja check # Test LLVM only.
|
||||
ninja clang-test # Test Clang only.
|
||||
@@ -65,9 +58,7 @@ Okay. Now we'll build Clang!
|
||||
|
||||
And we're live.
|
||||
|
||||
All of the tests should pass, though there is a (very) small chance that
|
||||
you can catch LLVM and Clang out of sync. Running ``'git svn rebase'``
|
||||
in both the llvm and clang directories should fix any problems.
|
||||
All of the tests should pass.
|
||||
|
||||
Finally, we want to set Clang as its own compiler.
|
||||
|
||||
|
||||
@@ -196,6 +196,6 @@ with ``-v`` and look at the search paths it looks through.
|
||||
Linking
|
||||
^^^^^^^
|
||||
|
||||
For a list of libraries to link, look at one of the tools' Makefiles (for
|
||||
example `clang-check/Makefile
|
||||
<https://llvm.org/viewvc/llvm-project/cfe/trunk/tools/clang-check/Makefile?view=markup>`_).
|
||||
For a list of libraries to link, look at one of the tools' CMake files (for
|
||||
example `clang-check/CMakeList.txt
|
||||
<https://github.com/llvm/llvm-project/blob/master/clang/tools/clang-check/CMakeLists.txt>`_).
|
||||
|
||||
@@ -229,14 +229,8 @@ of other runtimes.
|
||||
libunwind (LLVM)
|
||||
^^^^^^^^^^^^^^^^
|
||||
|
||||
LLVM's unwinder library can be obtained from subversion:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
llvm-src$ svn co https://llvm.org/svn/llvm-project/libunwind/trunk projects/libunwind
|
||||
|
||||
When checked out into projects/libunwind within an LLVM checkout,
|
||||
it should be automatically picked up by the LLVM build system.
|
||||
LLVM's unwinder library is part of the llvm-project git repository. To
|
||||
build it, pass ``-DLLVM_ENABLE_PROJECTS=libunwind`` to the cmake invocation.
|
||||
|
||||
If using libc++abi, you may need to configure it to use libunwind
|
||||
rather than libgcc_s by passing ``-DLIBCXXABI_USE_LLVM_UNWINDER=YES``
|
||||
|
||||
@@ -431,7 +431,7 @@ public:
|
||||
|
||||
/// Values for bit flags used in the ident_t to describe the fields.
|
||||
/// All enumeric elements are named and described in accordance with the code
|
||||
/// from http://llvm.org/svn/llvm-project/openmp/trunk/runtime/src/kmp.h
|
||||
/// from https://github.com/llvm/llvm-project/blob/master/openmp/runtime/src/kmp.h
|
||||
enum OpenMPLocationFlags : unsigned {
|
||||
/// Use trampoline for internal microtask.
|
||||
OMP_IDENT_IMD = 0x01,
|
||||
@@ -460,7 +460,7 @@ enum OpenMPLocationFlags : unsigned {
|
||||
|
||||
/// Describes ident structure that describes a source location.
|
||||
/// All descriptions are taken from
|
||||
/// http://llvm.org/svn/llvm-project/openmp/trunk/runtime/src/kmp.h
|
||||
/// https://github.com/llvm/llvm-project/blob/master/openmp/runtime/src/kmp.h
|
||||
/// Original structure:
|
||||
/// typedef struct ident {
|
||||
/// kmp_int32 reserved_1; /**< might be used in Fortran;
|
||||
@@ -1477,7 +1477,7 @@ Address CGOpenMPRuntime::getOrCreateDefaultLocation(unsigned Flags) {
|
||||
// Initialize default location for psource field of ident_t structure of
|
||||
// all ident_t objects. Format is ";file;function;line;column;;".
|
||||
// Taken from
|
||||
// http://llvm.org/svn/llvm-project/openmp/trunk/runtime/src/kmp_str.c
|
||||
// https://github.com/llvm/llvm-project/blob/master/openmp/runtime/src/kmp_str.cpp
|
||||
DefaultOpenMPPSource =
|
||||
CGM.GetAddrOfConstantCString(";unknown;unknown;0;0;;").getPointer();
|
||||
DefaultOpenMPPSource =
|
||||
@@ -4965,7 +4965,7 @@ CGOpenMPRuntime::emitTaskInit(CodeGenFunction &CGF, SourceLocation Loc,
|
||||
// kmp_int32 flags, size_t sizeof_kmp_task_t, size_t sizeof_shareds,
|
||||
// kmp_routine_entry_t *task_entry);
|
||||
// Task flags. Format is taken from
|
||||
// http://llvm.org/svn/llvm-project/openmp/trunk/runtime/src/kmp.h,
|
||||
// https://github.com/llvm/llvm-project/blob/master/openmp/runtime/src/kmp.h,
|
||||
// description of kmp_tasking_flags struct.
|
||||
enum {
|
||||
TiedFlag = 0x1,
|
||||
@@ -9888,4 +9888,3 @@ CGOpenMPSIMDRuntime::getParameterAddress(CodeGenFunction &CGF,
|
||||
const VarDecl *TargetParam) const {
|
||||
llvm_unreachable("Not supported in SIMD-only mode");
|
||||
}
|
||||
|
||||
|
||||
@@ -789,11 +789,11 @@ Static Analyzer:
|
||||
<li><a href="http://lcs.ios.ac.cn/~xuzb/canalyze/memmodel.pdf">Xu, Zhongxing &
|
||||
Kremenek, Ted & Zhang, Jian. (2010). A Memory Model for Static Analysis of C
|
||||
Programs.</a></li>
|
||||
<li><a href="https://github.com/llvm-mirror/clang/blob/master/lib/StaticAnalyzer/README.txt">
|
||||
<li><a href="https://github.com/llvm/llvm-project/blob/master/clang/lib/StaticAnalyzer/README.txt">
|
||||
The Clang Static Analyzer README</a></li>
|
||||
<li><a href="https://github.com/llvm-mirror/clang/blob/master/docs/analyzer/RegionStore.txt">
|
||||
<li><a href="https://github.com/llvm/llvm-project/blob/master/clang/docs/analyzer/RegionStore.txt">
|
||||
Documentation for how the Store works</a></li>
|
||||
<li><a href="https://github.com/llvm-mirror/clang/blob/master/docs/analyzer/IPA.txt">
|
||||
<li><a href="https://github.com/llvm/llvm-project/blob/master/clang/docs/analyzer/IPA.txt">
|
||||
Documentation about inlining</a></li>
|
||||
<li> The "Building a Checker in 24 hours" presentation given at the <a
|
||||
href="http://llvm.org/devmtg/2012-11">November 2012 LLVM Developer's
|
||||
|
||||
@@ -30,8 +30,6 @@ bugs in <a href="https://bugs.llvm.org/">LLVM Bugzilla</a>.</p>
|
||||
|
||||
<h3 id="buildNix">On Unix-like Systems</h3>
|
||||
|
||||
<p>Note: as an experimental setup, you can use a <b>single checkout</b> with all the projects, and an <b>easy CMake invocation</b>, see the LLVM Doc "<a href="https://llvm.org/docs/GettingStarted.html#for-developers-to-work-with-a-git-monorepo">For developers to work with a git monorepo</a>"</p>
|
||||
|
||||
<p>If you would like to check out and build Clang, the current procedure is as
|
||||
follows:</p>
|
||||
|
||||
@@ -49,48 +47,18 @@ follows:</p>
|
||||
http://www.cmake.org/download</a></li>
|
||||
</ul>
|
||||
|
||||
<li>Check out LLVM:
|
||||
<li>Check out the LLVM project:
|
||||
<ul>
|
||||
<li>Change directory to where you want the llvm directory placed.</li>
|
||||
<li><tt>svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm</tt></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Check out Clang:
|
||||
<ul>
|
||||
<li><tt>cd llvm/tools</tt></li>
|
||||
<li><tt>svn co http://llvm.org/svn/llvm-project/cfe/trunk clang</tt></li>
|
||||
<li><tt>cd ../..</tt></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Check out extra Clang tools: (optional)
|
||||
<ul>
|
||||
<li><tt>cd llvm/tools/clang/tools</tt></li>
|
||||
<li><tt>svn co http://llvm.org/svn/llvm-project/clang-tools-extra/trunk
|
||||
extra</tt></li>
|
||||
<li><tt>cd ../../../..</tt></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Check out Compiler-RT (optional):
|
||||
<ul>
|
||||
<li><tt>cd llvm/projects</tt></li>
|
||||
<li><tt>svn co http://llvm.org/svn/llvm-project/compiler-rt/trunk
|
||||
compiler-rt</tt></li>
|
||||
<li><tt>cd ../..</tt></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Check out libcxx: (only required to build and run Compiler-RT tests on OS X, optional otherwise)
|
||||
<ul>
|
||||
<li><tt>cd llvm/projects</tt></li>
|
||||
<li><tt>svn co http://llvm.org/svn/llvm-project/libcxx/trunk
|
||||
libcxx</tt></li>
|
||||
<li><tt>cd ../..</tt></li>
|
||||
<li><tt>git clone https://github.com/llvm/llvm-project.git</tt></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Build LLVM and Clang:
|
||||
<ul>
|
||||
<li><tt>cd llvm-project</tt></li>
|
||||
<li><tt>mkdir build</tt> (in-tree build is not supported)</li>
|
||||
<li><tt>cd build</tt></li>
|
||||
<li><tt>cmake -G "Unix Makefiles" ../llvm</tt></li>
|
||||
<li><tt>cmake -DLLVM_ENABLE_PROJECTS=clang -G "Unix Makefiles" ../llvm</tt></li>
|
||||
<li><tt>make</tt></li>
|
||||
<li>This builds both LLVM and Clang for debug mode.</li>
|
||||
<li>Note: For subsequent Clang development, you can just run
|
||||
@@ -127,22 +95,6 @@ follows:</p>
|
||||
</li>
|
||||
</ol>
|
||||
|
||||
<h3>Simultaneously Building Clang and LLVM:</h3>
|
||||
|
||||
<p>Once you have checked out Clang into the llvm source tree it will build along
|
||||
with the rest of <tt>llvm</tt>. To build all of LLVM and Clang together all at
|
||||
once simply run <tt>make</tt> from the root LLVM directory.</p>
|
||||
|
||||
<p>If you encounter problems while building Clang, make sure that your LLVM
|
||||
checkout is at the same revision as your Clang checkout. LLVM's interfaces
|
||||
change over time, and mismatched revisions are not expected to work
|
||||
together. We recommend writing a script to automatically run <tt>svn up</tt> in
|
||||
each repository to keep them synchronized. Alternatively, you may consider using
|
||||
the unofficial
|
||||
<a href="https://llvm.org/docs/GettingStarted.html#for-developers-to-work-with-a-git-monorepo">git monorepo</a>
|
||||
which automatically keeps everything in sync at the same revision and lets you
|
||||
commit changes atomically across multiple LLVM subprojects.</p>
|
||||
|
||||
<h3 id="buildWindows">Using Visual Studio</h3>
|
||||
|
||||
<p>The following details setting up for and building Clang on Windows using
|
||||
@@ -151,9 +103,9 @@ Visual Studio:</p>
|
||||
<ol>
|
||||
<li>Get the required tools:
|
||||
<ul>
|
||||
<li><b>Subversion</b>. Source code control program. Get it from:
|
||||
<a href="https://subversion.apache.org/packages.html">
|
||||
https://subversion.apache.org/packages.html</a></li>
|
||||
<li><b>Git</b>. Source code control program. Get it from:
|
||||
<a href="https://git-scm.com/download">
|
||||
https://git-scm.com/download</a></li>
|
||||
<li><b>CMake</b>. This is used for generating Visual Studio solution and
|
||||
project files. Get it from:
|
||||
<a href="https://cmake.org/download/">
|
||||
@@ -174,19 +126,14 @@ Visual Studio:</p>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li>Check out LLVM:
|
||||
<li>Check out LLVM and Clang:
|
||||
<ul>
|
||||
<li><tt>svn co https://llvm.org/svn/llvm-project/llvm/trunk llvm</tt></li>
|
||||
<li><tt>git clone https://github.com/llvm/llvm-project.git</tt></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>Check out Clang:
|
||||
<ul>
|
||||
<li><tt>cd llvm\tools</tt>
|
||||
<li><tt>svn co https://llvm.org/svn/llvm-project/cfe/trunk clang</tt></li>
|
||||
</ul>
|
||||
<p><em>Note</em>: Some Clang tests are sensitive to the line endings. Ensure
|
||||
that checking out the files does not convert LF line endings to CR+LF.
|
||||
If you use git-svn, make sure your <tt>core.autocrlf</tt> setting is false.</p>
|
||||
<p><em>Note</em>: Some Clang tests are sensitive to the line endings. Ensure
|
||||
that checking out the files does not convert LF line endings to CR+LF. If
|
||||
you're using git on Windows, make sure your <tt>core.autocrlf</tt> setting
|
||||
is false.</p>
|
||||
</li>
|
||||
<li>Run CMake to generate the Visual Studio solution and project files:
|
||||
<ul>
|
||||
@@ -195,7 +142,7 @@ Visual Studio:</p>
|
||||
<li><tt>cd build</tt></li>
|
||||
<li>
|
||||
If you are using Visual Studio 2017:
|
||||
<tt>cmake -G "Visual Studio 15 2017" -A x64 -Thost=x64 ..\llvm</tt><br/>
|
||||
<tt>cmake -DLLVM_ENABLE_PROJECTS=clang -G "Visual Studio 15 2017" -A x64 -Thost=x64 ..\llvm</tt><br/>
|
||||
<tt>-Thost=x64</tt> is required, since the 32-bit linker will run out of memory.
|
||||
</li>
|
||||
<li>To generate x86 binaries instead of x64, pass <tt>-A Win32</tt>.</li>
|
||||
@@ -219,10 +166,6 @@ Visual Studio:</p>
|
||||
on running regression tests on Windows.</li>
|
||||
</ol>
|
||||
|
||||
<p>Note that once you have checked out both llvm and clang, to synchronize
|
||||
to the latest code base, use the <tt>svn update</tt> command in both the
|
||||
llvm and llvm\tools\clang directories, as they are separate repositories.</p>
|
||||
|
||||
<h3 id="buildWindowsNinja">Using Ninja alongside Visual Studio</h3>
|
||||
|
||||
<p>We recommend that developers who want the fastest incremental builds use the
|
||||
|
||||
@@ -89,22 +89,22 @@
|
||||
wrapped <tt>Type*</tt> which you can then dump.</li>
|
||||
<li>For <a href="http://lldb.llvm.org"> <tt>LLDB</tt></a> users there are
|
||||
data formatters for clang data structures in
|
||||
<a href="http://llvm.org/svn/llvm-project/cfe/trunk/utils/ClangDataFormat.py">
|
||||
<tt>utils/ClangDataFormat.py</tt></a>.</li>
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/clang/utils/ClangDataFormat.py">
|
||||
<tt>clang/utils/ClangDataFormat.py</tt></a>.</li>
|
||||
</ul>
|
||||
|
||||
<!--=====================================================================-->
|
||||
<h3 id="debuggingVisualStudio">Debugging using Visual Studio</h3>
|
||||
<!--=====================================================================-->
|
||||
|
||||
<p>The files
|
||||
<a href="http://llvm.org/svn/llvm-project/llvm/trunk/utils/LLVMVisualizers/llvm.natvis">
|
||||
<tt>utils/LLVMVisualizers/llvm.natvis</tt></a> and
|
||||
<a href="http://llvm.org/svn/llvm-project/cfe/trunk/utils/ClangVisualizers/clang.natvis">
|
||||
<tt>utils/ClangVisualizers/clang.natvis</tt></a> provide debugger visualizers
|
||||
<p>The files
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/llvm/utils/LLVMVisualizers/llvm.natvis">
|
||||
<tt>llvm/utils/LLVMVisualizers/llvm.natvis</tt></a> and
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/clang/utils/ClangVisualizers/clang.natvis">
|
||||
<tt>clang/utils/ClangVisualizers/clang.natvis</tt></a> provide debugger visualizers
|
||||
that make debugging of more complex data types much easier.</p>
|
||||
<p>For Visual Studio 2013 only, put the files into
|
||||
<tt>%USERPROFILE%\Documents\Visual Studio 2013\Visualizers</tt> or
|
||||
<p>For Visual Studio 2013 only, put the files into
|
||||
<tt>%USERPROFILE%\Documents\Visual Studio 2013\Visualizers</tt> or
|
||||
create a symbolic link so they update automatically.</p>
|
||||
<p>For later versions of Visual Studio, no installation is required.
|
||||
Note also that later versions of Visual Studio also display better visualizations.</p>
|
||||
|
||||
@@ -43,9 +43,8 @@
|
||||
|
||||
<div class="submenu">
|
||||
<label>The Code</label>
|
||||
<a href="/get_started.html#build">Check Out SVN</a>
|
||||
<a href="http://llvm.org/svn/llvm-project/cfe/trunk/">Browse SVN</a>
|
||||
<a href="http://llvm.org/viewvc/llvm-project/cfe/trunk/">Browse ViewVC</a>
|
||||
<a href="/get_started.html#build">Check Out Sources</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/clang/">Browse Sources</a>
|
||||
<a href="http://clang.llvm.org/doxygen/">doxygen</a>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -30,7 +30,7 @@ __extension__ typedef __int128 __tsan_atomic128;
|
||||
#endif
|
||||
|
||||
// Part of ABI, do not change.
|
||||
// http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/atomic?view=markup
|
||||
// https://github.com/llvm/llvm-project/blob/master/libcxx/include/atomic
|
||||
typedef enum {
|
||||
__tsan_memory_order_relaxed,
|
||||
__tsan_memory_order_consume,
|
||||
|
||||
@@ -199,7 +199,7 @@ __extension__ typedef __int128 a128;
|
||||
#endif
|
||||
|
||||
// Part of ABI, do not change.
|
||||
// http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/atomic?view=markup
|
||||
// https://github.com/llvm/llvm-project/blob/master/libcxx/include/atomic
|
||||
typedef enum {
|
||||
mo_relaxed,
|
||||
mo_consume,
|
||||
|
||||
@@ -109,16 +109,20 @@
|
||||
<h2>Get it and get involved!</h2>
|
||||
<!--=====================================================================-->
|
||||
|
||||
<p>Generally, you need to build LLVM/Clang in order to build compiler-rt. You can
|
||||
either follow the Clang's
|
||||
<a href="http://clang.llvm.org/get_started.html">Getting Started</a> page, or
|
||||
<p>Generally, you need to build LLVM/Clang in order to build compiler-rt. You
|
||||
can build it either together with llvm and clang, or separately.
|
||||
|
||||
<p>To build it together, simply add compiler-rt to the -DLLVM_ENABLE_PROJECTS= option to
|
||||
cmake.
|
||||
|
||||
<p>To build it separately, first
|
||||
<a href="http://llvm.org/docs/CMake.html#quick-start">build LLVM</a>
|
||||
separately to get llvm-config binary, and then run:
|
||||
|
||||
<ul>
|
||||
<li>svn co http://llvm.org/svn/llvm-project/compiler-rt/trunk compiler-rt</li>
|
||||
<li>mkdir build</li>
|
||||
<li>cd build</li>
|
||||
<li>cd llvm-project</li>
|
||||
<li>mkdir build-compiler-rt</li>
|
||||
<li>cd build-compiler-rt</li>
|
||||
<li>cmake ../compiler-rt -DLLVM_CONFIG_PATH=/path/to/llvm-config</li>
|
||||
<li>make</li>
|
||||
</ul>
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
<a href="http://lists.llvm.org/mailman/listinfo/llvm-dev">llvm-dev</a>
|
||||
<a href="http://lists.llvm.org/mailman/listinfo/llvm-commits">llvm-commits</a>
|
||||
<a href="http://llvm.org/bugs/">Bug Reports</a>
|
||||
<a href="http://llvm.org/svn/llvm-project/compiler-rt/trunk/">Browse SVN</a>
|
||||
<a href="http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/compiler-rt/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -43,9 +43,7 @@ support for more targets is welcome.
|
||||
|
||||
<h2>Download</h2>
|
||||
|
||||
<tt>svn checkout http://llvm.org/svn/llvm-project/libclc/trunk libclc</tt> (<a href="http://llvm.org/viewvc/llvm-project/libclc/trunk/">ViewVC</a>)
|
||||
<br>- or -<br>
|
||||
<tt>git clone http://llvm.org/git/libclc.git</tt>
|
||||
<tt>git clone https://github.com/llvm/llvm-project.git</tt> (<a href="https://github.com/llvm/llvm-project/tree/libclc">View sources</a>)
|
||||
|
||||
<h2>Mailing List</h2>
|
||||
|
||||
|
||||
@@ -18,33 +18,10 @@ Xcode 4.2 or later. However if you want to install tip-of-trunk from here
|
||||
|
||||
The basic steps needed to build libc++ are:
|
||||
|
||||
#. Checkout LLVM:
|
||||
|
||||
* ``cd where-you-want-llvm-to-live``
|
||||
* ``svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm``
|
||||
|
||||
#. Checkout libc++:
|
||||
|
||||
* ``cd where-you-want-llvm-to-live``
|
||||
* ``cd llvm/projects``
|
||||
* ``svn co http://llvm.org/svn/llvm-project/libcxx/trunk libcxx``
|
||||
|
||||
#. Checkout libc++abi:
|
||||
|
||||
* ``cd where-you-want-llvm-to-live``
|
||||
* ``cd llvm/projects``
|
||||
* ``svn co http://llvm.org/svn/llvm-project/libcxxabi/trunk libcxxabi``
|
||||
|
||||
#. Configure and build libc++ with libc++abi:
|
||||
|
||||
CMake is the only supported configuration system.
|
||||
|
||||
Clang is the preferred compiler when building and using libc++.
|
||||
|
||||
* ``cd where you want to build llvm``
|
||||
* ``mkdir build``
|
||||
* ``cd build``
|
||||
* ``cmake -G <generator> [options] <path to llvm sources>``
|
||||
#. Checkout and configure LLVM (including libc++ and libc++abi), according to the `LLVM
|
||||
getting started <https://llvm.org/docs/GettingStarted.html>`_ documentation. Make sure
|
||||
to include ``libcxx`` and ``libcxxabi`` in the ``LLVM_ENABLE_PROJECTS`` option passed
|
||||
to CMake.
|
||||
|
||||
For more information about configuring libc++ see :ref:`CMake Options`.
|
||||
|
||||
@@ -71,23 +48,21 @@ The instructions are for building libc++ on
|
||||
FreeBSD, Linux, or Mac using `libc++abi`_ as the C++ ABI library.
|
||||
On Linux, it is also possible to use :ref:`libsupc++ <libsupcxx>` or libcxxrt.
|
||||
|
||||
It is sometimes beneficial to build outside of the LLVM tree. An out-of-tree
|
||||
build would look like this:
|
||||
It is sometimes beneficial to build separately from the full LLVM build. An
|
||||
out-of-tree build would look like this:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
$ cd where-you-want-libcxx-to-live
|
||||
$ # Check out llvm, libc++ and libc++abi.
|
||||
$ ``svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm``
|
||||
$ ``svn co http://llvm.org/svn/llvm-project/libcxx/trunk libcxx``
|
||||
$ ``svn co http://llvm.org/svn/llvm-project/libcxxabi/trunk libcxxabi``
|
||||
$ # Check out the sources (includes everything, but we'll only use libcxx)
|
||||
$ ``git clone https://github.com/llvm/llvm-project.git``
|
||||
$ cd where-you-want-to-build
|
||||
$ mkdir build && cd build
|
||||
$ export CC=clang CXX=clang++
|
||||
$ cmake -DLLVM_PATH=path/to/llvm \
|
||||
$ cmake -DLLVM_PATH=path/to/separate/llvm \
|
||||
-DLIBCXX_CXX_ABI=libcxxabi \
|
||||
-DLIBCXX_CXX_ABI_INCLUDE_PATHS=path/to/libcxxabi/include \
|
||||
path/to/libcxx
|
||||
-DLIBCXX_CXX_ABI_INCLUDE_PATHS=path/to/separate/libcxxabi/include \
|
||||
path/to/llvm-project/libcxx
|
||||
$ make
|
||||
$ make check-libcxx # optional
|
||||
|
||||
|
||||
@@ -190,5 +190,4 @@ Quick Links
|
||||
* `LLVM Bugzilla <https://bugs.llvm.org/>`_
|
||||
* `libcxx-commits Mailing List`_
|
||||
* `libcxx-dev Mailing List`_
|
||||
* `Browse libc++ -- SVN <http://llvm.org/svn/llvm-project/libcxx/trunk/>`_
|
||||
* `Browse libc++ -- ViewVC <http://llvm.org/viewvc/llvm-project/libcxx/trunk/>`_
|
||||
* `Browse libc++ Sources <https://github.com/llvm/llvm-project/tree/master/libcxx/>`_
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -26,8 +26,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/libcxx-dev">libcxx-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/libcxx-commits">libcxx-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-dev">cfe-dev</a>
|
||||
<a href="https://lists.llvm.org/mailman/listinfo/cfe-commits">cfe-commits</a>
|
||||
<a href="https://bugs.llvm.org/">Bug Reports</a>
|
||||
<a href="https://llvm.org/svn/llvm-project/libcxx/trunk/">Browse SVN</a>
|
||||
<a href="https://llvm.org/viewvc/llvm-project/libcxx/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxx/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -26,8 +26,7 @@
|
||||
<a href="http://lists.llvm.org/mailman/listinfo/libcxx-dev">libcxx-dev</a>
|
||||
<a href="http://lists.llvm.org/mailman/listinfo/libcxx-commits">libcxx-commits</a>
|
||||
<a href="http://llvm.org/bugs/">Bug Reports</a>
|
||||
<a href="http://llvm.org/svn/llvm-project/libcxxabi/trunk/">Browse SVN</a>
|
||||
<a href="http://llvm.org/viewvc/llvm-project/libcxxabi/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/libcxxabi/">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -74,29 +73,28 @@
|
||||
<h2>Get it and get involved!</h2>
|
||||
<!--=====================================================================-->
|
||||
|
||||
<p>To check out the code, use:</p>
|
||||
<p>To check out the code (including llvm and others), use:</p>
|
||||
|
||||
<ul>
|
||||
<li><code>svn co http://llvm.org/svn/llvm-project/libcxxabi/trunk libcxxabi</code></li>
|
||||
<li><code>git clone https://github.com/llvm/llvm-project.git</code></li>
|
||||
</ul>
|
||||
|
||||
<p>To build:</p>
|
||||
<ul>
|
||||
<li>Check out libcxxabi into <code>llvm/projects</code></li>
|
||||
<li><code>cd llvm</code></li>
|
||||
<li><code>cd llvm-project</code></li>
|
||||
<li><code>mkdir build && cd build</code></li>
|
||||
<li><code>cmake .. # on linux you may need to prefix with CC=clang CXX=clang++</code></li>
|
||||
<li><code>cmake -DLLVM_ENABLE_PROJECTS=libcxxabi ../llvm # on linux you may need to specify -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++</code></li>
|
||||
<li><code>make</code></li>
|
||||
</ul>
|
||||
|
||||
<p>To do a standalone build:</p>
|
||||
<ul>
|
||||
<li>
|
||||
Check out the <a href="http://libcxx.llvm.org">libcxx source</a> tree.
|
||||
Check out the source tree. This includes the other subprojects, but you'll only use the libcxxabi part.
|
||||
</li>
|
||||
<li><code>cd libcxxabi</code></li>
|
||||
<li><code>mkdir build && cd build</code></li>
|
||||
<li><code>cmake -DLIBCXXABI_LIBCXX_PATH=path/to/libcxx .. # on
|
||||
<li><code>cd llvm-project</code></li>
|
||||
<li><code>mkdir build-libcxxabi && cd build-libcxxabi</code></li>
|
||||
<li><code>cmake -DLIBCXXABI_LIBCXX_PATH=path/to/libcxx ../libcxxabi # on
|
||||
linux you may need -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++</code></li>
|
||||
<li><code>make</code></li>
|
||||
</ul>
|
||||
|
||||
@@ -18,16 +18,10 @@ edge), read on.
|
||||
|
||||
The basic steps needed to build libc++ are:
|
||||
|
||||
#. Checkout LLVM:
|
||||
#. Checkout LLVM, libunwind, and related projects:
|
||||
|
||||
* ``cd where-you-want-llvm-to-live``
|
||||
* ``svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm``
|
||||
|
||||
#. Checkout libunwind:
|
||||
|
||||
* ``cd where-you-want-llvm-to-live``
|
||||
* ``cd llvm/runtimes``
|
||||
* ``svn co http://llvm.org/svn/llvm-project/libunwind/trunk libunwind``
|
||||
* ``git clone https://github.com/llvm/llvm-project.git``
|
||||
|
||||
#. Configure and build libunwind:
|
||||
|
||||
@@ -38,7 +32,7 @@ The basic steps needed to build libc++ are:
|
||||
* ``cd where you want to build llvm``
|
||||
* ``mkdir build``
|
||||
* ``cd build``
|
||||
* ``cmake -G <generator> [options] <path to llvm sources>``
|
||||
* ``cmake -G <generator> -DLLVM_ENABLE_PROJECTS=libunwind [options] <path to llvm sources>``
|
||||
|
||||
For more information about configuring libunwind see :ref:`CMake Options`.
|
||||
|
||||
|
||||
@@ -101,5 +101,4 @@ Quick Links
|
||||
* `LLVM Bugzilla <https://bugs.llvm.org/>`_
|
||||
* `cfe-commits Mailing List`_
|
||||
* `cfe-dev Mailing List`_
|
||||
* `Browse libunwind -- SVN <http://llvm.org/svn/llvm-project/libunwind/trunk/>`_
|
||||
* `Browse libunwind -- ViewVC <http://llvm.org/viewvc/llvm-project/libunwind/trunk/>`_
|
||||
* `Browse libunwind Sources <https://github.com/llvm/llvm-project/blob/master/libunwind/>`_
|
||||
|
||||
@@ -28,23 +28,15 @@ On Unix-like Systems
|
||||
.. _libc++: http://libcxx.llvm.org/
|
||||
.. _Python 2.4: http://python.org/download/
|
||||
|
||||
2. Check out LLVM::
|
||||
2. Check out LLVM and subprojects (including lld)::
|
||||
|
||||
$ cd path/to/llvm-project
|
||||
$ svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
|
||||
|
||||
3. Check out lld::
|
||||
|
||||
$ cd llvm/tools
|
||||
$ svn co http://llvm.org/svn/llvm-project/lld/trunk lld
|
||||
|
||||
* lld can also be checked out to ``path/to/llvm-project`` and built as an external
|
||||
project.
|
||||
$ git clone https://github.com/llvm/llvm-project.git
|
||||
|
||||
4. Build LLVM and lld::
|
||||
|
||||
$ cd path/to/llvm-build/llvm (out of source build required)
|
||||
$ cmake -G "Unix Makefiles" path/to/llvm-project/llvm
|
||||
$ cd llvm-project
|
||||
$ mkdir build && cd build
|
||||
$ cmake -G "Unix Makefiles" -DLLVM_ENABLE_PROJECTS=lld ../llvm
|
||||
$ make
|
||||
|
||||
* If you want to build with clang and it is not the default compiler or
|
||||
@@ -71,23 +63,12 @@ Using Visual Studio
|
||||
.. _Visual Studio 12 (2013) or later: http://www.microsoft.com/visualstudio/11/en-us
|
||||
.. _Python 2.4: http://python.org/download/
|
||||
|
||||
#. Check out LLVM::
|
||||
|
||||
$ cd path/to/llvm-project
|
||||
$ svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm
|
||||
|
||||
#. Check out lld::
|
||||
|
||||
$ cd llvm/tools
|
||||
$ svn co http://llvm.org/svn/llvm-project/lld/trunk lld
|
||||
|
||||
* lld can also be checked out to ``path/to/llvm-project`` and built as an external
|
||||
project.
|
||||
#. Check out LLVM as above.
|
||||
|
||||
#. Generate Visual Studio project files::
|
||||
|
||||
$ cd path/to/llvm-build/llvm (out of source build required)
|
||||
$ cmake -G "Visual Studio 11" path/to/llvm-project/llvm
|
||||
$ cd llvm-project/build (out of source build required)
|
||||
$ cmake -G "Visual Studio 11" -DLLVM_ENABLE_PROJECTS=lld ../llvm
|
||||
|
||||
#. Build
|
||||
|
||||
|
||||
@@ -106,7 +106,7 @@ build that tree. You need `cmake` and of course a C++ compiler.
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ git clone https://github.com/llvm-project/llvm-project-20170507 llvm-project
|
||||
$ git clone https://github.com/llvm/llvm-project llvm-project
|
||||
$ mkdir build
|
||||
$ cd build
|
||||
$ cmake -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_PROJECTS=lld -DCMAKE_INSTALL_PREFIX=/usr/local ../llvm-project/llvm
|
||||
|
||||
@@ -1,51 +0,0 @@
|
||||
This document describes how to build a debug version of LLVM for use with
|
||||
LLDB, and how to make LLDB use it.
|
||||
|
||||
It assumes that you are using the Xcode 3 series (I used 3.2.4) to build
|
||||
LLDB. It also assumes that your shell is /bin/bash, and that you are
|
||||
currently at a shell prompt in a checked-out LLDB repository.
|
||||
|
||||
1. Check out LLVM and Clang from their repositories. To determine
|
||||
the revision to use, consult scripts/build-llvm.pl (this is done
|
||||
in the first command line below). !!! WARNING Do not use the
|
||||
name "llvm" for your checkout, for reasons described in part 3
|
||||
below.
|
||||
|
||||
$ export CLANG_REVISION=`cat scripts/build-llvm.pl | grep ^our.*llvm_revision | cut -d \' -f 2,2`
|
||||
$ svn co -r $CLANG_REVISION http://llvm.org/svn/llvm-project/llvm/trunk llvm.checkout
|
||||
$ svn co -r $CLANG_REVISION http://llvm.org/svn/llvm-project/cfe/trunk llvm.checkout/tools/clang
|
||||
|
||||
2. Configure LLVM/Clang with the proper options and compilers. I use:
|
||||
|
||||
$ cd llvm.checkout
|
||||
$ CC="cc -g -O0" CXX="c++ -g -O0" ./configure --disable-optimized --enable-assertions --enable-targets=x86_64,arm
|
||||
$ CC="cc -g -O0" CXX="c++ -g -O0" make -j 2
|
||||
$ cd ..
|
||||
|
||||
3. Create a link to the built LLVM. !!! WARNING: Do not rename the
|
||||
directory! The LLVM builder script that runs as part of the Xcode
|
||||
build keys off the fact that llvm/ is a symlink to recognize that
|
||||
we are building with a custom debug build.
|
||||
|
||||
$ ln -sf llvm.checkout llvm
|
||||
|
||||
4. Make sure that your Xcode project is set up correctly. Open
|
||||
lldb.xcodeproj and do the following:
|
||||
|
||||
Under "Targets" in the Groups & Files navigator, double-click
|
||||
lldb-tool. In the resulting window, select "Debug" from the
|
||||
"Configuration:" drop-down. Then, make sure that the setting
|
||||
"Build Active Architecture Only" is enabled. Close the window.
|
||||
|
||||
Under "Targets" in the Groups & Files navigator, double-click
|
||||
LLDB. In the resulting window, select "Debug" from the
|
||||
"Configuration:" drop-down. Then, make sure that the setting
|
||||
"Build Active Architecture Only" is enabled. Close the window.
|
||||
|
||||
5. Ensure that Xcode is building the lldb-tool target in Debug
|
||||
configuration for your architecture (typically x86_64). You
|
||||
can usually pick these options from the Overview drop-down at
|
||||
the top left of the Xcode window.
|
||||
|
||||
6. Build lldb.xcodeproj.
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
"""
|
||||
Test that lldb command "command source" works correctly.
|
||||
|
||||
See also http://llvm.org/viewvc/llvm-project?view=rev&revision=109673.
|
||||
"""
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
"""
|
||||
Test that objective-c expression parser continues to work for optimized build.
|
||||
|
||||
http://llvm.org/viewvc/llvm-project?rev=126973&view=rev
|
||||
Fixed a bug in the expression parser where the 'this'
|
||||
or 'self' variable was not properly read if the compiler
|
||||
optimized it into a register.
|
||||
|
||||
@@ -107,7 +107,7 @@ On Mac OS X (under MacVim) , the following key mappings are available:
|
||||
ABOUT *lldb-about*
|
||||
|
||||
Grab the latest version of this plugin (and LLDB sources) with:
|
||||
git clone http://llvm.org/git/lldb
|
||||
git clone https://github.com/llvm/llvm-project.git
|
||||
|
||||
File any bugs at:
|
||||
http://llvm.org/bugs/enter_bug.cgi?product=lldb
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
<div class="postcontent">
|
||||
<p>
|
||||
The LanguageType enum
|
||||
(see <a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/lldb-enumerations.h">lldb-enumerations.h</a>)
|
||||
(see <a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/lldb-enumerations.h">lldb-enumerations.h</a>)
|
||||
contains a list of every language known to LLDB. It is
|
||||
the one place where support for a language must live
|
||||
that will need to merge cleanly with core LLDB if you
|
||||
@@ -72,8 +72,8 @@
|
||||
<h1 class="postheader">Add a TypeSystem for the Language</h1>
|
||||
<div class="postcontent">
|
||||
<p>
|
||||
Both <a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/Core/Module.h">Module</a>
|
||||
and <a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/Target/Target.h">Target</a>
|
||||
Both <a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/Core/Module.h">Module</a>
|
||||
and <a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/Target/Target.h">Target</a>
|
||||
support the retrieval of a TypeSystem instance via
|
||||
GetTypeSystemForLanguage(). For Module, this method is
|
||||
directly on the Module instance. For Target, this is
|
||||
@@ -116,7 +116,7 @@
|
||||
Expression Evaluation support is enabled by implementing
|
||||
the relevant methods on a TypeSystem-derived class.
|
||||
Search for "Expression" in the
|
||||
<a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/Symbol/TypeSystem.h">TypeSystem header</a>
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/Symbol/TypeSystem.h">TypeSystem header</a>
|
||||
to find relevant
|
||||
methods to implement.
|
||||
</p>
|
||||
@@ -160,7 +160,7 @@
|
||||
Your TypeSystem will need an approach for creating types
|
||||
based on a set of Modules. If your type info is going
|
||||
to come from DWARF info, you will want to subclass
|
||||
<a href="http://llvm.org/svn/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/DWARFASTParser.h">DWARFASTParser</a>.
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParser.h">DWARFASTParser</a>.
|
||||
</p>
|
||||
</div>
|
||||
<div class="postfooter"></div>
|
||||
|
||||
@@ -249,48 +249,11 @@
|
||||
</code>
|
||||
<h2>Building LLDB</h2>
|
||||
<p>
|
||||
We first need to checkout the source trees into the appropriate locations. Both
|
||||
Clang and LLDB build as subprojects of LLVM. This means we will be checking out
|
||||
the source for both Clang and LLDB into the <tt>tools</tt> subdirectory of LLVM. We
|
||||
will be setting up a directory hierarchy looking something like this:
|
||||
</p>
|
||||
<p>
|
||||
<pre><tt>
|
||||
llvm
|
||||
|
|
||||
`-- tools
|
||||
|
|
||||
+-- clang
|
||||
|
|
||||
`-- lldb
|
||||
</tt></pre>
|
||||
</p>
|
||||
<p>
|
||||
For reference, we will call the root of the LLVM project tree <tt>$llvm</tt>, and the
|
||||
roots of the Clang and LLDB source trees <tt>$clang</tt> and <tt>$lldb</tt> respectively.
|
||||
</p>
|
||||
<p>Change to the directory where you want to do development work and checkout LLVM:</p>
|
||||
<code>> svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm</code>
|
||||
|
||||
<p>Now switch to LLVM’s tools subdirectory and checkout both Clang and LLDB:</p>
|
||||
<code>
|
||||
> cd $llvm/tools
|
||||
<br />> svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
|
||||
<br />> svn co http://llvm.org/svn/llvm-project/lldb/trunk lldb
|
||||
</code>
|
||||
|
||||
<p>
|
||||
In general, building the LLDB trunk revision requires trunk revisions of both
|
||||
LLVM and Clang.
|
||||
</p>
|
||||
<p>
|
||||
It is highly recommended that you build the system out of tree. Create a second
|
||||
build directory and configure the LLVM project tree to your specifications as
|
||||
outlined in LLVM’s <em>Getting Started Guide</em>. A typical build procedure
|
||||
might be:
|
||||
</p>
|
||||
<code>
|
||||
> cd $llvm/..
|
||||
LLDB requires both LLVM and Clang to build. We first need to checkout the source tree,
|
||||
which contains all three. Change to the directory where you want to do development
|
||||
work and clone the repository:</p>
|
||||
<code>> git clone https://github.com/llvm/llvm-project.git
|
||||
<br />> cd llvm-project
|
||||
<br />> mkdir build
|
||||
<br />> cd build
|
||||
</code>
|
||||
@@ -309,7 +272,7 @@
|
||||
ninja on your system. To build using ninja:
|
||||
</p>
|
||||
<code>
|
||||
> cmake ../llvm -G Ninja
|
||||
> cmake ../llvm -G Ninja -DLLVM_ENABLE_PROJECTS='clang;lldb'
|
||||
<br />> ninja lldb
|
||||
<br />> ninja check-lldb
|
||||
</code>
|
||||
@@ -318,7 +281,7 @@
|
||||
two additional arguments to cmake before running ninja:
|
||||
</p>
|
||||
<code>
|
||||
> cmake ../llvm -G Ninja -DLLDB_EXPORT_ALL_SYMBOLS=1 -DCMAKE_BUILD_TYPE=Debug
|
||||
> cmake ../llvm -G Ninja -DLLVM_ENABLE_PROJECTS='clang;lldb' -DLLDB_EXPORT_ALL_SYMBOLS=1 -DCMAKE_BUILD_TYPE=Debug
|
||||
</code>
|
||||
<h3>Using CMake + Unix Makefiles</h3>
|
||||
<p>If you do not have Ninja, you can still use CMake to generate Unix Makefiles that build LLDB:</p>
|
||||
|
||||
@@ -110,7 +110,7 @@
|
||||
<p>To check out the code, use:</p>
|
||||
|
||||
<ul>
|
||||
<li>svn co http://llvm.org/svn/llvm-project/lldb/trunk lldb</li>
|
||||
<li>git clone https://github.com/llvm/llvm-project.git</li>
|
||||
</ul>
|
||||
|
||||
<p>Note that LLDB generally builds from top-of-trunk</p>
|
||||
|
||||
@@ -515,11 +515,11 @@ Enter your Python command(s). Type 'DONE' to end.
|
||||
its operations. </p>
|
||||
<p>There is a longer discussion of scripted thread plans and the state machine, and several interesting examples
|
||||
of their use in:</p>
|
||||
<a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/python/scripted_step.py">scripted_step.py</a>
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/python/scripted_step.py">scripted_step.py</a>
|
||||
|
||||
<p> And for a MUCH fuller discussion of the whole state machine, see:</p>
|
||||
|
||||
<a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/Target/ThreadPlan.h">ThreadPlan.h</a>
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/Target/ThreadPlan.h">ThreadPlan.h</a>
|
||||
|
||||
<p>If you are reading those comments it is useful to know that scripted thread plans are set to be
|
||||
"MasterPlans", and not "OkayToDiscard".
|
||||
@@ -795,7 +795,7 @@ total 365848
|
||||
</tt></pre></code>
|
||||
<p>A more interesting template has been created in the source repository that can help you to create
|
||||
lldb command quickly:</p>
|
||||
<a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/python/cmdtemplate.py">cmdtemplate.py</a>
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/python/cmdtemplate.py">cmdtemplate.py</a>
|
||||
<p>
|
||||
A commonly required facility is being able to create a command that does some token substitution, and then runs a different debugger command
|
||||
(usually, it po'es the result of an expression evaluated on its argument). For instance, given the following program:
|
||||
|
||||
@@ -160,7 +160,7 @@
|
||||
objects are used, among other things, to wrap up program variables and values.
|
||||
There are many useful methods defined in the SBValue class to allow you to get
|
||||
information or children values out of SBValues. For complete information, see
|
||||
the header file <a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/API/SBValue.h">SBValue.h</a>. The
|
||||
the header file <a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/API/SBValue.h">SBValue.h</a>. The
|
||||
SBValue methods that we use in our DFS function are
|
||||
<code>GetChildMemberWithName()</code>,
|
||||
<code>GetSummary()</code>, and <code>GetValue()</code>.</p>
|
||||
@@ -573,8 +573,8 @@ Process 696 stopped
|
||||
the DFS function and other Python script examples (tree_utils.py) used for this
|
||||
example are available via following file links:</p>
|
||||
|
||||
<a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/scripting/tree_utils.py">tree_utils.py</a> - Example Python functions using LLDB's API, including DFS<br>
|
||||
<a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/scripting/dictionary.c">dictionary.c</a> - Sample dictionary program, with bug<br>
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/scripting/tree_utils.py">tree_utils.py</a> - Example Python functions using LLDB's API, including DFS<br>
|
||||
<a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/scripting/dictionary.c">dictionary.c</a> - Sample dictionary program, with bug<br>
|
||||
|
||||
<p>The text for "Romeo and Juliet" can be obtained from the Gutenberg Project
|
||||
(http://www.gutenberg.org).</p>
|
||||
|
||||
@@ -50,8 +50,7 @@
|
||||
<li><a href="/test.html">Test</a></li>
|
||||
<li><a href="/SB-api-coding-rules.html">SB API Coding Rules</a></li>
|
||||
<li><a href="http://bugs.llvm.org">Bug Reports</a></li>
|
||||
<li><a href="http://llvm.org/svn/llvm-project/lldb/trunk">Browse SVN</a></li>
|
||||
<li><a href="http://llvm.org/viewvc/llvm-project/lldb/trunk">Browse ViewVC</a></li>
|
||||
<li><a href="https://github.com/llvm/llvm-project/tree/master/lldb/">Browse Sources</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -22,23 +22,9 @@
|
||||
<div class="postcontent">
|
||||
<p>Refer to the <a href="http://llvm.org/docs/GettingStarted.html#getting-started-with-llvm">LLVM Getting Started Guide</a>
|
||||
for general instructions on how to check out source. Note that LLDB depends on having a working checkout of LLVM
|
||||
and Clang, so the first step is to download LLVM and Clang sources as described at the above URL. Then you can
|
||||
additionally download the LLDB sources from the following repository URLs.</p>
|
||||
<p><b>SVN Repository</b>: http://llvm.org/svn/llvm-project/lldb/trunk </p>
|
||||
<p><b>Git Clone</b>: http://llvm.org/git/lldb.git </p>
|
||||
<p>
|
||||
For non-Mac platforms, and for MacOSX building with CMake (not Xcode), you should check out your sources to adhere to
|
||||
the following directory structure:
|
||||
<pre><tt>
|
||||
llvm
|
||||
|
|
||||
`-- tools
|
||||
|
|
||||
+-- clang
|
||||
|
|
||||
`-- lldb
|
||||
</tt></pre>
|
||||
</p>
|
||||
and Clang, so the first step is to download and build as described at the above URL. The same repository also
|
||||
contains LLDB.</p>
|
||||
<p><b>Git browser</b>: https://github.com/llvm/llvm-project/tree/master/lldb </p>
|
||||
<p>
|
||||
For MacOSX building from Xcode, simply checkout LLDB and then build from Xcode. The Xcode project will
|
||||
automatically detect that it is a fresh checkout, and checkout LLVM and clang automatically. Unlike other
|
||||
|
||||
@@ -352,8 +352,8 @@ Options:
|
||||
</tt></pre></code>
|
||||
<p>The source for the "symbolication" and "crashlog" modules are available in SVN:</p>
|
||||
<ul>
|
||||
<li><a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/python/symbolication.py">symbolication.py</a></li>
|
||||
<li><a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/python/crashlog.py">crashlog.py</a></li>
|
||||
<li><a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/python/symbolication.py">symbolication.py</a></li>
|
||||
<li><a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/python/crashlog.py">crashlog.py</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="postfooter"></div>
|
||||
|
||||
@@ -870,13 +870,13 @@ def function (valobj,internal_dict):<br/>
|
||||
|
||||
<p><code>internal_dict</code> is an internal support parameter used by LLDB and you should
|
||||
not touch it.<br/><code>valobj</code> is the object encapsulating the actual
|
||||
variable being displayed, and its type is <a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/API/SBValue.h">SBValue</a>.
|
||||
variable being displayed, and its type is <a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/API/SBValue.h">SBValue</a>.
|
||||
Out of the many possible operations on an SBValue, the basic one is retrieve the children objects
|
||||
it contains (essentially, the fields of the object wrapped by it), by calling
|
||||
<code>GetChildMemberWithName()</code>, passing it the child's name as a string.<br/>
|
||||
If the variable has a value, you can ask for it, and return it as a string using <code>GetValue()</code>,
|
||||
or as a signed/unsigned number using <code>GetValueAsSigned()</code>, <code>GetValueAsUnsigned()</code>.
|
||||
It is also possible to retrieve an <a href="http://llvm.org/svn/llvm-project/lldb/trunk/include/lldb/API/SBData.h"><code>SBData</code></a> object by calling <code>GetData()</code> and then read
|
||||
It is also possible to retrieve an <a href="https://github.com/llvm/llvm-project/blob/master/lldb/include/lldb/API/SBData.h"><code>SBData</code></a> object by calling <code>GetData()</code> and then read
|
||||
the object's contents out of the <code>SBData</code>.
|
||||
|
||||
<p>If you need to delve into several levels of hierarchy, as you can do with summary
|
||||
@@ -957,7 +957,7 @@ def function (valobj,internal_dict):<br/>
|
||||
matching. </p>
|
||||
<p>One of the ways LLDB uses this feature internally, is to match
|
||||
the names of STL container classes, regardless of the template
|
||||
arguments provided. The details for this are found at <a href="http://llvm.org/svn/llvm-project/lldb/trunk/source/DataFormatters/FormatManager.cpp">FormatManager.cpp</a></p>
|
||||
arguments provided. The details for this are found at <a href="https://github.com/llvm/llvm-project/blob/master/lldb/source/DataFormatters/FormatManager.cpp">FormatManager.cpp</a></p>
|
||||
|
||||
<p>The regular expression language used by LLDB is the <a href="http://en.wikipedia.org/wiki/Regular_expression#POSIX_Extended_Regular_Expressions">POSIX extended language</a>, as defined by the <a href="http://pubs.opengroup.org/onlinepubs/7908799/xsh/regex.h.html">Single UNIX Specification</a>, of which Mac OS X is a
|
||||
compliant implementation.
|
||||
@@ -1069,9 +1069,9 @@ def function (valobj,internal_dict):<br/>
|
||||
<br/>
|
||||
<sup>[3]</sup> This method is optional (starting with SVN revision 219330). The SBValue you return here will most likely be a numeric type (int, float, ...) as its value bytes will be used as-if they were the value of the root SBValue proper. As a shortcut for this, you can inherit from lldb.SBSyntheticValueProvider, and just define get_value as other methods are defaulted in the superclass as returning default no-children responses.
|
||||
<p>If a synthetic child provider supplies a special child named <code>$$dereference$$</code> then it will be used when evaluating <code>opertaor*</code> and <code>operator-></code> in the <code>frame variable</code> command and related SB API functions.</p>
|
||||
<p>For examples of how synthetic children are created, you are encouraged to look at <a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/synthetic/">examples/synthetic</a> in the LLDB trunk. Please, be aware that the code in those files (except bitfield/)
|
||||
<p>For examples of how synthetic children are created, you are encouraged to look at <a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/synthetic/">examples/synthetic</a> in the LLDB sources. Please, be aware that the code in those files (except bitfield/)
|
||||
is legacy code and is not maintained.
|
||||
You may especially want to begin looking at <a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/synthetic/bitfield">this example</a> to get
|
||||
You may especially want to begin looking at <a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/synthetic/bitfield/">this example</a> to get
|
||||
a feel for this feature, as it is a very easy and well commented example.</p>
|
||||
The design pattern consistently used in synthetic providers shipping with LLDB
|
||||
is to use the <code>__init__</code> to store the SBValue instance as a part of <code>self</code>. The <code>update</code> function is then used
|
||||
@@ -1206,7 +1206,7 @@ By default, LLDB will not show you the real type of the object. it can actually
|
||||
Because LLDB uses a detection algorithm that does not need to invoke any functions
|
||||
on the target process, <code>no-run-target</code> is enough for this to work.</p>
|
||||
As a side note, the summary for NSString shown in the example is built right into LLDB.
|
||||
It was initially implemented through Python (the code is still available for reference at <a href="http://llvm.org/svn/llvm-project/lldb/trunk/examples/summaries/cocoa/CFString.py">CFString.py</a>).
|
||||
It was initially implemented through Python (the code is still available for reference at <a href="https://github.com/llvm/llvm-project/blob/master/lldb/examples/summaries/cocoa/CFString.py">CFString.py</a>).
|
||||
However, this is out of sync with the current implementation of the NSString formatter (which is a C++ function compiled into the LLDB core).
|
||||
</p>
|
||||
</div>
|
||||
@@ -1281,9 +1281,7 @@ By default, LLDB will not show you the real type of the object. it can actually
|
||||
<div class="post">
|
||||
<h1 class="postheader">Finding formatters 101</h1>
|
||||
<div class="postcontent">
|
||||
<p>Searching for a formatter
|
||||
(including formats, starting in SVN rev <a href="http://llvm.org/viewvc/llvm-project?view=revision&revision=192217">r192217</a>)
|
||||
given a variable goes through
|
||||
<p>Searching for a formatter given a variable goes through
|
||||
a rather intricate set of rules. Namely, what happens is that LLDB
|
||||
starts looking in each enabled category, according to the order in which
|
||||
they were enabled (latest enabled first). In each category, LLDB does
|
||||
|
||||
@@ -38,20 +38,14 @@ a sufficiently new CMake or C++ toolchain.
|
||||
|
||||
To build and install llgo:
|
||||
|
||||
# Checkout LLVM:
|
||||
svn co http://llvm.org/svn/llvm-project/llvm/trunk /path/to/llvm
|
||||
|
||||
# Checkout Clang:
|
||||
cd /path/to/llvm/tools
|
||||
svn co http://llvm.org/svn/llvm-project/cfe/trunk clang
|
||||
|
||||
# Checkout llgo:
|
||||
svn co http://llvm.org/svn/llvm-project/llgo/trunk llgo
|
||||
# Checkout llvm project.
|
||||
git clone https://github.com/llvm/llvm-project.git
|
||||
|
||||
# Build LLVM, Clang and llgo: (see also http://llvm.org/docs/CMake.html)
|
||||
mkdir /path/to/llvm-build
|
||||
cd /path/to/llvm-build
|
||||
cmake /path/to/llvm -DCMAKE_INSTALL_PREFIX=/path/to/llvm-inst
|
||||
cd llvm-project
|
||||
mkdir build
|
||||
cd build
|
||||
cmake ../llvm -DLLVM_ENABLE_PROJECTS='clang;llgo' -DCMAKE_INSTALL_PREFIX=/path/to/llvm-inst
|
||||
make install
|
||||
|
||||
Running
|
||||
|
||||
@@ -143,9 +143,9 @@ device side.
|
||||
----------------------------
|
||||
|
||||
In clang, ``math.h`` and ``cmath`` are available and `pass
|
||||
<https://github.com/llvm-mirror/test-suite/blob/master/External/CUDA/math_h.cu>`_
|
||||
<https://github.com/llvm/llvm-test-suite/blob/master/External/CUDA/math_h.cu>`_
|
||||
`tests
|
||||
<https://github.com/llvm-mirror/test-suite/blob/master/External/CUDA/cmath.cu>`_
|
||||
<https://github.com/llvm/llvm-test-suite/blob/master/External/CUDA/cmath.cu>`_
|
||||
adapted from libc++'s test suite.
|
||||
|
||||
In nvcc ``math.h`` and ``cmath`` are mostly available. Versions of ``::foof``
|
||||
|
||||
@@ -544,7 +544,7 @@ Periodically restart both fuzzers so that they can use each other's findings.
|
||||
Currently, there is no simple way to run both fuzzing engines in parallel while sharing the same corpus dir.
|
||||
|
||||
You may also use AFL on your target function ``LLVMFuzzerTestOneInput``:
|
||||
see an example `here <https://github.com/llvm-mirror/compiler-rt/tree/master/lib/fuzzer/afl>`__.
|
||||
see an example `here <https://github.com/llvm/llvm-project/tree/master/compiler-rt/lib/fuzzer/afl>`__.
|
||||
|
||||
How good is my fuzzer?
|
||||
----------------------
|
||||
@@ -741,7 +741,7 @@ Trophies
|
||||
.. _AddressSanitizer: http://clang.llvm.org/docs/AddressSanitizer.html
|
||||
.. _LeakSanitizer: http://clang.llvm.org/docs/LeakSanitizer.html
|
||||
.. _Heartbleed: http://en.wikipedia.org/wiki/Heartbleed
|
||||
.. _FuzzerInterface.h: https://github.com/llvm-mirror/compiler-rt/blob/master/lib/fuzzer/FuzzerInterface.h
|
||||
.. _FuzzerInterface.h: https://github.com/llvm/llvm-project/blob/master/compiler-rt/lib/fuzzer/FuzzerInterface.h
|
||||
.. _3.7.0: http://llvm.org/releases/3.7.0/docs/LibFuzzer.html
|
||||
.. _building Clang from trunk: http://clang.llvm.org/get_started.html
|
||||
.. _MemorySanitizer: http://clang.llvm.org/docs/MemorySanitizer.html
|
||||
|
||||
@@ -27,7 +27,7 @@ Quickstart
|
||||
2. Check out the `test-suite` module with:
|
||||
|
||||
```bash
|
||||
% svn co http://llvm.org/svn/llvm-project/test-suite/trunk test-suite
|
||||
% git clone https://github.com/llvm/llvm-test-suite.git test-suite
|
||||
```
|
||||
|
||||
3. Create a build directory and use CMake to configure the suite. Use the
|
||||
|
||||
@@ -14,14 +14,14 @@ the test suite creates temporary files during execution.
|
||||
|
||||
To run the test suite, you need to use the following steps:
|
||||
|
||||
#. ``cd`` into the ``llvm/projects`` directory in your source tree.
|
||||
#. Check out the ``test-suite`` module with:
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
% svn co http://llvm.org/svn/llvm-project/test-suite/trunk test-suite
|
||||
% git clone https://github.com/llvm/llvm-test-suite.git test-suite
|
||||
|
||||
This will get the test suite into ``llvm/projects/test-suite``.
|
||||
#. FIXME: these directions are outdated and won't work. Figure out
|
||||
what the correct thing to do is, and write it down here.
|
||||
|
||||
#. Configure and build ``llvm``.
|
||||
|
||||
|
||||
@@ -165,15 +165,9 @@ or the :doc:`lit man page <CommandGuide/lit>`.
|
||||
Debugging Information tests
|
||||
---------------------------
|
||||
|
||||
To run debugging information tests simply checkout the tests inside
|
||||
clang/test directory.
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
% cd clang/test
|
||||
% svn co http://llvm.org/svn/llvm-project/debuginfo-tests/trunk debuginfo-tests
|
||||
|
||||
These tests are already set up to run as part of clang regression tests.
|
||||
To run debugging information tests simply add the ``debuginfo-tests``
|
||||
project to your ``LLVM_ENABLE_PROJECTS`` define on the cmake
|
||||
command-line.
|
||||
|
||||
Regression test structure
|
||||
=========================
|
||||
|
||||
@@ -4319,7 +4319,7 @@ bool TargetLowering::expandFP_TO_SINT(SDNode *Node, SDValue &Result,
|
||||
|
||||
// Expand f32 -> i64 conversion
|
||||
// This algorithm comes from compiler-rt's implementation of fixsfdi:
|
||||
// https://github.com/llvm-mirror/compiler-rt/blob/master/lib/builtins/fixsfdi.c
|
||||
// https://github.com/llvm/llvm-project/blob/master/compiler-rt/lib/builtins/fixsfdi.c
|
||||
unsigned SrcEltBits = SrcVT.getScalarSizeInBits();
|
||||
EVT IntVT = SrcVT.changeTypeToInteger();
|
||||
EVT IntShVT = getShiftAmountTy(IntVT, DAG.getDataLayout());
|
||||
|
||||
@@ -211,14 +211,14 @@ public:
|
||||
|
||||
const char* getTargetNodeName(unsigned Opcode) const override;
|
||||
|
||||
// FIXME: Turn off MergeConsecutiveStores() before Instruction Selection
|
||||
// for AMDGPU.
|
||||
// A commit ( git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@319036
|
||||
// 91177308-0d34-0410-b5e6-96231b3b80d8 ) turned on
|
||||
// MergeConsecutiveStores() before Instruction Selection for all targets.
|
||||
// Enough AMDGPU compiles go into an infinite loop ( MergeConsecutiveStores()
|
||||
// merges two stores; LegalizeStoreOps() un-merges; MergeConsecutiveStores()
|
||||
// re-merges, etc. ) to warrant turning it off for now.
|
||||
// FIXME: Turn off MergeConsecutiveStores() before Instruction Selection for
|
||||
// AMDGPU. Commit r319036,
|
||||
// (https://github.com/llvm/llvm-project/commit/db77e57ea86d941a4262ef60261692f4cb6893e6)
|
||||
// turned on MergeConsecutiveStores() before Instruction Selection for all
|
||||
// targets. Enough AMDGPU compiles go into an infinite loop (
|
||||
// MergeConsecutiveStores() merges two stores; LegalizeStoreOps() un-merges;
|
||||
// MergeConsecutiveStores() re-merges, etc. ) to warrant turning it off for
|
||||
// now.
|
||||
bool mergeStoresAfterLegalization() const override { return false; }
|
||||
|
||||
bool isFsqrtCheap(SDValue Operand, SelectionDAG &DAG) const override {
|
||||
|
||||
@@ -56,7 +56,7 @@ attributes #3 = { nounwind }
|
||||
!llvm.module.flags = !{!29, !30}
|
||||
!llvm.ident = !{!31}
|
||||
|
||||
!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.8.0 (git://github.com/llvm-mirror/clang.git e0848b6353721eb1b278a5bbea257bbf6316251e) (git://github.com/llvm-mirror/llvm.git 8724a428dfd5e78d7865bb01783708e83f9ed128)", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, retainedTypes: !3, globals: !23)
|
||||
!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.8.0", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, retainedTypes: !3, globals: !23)
|
||||
!1 = !DIFile(filename: "testcase.i", directory: "/tmp/glibc.build")
|
||||
!2 = !{}
|
||||
!3 = !{!4}
|
||||
@@ -86,7 +86,7 @@ attributes #3 = { nounwind }
|
||||
!28 = !DISubrange(count: 23)
|
||||
!29 = !{i32 2, !"Dwarf Version", i32 4}
|
||||
!30 = !{i32 2, !"Debug Info Version", i32 3}
|
||||
!31 = !{!"clang version 3.8.0 (git://github.com/llvm-mirror/clang.git e0848b6353721eb1b278a5bbea257bbf6316251e) (git://github.com/llvm-mirror/llvm.git 8724a428dfd5e78d7865bb01783708e83f9ed128)"}
|
||||
!31 = !{!"clang version 3.8.0"}
|
||||
!32 = !DILocation(line: 21, column: 32, scope: !33)
|
||||
!33 = distinct !DILexicalBlock(scope: !6, file: !1, line: 21, column: 6)
|
||||
!34 = !DILocation(line: 22, column: 15, scope: !35)
|
||||
|
||||
@@ -52,8 +52,8 @@ Command Guide: http://llvm.org/cmds/lit.html.
|
||||
Source
|
||||
======
|
||||
|
||||
The *lit* source is available as part of LLVM, in the LLVM SVN repository:
|
||||
http://llvm.org/svn/llvm-project/llvm/trunk/utils/lit.
|
||||
The *lit* source is available as part of LLVM, in the LLVM source repository:
|
||||
https://github.com/llvm/llvm-project/tree/master/llvm/utils/lit
|
||||
""",
|
||||
|
||||
classifiers=[
|
||||
|
||||
@@ -25,8 +25,7 @@
|
||||
<a href="http://lists.llvm.org/mailman/listinfo/openmp-dev">openmp-dev</a>
|
||||
<a href="http://lists.llvm.org/mailman/listinfo/openmp-commits">openmp-commits</a>
|
||||
<a href="http://llvm.org/bugs/">Bug Reports</a>
|
||||
<a href="http://llvm.org/svn/llvm-project/openmp/trunk/">Browse SVN</a>
|
||||
<a href="http://llvm.org/viewvc/llvm-project/openmp/trunk/">Browse ViewVC</a>
|
||||
<a href="https://github.com/llvm/llvm-project/openmp">Browse Sources</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -154,30 +153,22 @@
|
||||
<p>To check out the code, use:</p>
|
||||
|
||||
<ul>
|
||||
<li><code>svn co http://llvm.org/svn/llvm-project/openmp/trunk openmp</code></li>
|
||||
<li><code>git clone https://github.com/llvm/llvm-project.git</code></li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
Note that for an in-tree build, you should check out openmp to llvm/projects.
|
||||
</p>
|
||||
|
||||
<p>In-tree build:</p>
|
||||
<ul>
|
||||
<li><code>cd where-you-want-to-live</code></li>
|
||||
<li>Check out openmp into llvm/projects</li>
|
||||
<li><code>cd where-you-want-to-build</code></li>
|
||||
<li><code>cd llvm-project</code></li>
|
||||
<li><code>mkdir build && cd build</code></li>
|
||||
<li><code>cmake path/to/llvm -DCMAKE_C_COMPILER=<C compiler> -DCMAKE_CXX_COMPILER=<C++ compiler></code></li>
|
||||
<li><code>cmake ../llvm -DLLVM_ENABLE_PROJECTS=openmp -DCMAKE_C_COMPILER=<C compiler> -DCMAKE_CXX_COMPILER=<C++ compiler></code></li>
|
||||
<li><code>make omp</code></li>
|
||||
</ul>
|
||||
|
||||
<p>Out-of-tree build:</p>
|
||||
<ul>
|
||||
<li><code>cd where-you-want-to-live</code></li>
|
||||
<li>Check out openmp</li>
|
||||
<li><code>cd where-you-want-to-live/openmp</code></li>
|
||||
<li><code>mkdir build && cd build</code></li>
|
||||
<li><code>cmake path/to/openmp -DCMAKE_C_COMPILER=<C compiler> -DCMAKE_CXX_COMPILER=<C++ compiler></code></li>
|
||||
<li><code>cd llvm-project</code></li>
|
||||
<li><code>mkdir build-openmp && cd build-openmp</code></li>
|
||||
<li><code>cmake ../openmp -DCMAKE_C_COMPILER=<C compiler> -DCMAKE_CXX_COMPILER=<C++ compiler></code></li>
|
||||
<li><code>make</code></li>
|
||||
</ul>
|
||||
|
||||
|
||||
@@ -47,7 +47,7 @@ version history is the standard approach to identify the commit that introduced
|
||||
the regression.
|
||||
|
||||
LLVM has a single repository that contains all projects. It can be cloned at:
|
||||
`<https://github.com/llvm-project/llvm-project-20170507>`_. How to bisect on a
|
||||
`<https://github.com/llvm/llvm-project>`_. How to bisect on a
|
||||
git repository is explained here
|
||||
`<https://www.metaltoad.com/blog/beginners-guide-git-bisect-process-elimination>`_.
|
||||
The bisect process can also be automated as explained here:
|
||||
|
||||
@@ -33,20 +33,14 @@ chmod +x polly.sh
|
||||
<h2> Manual </h2>
|
||||
<h3 id="source"> Get the code </h3>
|
||||
|
||||
<p><b>Warning:</b> Polly/LLVM/clang need to be checked out at the same time.</p>
|
||||
|
||||
<pre>
|
||||
git clone http://llvm.org/git/llvm.git llvm_git
|
||||
git clone http://llvm.org/git/polly.git llvm_git/tools/polly
|
||||
|
||||
# Also build the matching clang-version (optional)
|
||||
git clone http://llvm.org/git/clang.git llvm_git/tools/clang
|
||||
git clone http://github.com/llvm/llvm-project.git llvm_git
|
||||
</pre>
|
||||
<h3 id="build">Build Polly</h3>
|
||||
|
||||
<pre>
|
||||
mkdir llvm_build && cd llvm_build
|
||||
cmake ../llvm_git && make
|
||||
cmake -DLLVM_ENABLE_PROJECTS='polly;clang' ../llvm_git/llvm && make
|
||||
</pre>
|
||||
|
||||
<h3> Test Polly</h3>
|
||||
@@ -59,7 +53,7 @@ also building LLVM. All you need is an installed version of LLVM or a previous
|
||||
build. To configure Polly to use a pre-built LLVM, set the
|
||||
<code>-DCMAKE_PREFIX_PATH</code> option:
|
||||
|
||||
<pre>cmake -DCMAKE_PREFIX_PATH=${LLVM_PREFIX}/lib/cmake/llvm</pre>
|
||||
<pre>cmake -DCMAKE_PREFIX_PATH=${LLVM_PREFIX}/lib/cmake/llvm ../llvm_git/polly</pre>
|
||||
|
||||
To run unittests, however, you need to have the LLVM source directory around.
|
||||
Polly will use the <code>llvm-config</code> of the LLVM you're building against
|
||||
|
||||
@@ -34,7 +34,7 @@ Optimizations</span></h2>
|
||||
<a href="http://lab.llvm.org:8080/coverage/coverage-reports/polly/index.html">Code Coverage</a>
|
||||
<a href="http://llvm.org/reports/scan-build/">Static analysis</a>
|
||||
<a href="/doxygen/">Doxygen</a>
|
||||
<a href="https://github.com/llvm-mirror/polly">Source @ GitHub</a>
|
||||
<a href="https://github.com/llvm/llvm-project/tree/master/polly">Source @ GitHub</a>
|
||||
</div>
|
||||
|
||||
<div class="submenu">
|
||||
|
||||
@@ -411,12 +411,6 @@ href="http://llvm.org/svn/llvm-project/polly"
|
||||
>http://llvm.org/svn/llvm-project/polly</a>
|
||||
</td><td> Tobias
|
||||
|
||||
</td></tr>
|
||||
<tr>
|
||||
<th align="left"> Git mirror
|
||||
</th><td class="done" align="center">
|
||||
git://llvm.org/git/polly.git
|
||||
</td><td> Tobias
|
||||
</td></tr>
|
||||
<tr>
|
||||
<th align="left"> Commit mails
|
||||
|
||||
Reference in New Issue
Block a user