Commit Graph

821 Commits

Author SHA1 Message Date
Jordan Rose 8dddf8ff20 [analyzer] Fix copy-paste error in internal docs.
Patch by Jared Grubb!

llvm-svn: 190651
2013-09-13 00:44:57 +00:00
Roman Divacky 786d32ecf7 Clarify the status of PowerPC support.
llvm-svn: 190533
2013-09-11 17:12:49 +00:00
Daniel Jasper 97292843d0 Support for modular module-map-files
This patch is the first step to make module-map-files modular (instead
of requiring a single "module.map"-file per include directory). This
step adds a new "extern module" declaration that enables
module-map-files to reference one another along with a very basic
implementation.

The next steps are:

* Combine this with the use-declaration (from
  http://llvm-reviews.chandlerc.com/D1546) in order to only load module
  map files required for a specific compilation.
* Add an additional flag to start with a specific module-map-file (instead
  of requiring there to be at least one "module.map").

Review: http://llvm-reviews.chandlerc.com/D1637
llvm-svn: 190497
2013-09-11 07:20:44 +00:00
Nico Rieck 7857d46c64 Add -fansi-escape-codes option
Some build systems use pipes for stdin/stderr. On nix-ish platforms colored
output can be forced by -fcolor-diagnostics. On Windows this option has
no effect in these cases because LLVM uses the console API (which only
operates on the console buffer) even if a console wrapper capable of
interpreting ANSI escape codes is used.

The -fansi-escape-codes option allows switching from the console API to
ANSI escape codes. It has no effect on other platforms.

llvm-svn: 190464
2013-09-11 00:38:02 +00:00
Hans Wennborg 9f6581bb88 Allow _clang-format as alternative to .clang-format config filename
Dotfiles are impractical on Windows. This makes clang-format search
for the style configuration file as '_clang-format' in addition to
the usual '.clang-format'. This is similar to how VIM searches for
'_vimrc' on Windows.

Differential Revision: http://llvm-reviews.chandlerc.com/D1629

llvm-svn: 190413
2013-09-10 15:41:12 +00:00
Sean Silva 98c64d4dca [docs] Prominently note modules are experimental.
It was really hard to tell that modules are experimental. This makes it
really clear by

* Noting the experimental status in the title.
* Moving the "warning" above the table of contents.

llvm-svn: 190340
2013-09-09 19:57:49 +00:00
Sean Silva fcb46a0dec [docs] End users should see just "Clang"
Half the internet has wildly incorrect ideas about what LLVM is (in
particular, many get the impression that LLVM is some magical
cross-platform runtime), so saying "LLVM" near "cross-compilation" in a
user-facing doc might provoke confusion.

llvm-svn: 190338
2013-09-09 19:50:47 +00:00
Sean Silva 3c53673b50 [docs] Fix Sphinx toctree warning.
Last I heard LSan is getting close to prime-time, but for now keep
LeakSanitizer.rst hidden (especially since it contains so little
content).

llvm-svn: 190337
2013-09-09 19:50:46 +00:00
Sean Silva a928c24984 [docs] Fix some finicky Sphinx warnings.
llvm-svn: 190336
2013-09-09 19:50:40 +00:00
Sean Silva 7a8b6ca2d1 [docs] Typographical and rewording fixes.
llvm-svn: 190333
2013-09-09 19:30:44 +00:00
Benjamin Kramer 60509af49a Fix constructor-related typos.
Noticed by Roman Divacky.

llvm-svn: 190311
2013-09-09 14:48:42 +00:00
Renato Golin f70e35ddc4 Adding cross-compilation instructions to Clang
llvm-svn: 190281
2013-09-08 20:44:39 +00:00
Reid Kleckner 725b7b3786 manual: Fix RST reference to MS extension support
llvm-svn: 190101
2013-09-05 21:29:35 +00:00
Alexander Kornienko 472d27aa22 A minor fix in the documentation.
llvm-svn: 189947
2013-09-04 15:14:18 +00:00
Alexander Kornienko d278e0eee3 Added documentation for clang-format style options.
Summary:
The main contents is in the ClangFormatStyleOptions.rst, which can be
updated from the Format.h by the dump_format_style.py script.

Reviewers: djasper, klimek

Reviewed By: klimek

CC: cfe-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D1597

llvm-svn: 189946
2013-09-04 15:09:13 +00:00
Alexander Kornienko e3648fbe1a Added WebKit style to the BasedOnStyle handling and to the relevant help messages.
llvm-svn: 189765
2013-09-02 16:39:23 +00:00
Alexander Kornienko d83adf30c6 Whitespace changes in help messages + updated help output in .rst file.
llvm-svn: 189762
2013-09-02 15:30:26 +00:00
Michael Gottesman 043c53b5a8 [doxygen] Add a few missing variables to the doxygen.cfg.in for external search and cleaned up external_search_map.
llvm-svn: 189523
2013-08-28 21:55:41 +00:00
Michael Gottesman 22a351d314 [doxygen] Added support for doxygen external search.
llvm-svn: 189509
2013-08-28 20:29:44 +00:00
Michael Gottesman 8f897af39c [doxygen] Added code for generating doxygen documentation for clang for cmake.
llvm-svn: 189508
2013-08-28 20:29:40 +00:00
Ted Kremenek 1aab6834fa Remove comment on the availability of boxed expressions. They have been available for a while.
llvm-svn: 189446
2013-08-28 06:03:59 +00:00
Samuel Benzaquen 85ec25d21c Rewrite eachOf/allOf/anyOf to use a variadic operator.
Summary:
Rewrite eachOf/allOf/anyOf to use a variadic operator, instead of hand-written calls to Polymorphic matchers.
This simplifies their definition and future changes to add them to the dynamic registry.

Reviewers: klimek

CC: cfe-commits, revane

Differential Revision: http://llvm-reviews.chandlerc.com/D1427

llvm-svn: 189357
2013-08-27 15:11:16 +00:00
Shuxin Yang 0e61122bb3 Add note about following two commands are no longer equivalent.
- "clang -O3 -flto a.c -c", and 
 - "clang -emit-llvm a.c -c" 

Thank Rafael for tips.

llvm-svn: 189150
2013-08-23 22:01:03 +00:00
Rafael Espindola 493f045e75 Don't imply -flto with -O4.
We now saturate at -O3.

llvm-svn: 189149
2013-08-23 21:49:00 +00:00
DeLesley Hutchins c2ecf0d815 Update to consumed analysis.
Patch by chris.wailes@gmail.com.  The following functionality was added:

* The same functionality is now supported for both CXXOperatorCallExprs and CXXMemberCallExprs.
* Factored out some code in StmtVisitor.
* Removed variables from the state map when their destructors are encountered.
* Started adding documentation for the consumed analysis attributes.

llvm-svn: 189059
2013-08-22 20:44:47 +00:00
Peter Collingbourne 730f3c8574 DataFlowSanitizer: Add a design doc paragraph on checking ABI consistency.
Differential Revision: http://llvm-reviews.chandlerc.com/D1443

llvm-svn: 189055
2013-08-22 20:08:20 +00:00
Samuel Benzaquen bd7d887f18 Refactor ArgumentAdaptativeMatcher matchers to remove the template from their declaration.
Summary:
Refactor ArgumentAdaptativeMatcher matchers to remove the template from their declaration.
This facilitates dynamic registration. Change the registry code to use the regular overload resolution mechanism for adaptative matchers.

Reviewers: klimek

CC: cfe-commits, revane

Differential Revision: http://llvm-reviews.chandlerc.com/D1402

llvm-svn: 188560
2013-08-16 16:19:42 +00:00
Evgeniy Stepanov fd75a2ca37 Update sanitizer attribute documentation to match behaviour change in r187967.
llvm-svn: 188459
2013-08-15 13:57:11 +00:00
Peter Collingbourne 276be3c57c Add support for -fsanitize-blacklist and default blacklists for DFSan.
Also add some documentation.

Differential Revision: http://llvm-reviews.chandlerc.com/D1346

llvm-svn: 188403
2013-08-14 18:54:18 +00:00
Richard Trieu 98ca59ed3b Fix typo in template diffing docs.
llvm-svn: 188120
2013-08-09 22:52:48 +00:00
Peter Collingbourne c377275a4a DataFlowSanitizer; Clang changes.
DataFlowSanitizer is a generalised dynamic data flow analysis.

Unlike other Sanitizer tools, this tool is not designed to detect a
specific class of bugs on its own.  Instead, it provides a generic
dynamic data flow analysis framework to be used by clients to help
detect application-specific issues within their own code.

Differential Revision: http://llvm-reviews.chandlerc.com/D966

llvm-svn: 187925
2013-08-07 22:47:34 +00:00
Alexey Samsonov 2de6833809 Documentation for sanitizer special case list format and -f(no-)?sanitize-blacklist flag
llvm-svn: 187871
2013-08-07 08:23:32 +00:00
Daniel Jasper 07e6c407bc Add option to disable module loading.
This patch was created by Lawrence Crowl and reviewed in:
http://llvm-reviews.chandlerc.com/D963

llvm-svn: 187738
2013-08-05 20:26:17 +00:00
Craig Topper 50ad5b7354 Add support for passing -1 to __builtin_shufflevector to signify an undefined element value to match IR capabilities.
llvm-svn: 187694
2013-08-03 17:40:38 +00:00
Eli Friedman f24bd3bdba Fix GNU ObjC ABI for a message returning a struct.
This allows the ObjFW runtime to correctly implement message forwarding
for messages which return a struct.

Patch by Jonathan Schleifer.

llvm-svn: 187174
2013-07-26 00:53:29 +00:00
Manuel Klimek dba64f1aff Fix incorrect documentation generation for type matchers.
llvm-svn: 187104
2013-07-25 06:05:50 +00:00
Richard Smith 4fb09720cf Rename feature test for lambda init-captures from cxx_generalized_capture to
cxx_init_capture. "generalized" is neither descriptive nor future-proof. No
compatibility problems expected, since we've never advertised having this
feature.

llvm-svn: 187058
2013-07-24 17:51:13 +00:00
Richard Smith c0f7b81d89 Update documentation to match current C++1y feature set.
llvm-svn: 187055
2013-07-24 17:41:31 +00:00
Manuel Klimek e88204c4ce Update docs.
llvm-svn: 187022
2013-07-24 05:46:07 +00:00
Eli Friedman a54333264a Fix bug in computing POD-for-layout.
A class with a field of non-POD-for-layout type is not POD-for-layout.
This computation should not depend on whether the field is of POD type
in the language sense.

Fixes PR16537.

Patch by Josh Magee.

llvm-svn: 186741
2013-07-20 01:06:31 +00:00
Richard Smith 83c728b581 Update users manual to indicate:
1) clang++ must be used when linking C++ programs using -fsanitize=undefined, and
  2) MSan can't be combined with TSan or ASan.

