Commit Graph

168756 Commits

Author SHA1 Message Date
Ahmed Charles d779459f21 [C++11] Add #include's for OwningPtr.
Allows removing #include's in LLVM while switching to std::unique_ptr.

llvm-svn: 202679
2014-03-03 07:20:05 +00:00
Ahmed Charles 686eb9a966 [C++11] Pass unique_ptr by value instead of &&.
Suggestion by Richard Smith.

llvm-svn: 202678
2014-03-03 07:15:46 +00:00
Ahmed Charles bf8e283f15 [C++11] Add #include's for OwningPtr.
Allows removing #include's in LLVM while switching to std::unique_ptr.

llvm-svn: 202677
2014-03-03 07:11:21 +00:00
Ahmed Charles de61d0edad [C++11] Add #include's for OwningPtr.
Allows removing #include's in LLVM while switching to std::unique_ptr.

llvm-svn: 202676
2014-03-03 07:00:47 +00:00
Argyrios Kyrtzidis 74c96c0c75 [libclang] Change clang_VirtualFileOverlay_writeToBuffer to return a malloc'ed buffer.
Returning CXString is not appropriate if we want to switch to a non-string format buffer.

llvm-svn: 202675
2014-03-03 06:38:52 +00:00
Saleem Abdulrasool 19dcc312ee AsmParser: add missed tests
The diagnostics tests were missing from the previous introduction of ifeqs.

llvm-svn: 202674
2014-03-03 06:35:00 +00:00
Marshall Clow 05c8dad230 Implement LWG Paper n3887: Consistent Metafunction Aliases. This adds std::tuple_element_t<> as an alias for tuple_element<>::type. Clean up the synopsis for tuple_element in <utility> as well.
llvm-svn: 202673
2014-03-03 06:18:11 +00:00
Marshall Clow 06965c1fd0 Per N3924, mark random_shuffle as deprecated in the synopsis for <algorithm>. Since we don't actually do anything when a call is deprecated, there is no functionality change. Maybe someday, we'll decide to warn when using a deprecated function.
llvm-svn: 202672
2014-03-03 06:14:19 +00:00
Marshall Clow 6a640a18a4 Implement LWG Issue #2285 - make_reverse_iterator. Also mark issues #1450 and #2205 as complete; they are just wording changes in the standard. Mark issues #2359, #2320 and #2322 as complete - libc++ implements them already.
llvm-svn: 202671
2014-03-03 01:24:04 +00:00
Venkatraman Govindaraju 925ec9b11e [Sparc] Add trap on integer condition codes (Ticc) instructions to Sparc backend.
llvm-svn: 202670
2014-03-02 23:39:07 +00:00
Peter Collingbourne c0423b349b Disable all dependency output options when using the Tooling library.
It isn't appropriate for a tool to be stomping over the dependency files,
especially if the actual build uses a compiler other than Clang or the tool
cannot find all the headers for some reason (which would cause the existing
dependency file to be deleted).

If a tool actually needs to care about dependency files we can think about
adding a mechanism for getting to this information.

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

llvm-svn: 202669
2014-03-02 23:37:26 +00:00
Peter Collingbourne b17a3b3d33 Add a level parameter to ClangTidyCheck::diag.
The goal is to make it possible for checks to emit diagnostics at levels
other than 'warning'.

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

llvm-svn: 202668
2014-03-02 23:34:48 +00:00
David Majnemer dbd6acb64b Revert "Preprocessor: Add __ALIGNOF_MAX_ALIGN_T__"
This commit reverts r201037, it's functionality is not needed given the
definition of std::max_align_t in libcxx circa r201843.

llvm-svn: 202667
2014-03-02 23:01:10 +00:00
Venkatraman Govindaraju 07d3af2821 [Sparc] Add return/rett instruction to Sparc backend.
llvm-svn: 202666
2014-03-02 22:55:53 +00:00
Benjamin Kramer ee68e352a7 Remove unnecessary copy ctors.
They didn't provide any value over the default ones but blocked move semantics.

