- Apr 11, 2017
-
-
Yaxun Liu authored
For OpenCL, the private address space qualifier is 0 in AST. Before this change, 0 address space qualifier is always mapped to target address space 0. As now target private address space is specified by alloca address space in data layout, address space qualifier 0 needs to be mapped to alloca addr space specified by the data layout. This change has no impact on targets whose alloca addr space is 0. With contributions from Matt Arsenault, Tony Tye and Wen-Heng (Jack) Chung Differential Revision: https://reviews.llvm.org/D31404 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299965 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alex Lorenz authored
rdar://31501863 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299962 91177308-0d34-0410-b5e6-96231b3b80d8
-
Vassil Vassilev authored
We need to address cases (breaking libc++) such as template <class _Up> static int __test(...); template<typename _Tp> auto v = __test<_Tp>(0); git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299956 91177308-0d34-0410-b5e6-96231b3b80d8
-
Nico Weber authored
At present, clang-format mangles Java containing logical right shift operators ('>>>=' or '>>>'), splitting them in two, resulting in invalid code: public class Minimal { public void func(String args) { int i = 42; - i >>>= 1; + i >> >= 1; return i; } } This adds both forms of logical right shift to the FormatTokenLexer, so clang-format won't attempt to split them and insert bogus whitespace. https://reviews.llvm.org/D31652 Patch from Richard Bradfield <bradfier@fstab.me>! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299952 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alex Lorenz authored
Differential Revision: https://reviews.llvm.org/D25321 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299951 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alex Lorenz authored
as identifiers in Objective-C++ This commit improves the 'expected identifier' errors that are presented when a C++ keyword is used as an identifier in Objective-C++ by mentioning that this is a C++ keyword in the diagnostic message. It also improves the error recovery: the parser will now treat the C++ keywords as identifiers to prevent unrelated parsing errors. rdar://20626062 Differential Revision: https://reviews.llvm.org/D26503 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299950 91177308-0d34-0410-b5e6-96231b3b80d8
-
Vassil Vassilev authored
Reviewed by Richard Smith (D29877)! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299930 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alexander Kornienko authored
Summary: This fixes a few outstanding bugs: * incorrect breaking of NSString literals containing double-width characters; * inconsistent formatting of ObjC dictionary literals containing NSString literals; * AlwaysBreakBeforeMultilineStrings ignoring implicitly-concatenated NSString literals. Reviewers: djasper Reviewed By: djasper Subscribers: klimek, cfe-commits Differential Revision: https://reviews.llvm.org/D31706 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299927 91177308-0d34-0410-b5e6-96231b3b80d8
-
Maxim Ostapenko authored
This is a compiler part of https://reviews.llvm.org/D29586. Enable LSan on arm Linux. Differential Revision: https://reviews.llvm.org/D31760 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299921 91177308-0d34-0410-b5e6-96231b3b80d8
-
Sylvestre Ledru authored
Reviewers: djasper Reviewed By: djasper Subscribers: Eugene.Zelenko, klimek, cfe-commits Differential Revision: https://reviews.llvm.org/D31408 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299919 91177308-0d34-0410-b5e6-96231b3b80d8
-
Peter Collingbourne authored
docs: Use the term "whole-program devirtualization" instead of "virtual function call optimization". The former term is probably more familiar to users. Also add references to the command line flags used to enable the features described in the doc. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299902 91177308-0d34-0410-b5e6-96231b3b80d8
-
Reid Kleckner authored
This re-lands r299875. I introduced a bug in Clang code responsible for replacing K&R, no prototype declarations with a real function definition with a prototype. The bug was here: // Collect any return attributes from the call. - if (oldAttrs.hasAttributes(llvm::AttributeList::ReturnIndex)) - newAttrs.push_back(llvm::AttributeList::get(newFn->getContext(), - oldAttrs.getRetAttributes())); + newAttrs.push_back(oldAttrs.getRetAttributes()); Previously getRetAttributes() carried AttributeList::ReturnIndex in its AttributeList. Now that we return the AttributeSetNode* directly, it no longer carries that index, and we call this overload with a single node: AttributeList::get(LLVMContext&, ArrayRef<AttributeSetNode*>) That aborted with an assertion on x86_32 targets. I added an explicit triple to the test and added CHECKs to help find issues like this in the future sooner. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299899 91177308-0d34-0410-b5e6-96231b3b80d8
-
Matt Arsenault authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299889 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 10, 2017
-
-
Matt Arsenault authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299877 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alexey Bataev authored
If the type of the captured variable is a pointer(s) to variably modified type, this type was not processed correctly. Need to drill into the type, find the innermost variably modified array type and convert it to canonical parameter type. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299868 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 08, 2017
-
-
Michal Gorny authored
Add the 'z3' subdirectory to the list of possible path suffixes for libz3 header search. The z3 headers are installed in /usr/include/z3 on Gentoo. Differential Revision: https://reviews.llvm.org/D31756 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299813 91177308-0d34-0410-b5e6-96231b3b80d8
-
Evgeniy Stepanov authored
Previously __cfi_check was created in LTO optimization pipeline, which means LLD has no way of knowing about the existence of this symbol without rescanning the LTO output object. As a result, LLD fails to export __cfi_check, even when given --export-dynamic-symbol flag. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299806 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 07, 2017
-
-
Saleem Abdulrasool authored
crtbegin is not really a proper windows support thing. This was duplicated when the toolchain was initially built. If the injection of crtbegin is needed, it can be done via the `/include` directive. Furthermore, since `-fPIC` doesnt make sense on PE/COFF, crtbegin and crtbeginS dont really need to be different. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299800 91177308-0d34-0410-b5e6-96231b3b80d8
-
Hans Wennborg authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299785 91177308-0d34-0410-b5e6-96231b3b80d8
-
Hans Wennborg authored
It's used by MS headers in VS 2017 without including intrin.h, so we can't implement it in the header anymore. Differential Revision: https://reviews.llvm.org/D31736 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299782 91177308-0d34-0410-b5e6-96231b3b80d8
-
Saleem Abdulrasool authored
MSDN (https://msdn.microsoft.com/en-us/library/h5w10wxs.aspx) indicates that `__declspec(naked)` is only permitted on x86 and ARM targets. Testing with cl does confirm this behaviour. Provide a warning for use of `__declspec(naked)` on x64. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299774 91177308-0d34-0410-b5e6-96231b3b80d8
-
NAKAMURA Takumi authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299760 91177308-0d34-0410-b5e6-96231b3b80d8
-
Laszlo Nagy authored
Differential Revision: https://reviews.llvm.org/D31237 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299759 91177308-0d34-0410-b5e6-96231b3b80d8
-
Sanne Wouda authored
Summary: When using the C preprocessor with assembly files, either with a capital `S` file extension, or with `-xassembler-with-cpp`, the Unicode escape sequence `\u` is ignored. The `\u` pattern can be used for expanding a macro argument that starts with `u`. Author: Salman Arif <salman.arif@arm.com> Reviewers: rengolin, olista01 Reviewed By: olista01 Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D31765 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299754 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 06, 2017
-
-
Yaxun Liu authored
Change constant address space from 4 to 2 for the new address space mapping in Clang. Differential Revision: https://reviews.llvm.org/D31771 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299691 91177308-0d34-0410-b5e6-96231b3b80d8
-
Chih-Hung Hsieh authored
When fixing a Clang-Tidy bug in D31406, reuse of FileID enabled the missing highlightRange function. Assertion in highlightRange failed because the end-of-range column number was 2 + the last column of a line on Windows. This fix is required to enable D31406. Differential Revision: https://reviews.llvm.org/D31713 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299681 91177308-0d34-0410-b5e6-96231b3b80d8
-
Stanislav Mekhanoshin authored
These two attributes specify the same info in a different way. AMGPU BE only checks the latter as a target specific attribute as opposed to language specific reqd_work_group_size. This change produces amdgpu_flat_work_group_size out of reqd_work_group_size if specified. Differential Revision: https://reviews.llvm.org/D31728 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299678 91177308-0d34-0410-b5e6-96231b3b80d8
-
Ivan Krasin authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299671 91177308-0d34-0410-b5e6-96231b3b80d8
-
Artem Dergachev authored
Hopefully fix crashes by unshadowing the variable. Original commit message: A big part of the clone detection code is functionality for filtering clones and clone groups based on different criteria. So far this filtering process was hardcoded into the CloneDetector class, which made it hard to understand and, ultimately, to extend. This patch splits the CloneDetector's logic into a sequence of reusable constraints that are used for filtering clone groups. These constraints can be turned on and off and reodreder at will, and new constraints are easy to implement if necessary. Unit tests are added for the new constraint interface. This is a refactoring patch - no functional change intended. Patch by Raphael Isemann! Differential Revision: https://reviews.llvm.org/D23418 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299653 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alex Lorenz authored
rdar://20441985 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299650 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alex Lorenz authored
object types should be preferred over conversions to other object pointers This change ensures that Clang will select the correct overload for the following code sample: void overload(Base *b); void overload(Derived *d); void test(Base<Base *> b) { overload(b); // Select overload(Base *), not overload(Derived *) } rdar://20124827 Differential Revision: https://reviews.llvm.org/D31597 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299648 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alex Lorenz authored
lambda capture used by the created block The commit r288866 introduced guaranteed copy elision to C++ 17. This unfortunately broke the lambda to block conversion in C++17 (the compiler crashes when performing IRGen). This commit fixes the conversion by avoiding copy elision for the capture that captures the lambda that's used in the block created by the lambda to block conversion process. rdar://31385153 Differential Revision: https://reviews.llvm.org/D31669 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299646 91177308-0d34-0410-b5e6-96231b3b80d8
-
Simon Dardis authored
Attempt to satisfy llvm-clang-x86_64-expensive-checks-win by targeting x86_64-apple-darwin10 for Sema/vector-ops.c. The underlying failure is due to datatype differences between platforms. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299643 91177308-0d34-0410-b5e6-96231b3b80d8
-
Simon Dardis authored
This improves some error messages which would otherwise refer to ext_vector_type types in contexts where there are no such types. Factored out from D25866 at reviewer's request. Reviewers: bruno Differential Revision: https://reviews.llvm.org/D31667 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299641 91177308-0d34-0410-b5e6-96231b3b80d8
-
Vassil Vassilev authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299639 91177308-0d34-0410-b5e6-96231b3b80d8
-
George Burgess IV authored
- Replace documented return values (true/false) with what's actually returned - Doxygenify the comment - Reflow said comment to 80 cols Not overly familiar with Doxygen, so nits are welcome. :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299603 91177308-0d34-0410-b5e6-96231b3b80d8
-
George Burgess IV authored
Two simplifications: - We check `!Previous.empty()` above and only use `Previous` in const contexts after that check, so the `!Previous.empty()` check seems redundant. - The null check looks pointless, as well: AFAICT, `LookupResults` should never contain null entries, and `OldDecl` should always be non-null if `Redeclaration` is true. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299601 91177308-0d34-0410-b5e6-96231b3b80d8
-
Meador Inge authored
The commit yesterday (r299473) to add the `-print-resource-dir` option was supposed to emit a newline after the resource dir. Differential Revision: https://reviews.llvm.org/D31447 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299597 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 05, 2017
-
-
Reid Kleckner authored
Move the test format into a standalone .py file and add it to the site module search path. This allows us to run the test on Windows, and it makes it compatible with the multiprocessing.Pool lit test execution strategy. I think this test was only passing everywhere else because multiprocessing uses 'fork' to spawn workers, so the test format never needs to be pickled. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299577 91177308-0d34-0410-b5e6-96231b3b80d8
-
Nico Weber authored
clang-format <<END auto c1 = u8'a'; auto c2 = u'a'; END Before: auto c1 = u8 'a'; auto c2 = u'a'; Now: auto c1 = u8'a'; auto c2 = u'a'; Patch from Denis Gladkikh <llvm@denis.gladkikh.email>! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@299574 91177308-0d34-0410-b5e6-96231b3b80d8
-