llvm-svn: 186711
2013-07-19 19:06:48 +00:00
Alexey Samsonov 492c7bc8ff Revert r186672 - turns out ASan supports Mac OS 10.6 yet.
llvm-svn: 186673
2013-07-19 12:53:04 +00:00
Alexey Samsonov 32f071a1d6 [ASan] Reflect the dropped Mac OS 10.6 support in docs
llvm-svn: 186672
2013-07-19 12:33:30 +00:00
Tim Northover 6aacd49094 ARM: implement low-level intrinsics for the atomic exclusive operations.
This adds three overloaded intrinsics to Clang:
    T __builtin_arm_ldrex(const volatile T *addr)
    int __builtin_arm_strex(T val, volatile T *addr)
    void __builtin_arm_clrex()

The intent is that these do what users would expect when given most sensible
types. Currently, "sensible" translates to ints, floats and pointers.

llvm-svn: 186394
2013-07-16 09:47:53 +00:00
Samuel Benzaquen 79656e19c8 Add support for type traversal matchers.
Summary:
Fixup the type traversal macros/matchers to specify the supported types.
Make the marshallers a little more generic to support any variadic function.
Update the doc script.

Reviewers: klimek

CC: cfe-commits, revane

Differential Revision: http://llvm-reviews.chandlerc.com/D1023