llvm-svn: 202664
2014-03-02 21:24:52 +00:00
Venkatraman Govindaraju 4fa2ab26f5 [Sparc] Add support for decoding jmpl/retl/ret instruction.
llvm-svn: 202663
2014-03-02 21:17:44 +00:00
Benjamin Kramer 49c8ae21f5 Give APInt move semantics.
The interaction between defaulted operators and move elision isn't
totally obvious, add a unit test so it doesn't break unintentionally.

llvm-svn: 202662
2014-03-02 20:56:28 +00:00
Venkatraman Govindaraju c3084ad294 [Sparc] Add fcmpe* instructions to Sparc backend.
llvm-svn: 202661
2014-03-02 19:56:19 +00:00
Venkatraman Govindaraju f9a202a9ac [Sparc] Add VIS instructions to sparc backend.
llvm-svn: 202660
2014-03-02 19:31:21 +00:00
David Majnemer b100410365 Normalize line endings
Some files had CRLF line terminators, some only had a mixture of
CRLF and LF.  Switch to LF.

llvm-svn: 202659
2014-03-02 18:46:05 +00:00
Hal Finkel f7a07a5010 Add a PPC inline asm constraint type for single CR bits
This adds support for the PPC "wc" inline asm constraint (used for allocating
individual CR bits). Support for this constraint type was recently added to the
LLVM PowerPC backend. Although gcc does not currently support allocating
individual CR bits, this identifier choice has been coordinated with the gcc
PowerPC team, and will be marked as reserved for this purpose in the gcc
constraints.md file.

Prior to this change, none of the multi-character PPC constraints were handled
correctly (the '^' escape character was not being added as required by the
parsing code in LLVM). This should now be fixed. I'll add tests for these other
constraints as support is added for them in the backend.

llvm-svn: 202658
2014-03-02 18:24:18 +00:00
Hal Finkel 6aca2373f2 Add a PPC inline asm constraint type for single CR bits
Now that the PowerPC backend can track individual CR bits as first-class
registers, we should also have a way of allocating them for inline asm
statements. Because these registers are only one bit, if an output variable is
implicitly cast to a larger integer size, we'll get an any_extend to that
larger type (this is part of the existing target-independent logic). As a
result, regardless of the size of the output type, only the first bit is
meaningful.

The constraint identifier "wc" has been chosen for this purpose. Although gcc
does not currently support allocating individual CR bits, this identifier
choice has been coordinated with the gcc PowerPC team, and will be marked as
reserved for this purpose in the gcc constraints.md file.

llvm-svn: 202657
2014-03-02 18:23:39 +00:00
David Majnemer fc256c3952 AttributeReference: Use UNIX line endings
llvm-svn: 202656
2014-03-02 18:17:08 +00:00
Aaron Ballman b576a36c88 Adding some cross references to the sanitizer attribute documentation. Removes a Sphinx warning pointed out by Sean Silva.
llvm-svn: 202655
2014-03-02 17:48:20 +00:00
Aaron Ballman b097f7fe9a Simplifying attribute generation with range-based for loops. No functional changes intended.
llvm-svn: 202654
2014-03-02 17:38:37 +00:00
Benjamin Kramer bd39f6e364 [C++11] ASTMatchers: Use standard static_assert and type traits.
llvm-svn: 202653
2014-03-02 17:08:43 +00:00
Benjamin Kramer 4527fb2f33 [C++11] Use std::atomic instead of LLVM's.
No intended functionality change.

llvm-svn: 202652
2014-03-02 17:08:31 +00:00
Tobias Grosser b5846f9e15 ScopDetect: Make foreachs 'const auto &'
We mostly iterate over read-only values. Following a suggestion by Duncan P.N
Exons Smith, we use the construct 'const auto &' for this.

llvm-svn: 202651
2014-03-02 17:05:27 +00:00
Tobias Grosser 45bac0d953 Use C++11 formatting
clang-formats behaviour has changed for a couple of C++11 formattings. We adapt
Polly to ensure our formatting checks are clean again.

llvm-svn: 202650
2014-03-02 17:05:21 +00:00
Dmitri Gribenko 23077e3e0a Documentation comments: fix incorrect usage of \param
llvm-svn: 202649
2014-03-02 16:48:59 +00:00
Tobias Grosser e8fa99b276 PollyDectect: Use spaces before foreach colons
clang-format requires a space before the ":" in the foreach loop. Even though
this is surprising to me, we follow this style to make our formatting
consistent with clang-format. I found that this clang-format style is used in a
couple of C++11 examples, hence I believe the fact that clang-format adds a
colon is not a bug but just something I was not used to yet.

llvm-svn: 202648
2014-03-02 16:28:24 +00:00
Michael Kuperstein 661e288a70 Ensure bitcode encoding of instructions and their operands stays stable.
This includes instructions that relate to memory access (load/store/GEP), comparison instructions and calls.

Work was done by lama.saba@intel.com.

llvm-svn: 202647
2014-03-02 15:26:36 +00:00
Benjamin Kramer ffe110b304 [C++11] Replace llvm::tie with std::tie.
llvm-svn: 202646
2014-03-02 13:48:32 +00:00
Benjamin Kramer 3445d9edad [C++11] Work around an incompatibility between llvm::tie and std::tie.
llvm-svn: 202645
2014-03-02 13:45:18 +00:00
Benjamin Kramer d6f1f84f51 [C++11] Replace llvm::tie with std::tie.
The old implementation is no longer needed in C++11.

llvm-svn: 202644
2014-03-02 13:30:33 +00:00
Benjamin Kramer cef536ec0f [C++11] Work around an incompatibility between llvm::tie and std::tie.
llvm-svn: 202643
2014-03-02 13:18:22 +00:00
Chandler Carruth cf01800b1f [C++11] Replace LLVM_STATIC_ASSERT with static_assert, we now have
access to it on all host toolchains.

llvm-svn: 202642
2014-03-02 13:10:45 +00:00
Ahmed Charles 7bc33bf934 Test commit.
llvm-svn: 202641
2014-03-02 13:08:46 +00:00
Chandler Carruth 06dde92cd6 [C++11] Switch from LLVM_STATIC_ASSERT to static_assert now that we
require host toolchains which support this.

llvm-svn: 202640
2014-03-02 13:02:01 +00:00
Benjamin Kramer 867ea1d426 [C++11] Replace llvm::tie with std::tie.
llvm-svn: 202639
2014-03-02 13:01:17 +00:00
Chandler Carruth d40922989a Fix a typo spotted by Anton.
llvm-svn: 202638
2014-03-02 13:00:23 +00:00
Chandler Carruth f8b7266d57 [C++11] Switch the clang-format LLVM style to use C++11 style braced
init list formatting. This suggestion has now gone into the LLVM coding
standards, and is particularly relevant now that we're using C++11.

Updated a really ridiculous number of tests to reflect this change.

llvm-svn: 202637
2014-03-02 12:37:31 +00:00
Benjamin Kramer b6d0bd48bd [C++11] Replace llvm::next and llvm::prior with std::next and std::prev.
Remove the old functions.

llvm-svn: 202636
2014-03-02 12:27:27 +00:00
Benjamin Kramer 167e999be9 [C++11] Replace llvm::next and llvm::prior with std::next and std::prev.
llvm-svn: 202635
2014-03-02 12:20:24 +00:00
Tobias Grosser 00dc309a08 C++11: Use foreach in ScopDetection
llvm-svn: 202634
2014-03-02 12:02:46 +00:00
Craig Topper e67972c462 Revert a LLVM_OVERRIDE to 'override' change in documentation. My search and replace was a little overzealous.
llvm-svn: 202633
2014-03-02 10:24:34 +00:00
Craig Topper a3dbe84166 [C++11] Replace LLVM_OVERRIDE with 'override'
llvm-svn: 202632
2014-03-02 10:20:11 +00:00
Chandler Carruth d293fc2174 [C++11] Clarify in the Compiler.h support macros and comments (and
assert it with an #error) that we require MSVC 2012; MSVC 2010 will no
longer suffice.

llvm-svn: 202631
2014-03-02 10:07:45 +00:00
Craig Topper bbc6d62736 [C++11] Remove an LLVM_OVERRIDE use that I missed in my previous commit.
llvm-svn: 202630
2014-03-02 10:02:43 +00:00
Craig Topper 127ab3e700 [C++11] Remove LLVM_FINAL and LLVM_OVERRIDE macros now that all their uses are gone.
llvm-svn: 202629
2014-03-02 09:54:13 +00:00