llvm-svn: 186340
2013-07-15 19:25:06 +00:00
Richard Smith 6cbd65d84d Add a __builtin_addressof that performs the same functionality as the built-in
& operator (ignoring any overloaded operator& for the type). The purpose of
this builtin is for use in std::addressof, to allow it to be made constexpr;
the existing implementation technique (reinterpret_cast to some reference type,
take address, reinterpert_cast back) does not permit this because
reinterpret_cast between reference types is not permitted in a constant
expression in C++11 onwards.

llvm-svn: 186053
2013-07-11 02:27:57 +00:00
Richard Smith 36ee4fc329 Fix some grammar errors.
llvm-svn: 186048
2013-07-11 00:34:42 +00:00
Richard Smith ccfc9ffcbe Fix documentation:
#if defined(__has_foo("X")) && __has_foo("X")

is not a correct way to portably use __has_foo, because it is expanded to

  #if 0 && 0("X")

... which is ill-formed.

Also add a missing ')'.

llvm-svn: 186047
2013-07-11 00:27:05 +00:00
Anna Zaks 7925e3db63 [analyzer] Add a debug checker that prints Exploded Graph
Add a debug checker that is useful to understand how the ExplodedGraph is
built; it can be triggered using the following command:

 clang -cc1 -analyze -analyzer-checker=debug.ViewExplodedGraph my_program.c

A patch by Béatrice Creusillet!

llvm-svn: 184768
2013-06-24 18:12:12 +00:00
Sean Silva 4c280bd3de [docs] `-fno-sanitize=` is accepted too.
llvm-svn: 184611
2013-06-21 23:50:58 +00:00