summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
* Java annotation declaration being handled correctlyHans Wennborg2018-10-192-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | Previously, Java annotation declarations (@interface AnnotationName) were being handled as ObjC interfaces. This caused the brace formatting to mess up, so that when you had a class with an interface defined in it, it would indent the final brace of the class. It used to format this class like so: class A { @interface B {} } But will now just skip the @interface and format it like so: class A { @interface B {} } Patch by Sam Maier! Differential Revision: https://reviews.llvm.org/D53434 llvm-svn: 344789
* [Hexagon] Remove support for V4Krzysztof Parzyszek2018-10-195-23/+6
| | | | llvm-svn: 344786
* [ASTImporter] Removed uneeded default case label.Balazs Keri2018-10-191-2/+2
| | | | llvm-svn: 344784
* [ASTImporter] Added error handling for AST import.Balazs Keri2018-10-194-3315/+4019
| | | | | | | | | | | | | | | | | | | | | Summary: The goal of this change is to make the ASTImporter::Import functions return llvm::Expected instead of the imported type. As first part the ASTNodeImporter visit functions are updated to return with llvm::Expected. Various `import` functions are added to ASTNodeImporter to simplify the code and have a common place for interface towards ASTImporter (from ASTNodeImporter). There is some temporary code that is needed before ASTImporter is updated. Reviewers: a.sidorin, a_sidorin, xazax.hun Reviewed By: a_sidorin Subscribers: dkrupp, Szelethus, rnkovacs, martong, jfb, cfe-commits Differential Revision: https://reviews.llvm.org/D51633 llvm-svn: 344783
* [OpenCL] Remove unwanted signedness conversion from testsMarco Antognini2018-10-191-4/+4
| | | | | | | | | | The get_kernel_* functions used in cl20-device-side-enqueue.cl all return unsigned integers. This patch avoids undesired implicit conversions on the returned values. Differential Revision: https://reviews.llvm.org/D52873 llvm-svn: 344778
* [COFF, ARM64] Enable unit test arm64-microsoft-status-reg.cpp only for ↵Mandeep Singh Grang2018-10-191-0/+2
| | | | | | | | | | aarch64 target This should unbreak bots broken here: http://lab.llvm.org:8011/builders/clang-cmake-x86_64-sde-avx512-linux/builds/14391 http://lab.llvm.org:8011/builders/llvm-clang-lld-x86_64-scei-ps4-ubuntu-fast/builds/38288 llvm-svn: 344767
* [COFF, ARM64] Add _ReadStatusReg and_WriteStatusReg intrinsicsMandeep Singh Grang2018-10-186-0/+171
| | | | | | | | | | | | Reviewers: rnk, compnerd, mstorsjo, efriedma, TomTan, haripul, javed.absar Reviewed By: efriedma Subscribers: dmajor, kristof.beyls, chrib, cfe-commits Differential Revision: https://reviews.llvm.org/D53115 llvm-svn: 344765
* [Test] Fix test file for C++98 modeDavid Bolvansky2018-10-181-1/+3
| | | | llvm-svn: 344762
* [Diagnostics] Add missing expected warning to test fileDavid Bolvansky2018-10-181-1/+1
| | | | llvm-svn: 344761
* [Diagnostics] Check for integer overflow in array size expressions David Bolvansky2018-10-184-3/+24
| | | | | | | | | | | | | | Summary: Fixes PR27439 Reviewers: rsmith, Rakete1111 Reviewed By: rsmith Subscribers: Rakete1111, cfe-commits Differential Revision: https://reviews.llvm.org/D52750 llvm-svn: 344759
* Add check-clang-python to the Clang tests directory in IDEs; NFC.Aaron Ballman2018-10-181-0/+1
| | | | llvm-svn: 344750
* Add language standard aliases for -std=c18, -std=gnu18, and -std=iso9899:2018.Aaron Ballman2018-10-183-2/+6
| | | | | | As described in D40225, the C17 standard was balloted and approved in 2017, but the ISO publication process delayed the actual publication until 2018. WG14 considers the release to be C17 and describes it as such, but users can still be confused by the publication year which is why -std=c18 adds value. These aliases map to c17 and are all supported by GCC 8.x with the same behavior. Note that the value of __STDC_VERSION__ remains at 201710L. llvm-svn: 344749
* [X86][Tests] Make sure tls-direct-seg-refs tests only run where supportedKristina Brooks2018-10-182-6/+9
| | | | | | | This flag is only supported for x86 targets, make sure the tests only run for those. llvm-svn: 344742
* [OPENMP] Move OMPClausePrinter to OpenMPClause.h/OpenMPClause.cpp - NFC. ↵Patrick Lyster2018-10-183-451/+448
| | | | | | Differential Revision: https://reviews.llvm.org/D53102 llvm-svn: 344740
* Add support for -mno-tls-direct-seg-refs to ClangKristina Brooks2018-10-187-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch exposes functionality added in rL344723 to the Clang driver/frontend as a flag and adds appropriate metadata. Driver tests pass: ``` ninja check-clang-driver -snip- Expected Passes : 472 Expected Failures : 3 Unsupported Tests : 65 ``` Odd failure in CodeGen tests but unrelated to this: ``` ninja check-clang-codegen -snip- /SourceCache/llvm-trunk-8.0/tools/clang/test/CodeGen/builtins-wasm.c:87:10: error: cannot compile this builtin function yet -snip- Failing Tests (1): Clang :: CodeGen/builtins-wasm.c Expected Passes : 1250 Expected Failures : 2 Unsupported Tests : 120 Unexpected Failures: 1 ``` Original commit: [X86] Support for the mno-tls-direct-seg-refs flag Allows to disable direct TLS segment access (%fs or %gs). GCC supports a similar flag, it can be useful in some circumstances, e.g. when a thread context block needs to be updated directly from user space. More info and specific use cases: https://bugs.llvm.org/show_bug.cgi?id=16145 Patch by nruslan (Ruslan Nikolaev). Differential Revision: https://reviews.llvm.org/D53102 llvm-svn: 344739
* [TI removal] Test predicate rather than casting to detect a terminatorChandler Carruth2018-10-181-4/+5
| | | | | | and use the range based successor API. llvm-svn: 344730
* AMDGPU: Add options to enable/disable code object v3Konstantin Zhuravlyov2018-10-172-0/+11
| | | | | | Differential Revision: https://reviews.llvm.org/D53386 llvm-svn: 344711
* [AArch64] Define __ELF__ for aarch64-none-elf and other similar triples.Eli Friedman2018-10-172-3/+3
| | | | | | | | "aarch64-none-elf" is commonly used for AArch64 baremetal toolchains. Differential Revision: https://reviews.llvm.org/D53348 llvm-svn: 344710
* Fix for arm bots afternew PM pass port. Prevent cross compiling on arm.Leonard Chan2018-10-171-1/+1
| | | | llvm-svn: 344702
* Fix for failing unit tests on some bots after r344696.Leonard Chan2018-10-171-23/+2
| | | | llvm-svn: 344701
* [PassManager/Sanitizer] Enable usage of ported AddressSanitizer passes with ↵Leonard Chan2018-10-172-0/+42
| | | | | | | | | | | | | -fsanitize=address Enable usage of `AddressSanitizer` and `AddressModuleSanitizer` ported from the legacy to the new PassManager. This patch depends on https://reviews.llvm.org/D52739. Differential Revision: https://reviews.llvm.org/D52814 llvm-svn: 344699
* NFC: Remove trailing space from CodeGenModule.cppTakuto Ikuta2018-10-171-8/+8
| | | | llvm-svn: 344668
* [python] [tests] Disable on known-broken archesMichal Gorny2018-10-171-11/+21
| | | | | | | | | | | | | | Disable the Python binding tests on AArch64, Hexagon and SystemZ following reports on test failures. The first two yield different results, possibly indicating test case problems. The last one seems to have broken FFI in Python. While at it, refactor the code to make adding future test restrictions easier. Differential Revision: https://reviews.llvm.org/D53326 llvm-svn: 344666
* AMDGPU: add __builtin_amdgcn_update_dppYaxun Liu2018-10-174-6/+27
| | | | | | | | | | Emit llvm.amdgcn.update.dpp for both __builtin_amdgcn_mov_dpp and __builtin_amdgcn_update_dpp. The first argument to llvm.amdgcn.update.dpp will be undef for __builtin_amdgcn_mov_dpp. Differential Revision: https://reviews.llvm.org/D52320 llvm-svn: 344665
* [analyzer] [www] Minor improvements to the text in open_projectsGeorge Karpenkov2018-10-171-21/+18
| | | | llvm-svn: 344664
* [analyzer] [www] Updated a list of open projectsGeorge Karpenkov2018-10-171-128/+185
| | | | | | Differential Revision: https://reviews.llvm.org/D53024 llvm-svn: 344663
* Disable code object version 3 for HIP toolchainYaxun Liu2018-10-163-7/+19
| | | | | | | | | AMDGPU backend will switch to code object version 3 by default. Since HIP runtime is not ready, disable it until the runtime is ready. Differential Revision: https://reviews.llvm.org/D53325 llvm-svn: 344630
* [SystemZ] Actually enable -mzvector keywordsUlrich Weigand2018-10-163-0/+51
| | | | | | | | | | | | | | It appears when initially committing the support for the IBM Z vector extension language, one critical line was lost, causing the specific keywords __vector, __bool, and vec_step to not actually be enabled. (Note that this does not affect "vector" and "bool"!) Unfortunately, this was not caught by any tests either. (All existing Z vector tests just use the regular "vector" and "bool" keywords ...) Fixed by adding the missing line and updating the tests. llvm-svn: 344611
* [driver][mips] Support MIPS R6 target triplesSimon Atanasyan2018-10-168-32/+184
| | | | | | | | | | | | | | | | This change adds support for the following MIPS target triples: mipsisa32r6-linux-gnu mipsisa32r6el-linux-gnu mipsisa64r6-linux-gnuabi64 mipsisa64r6el-linux-gnuabi64 mipsisa64r6-linux-gnuabin32 mipsisa64r6el-linux-gnuabin32 Patch by Yun Qiang Su. Differential revision: https://reviews.llvm.org/D50850 llvm-svn: 344608
* [driver][mips] Adjust target triple's environment accordingly to provided ↵Simon Atanasyan2018-10-162-9/+22
| | | | | | | | | | | ABI name For MIPS we need to adjust not only architecture name accordingly to ABI provided by the `-mabi` command line option, but also modify triple's environment. For example, for `mips-linux-gnu` triple and `-mabi=n32` option a correct final triple is `mips64-linux-gnuabin32`. llvm-svn: 344603
* Fix buildbots - update clang-interpreter to use Legacy ORC classes ↵Simon Pilgrim2018-10-161-3/+3
| | | | | | introduced in rL344572. llvm-svn: 344598
* [ARM][AArch64] Pass through endian flags to assembler and linker.Peter Smith2018-10-166-35/+169
| | | | | | | | | | | | | | | | | The big-endian arm32 Linux builds are currently failing when the -mbig-endian flag is used but the binutils default on the system is little endian. This also holds when -mlittle-endian is used and the binutils default is big endian. The patch always passes through -EL or -BE to the assembler and linker, taking into account the target and the -mbig-endian and -mlittle-endian flag. Fixes pr38770 Differential Revision: https://reviews.llvm.org/D52784 llvm-svn: 344597
* Add target requirement to profile remap test.Yvan Roux2018-10-161-0/+2
| | | | | | | | Fix bots which don't have x86_64 target built (ARM/AArch64). Differential Revision: https://reviews.llvm.org/D53272 llvm-svn: 344593
* [mips] Group similar commands in the test case. NFCSimon Atanasyan2018-10-161-8/+4
| | | | llvm-svn: 344583
* [OPENMP][NVPTX]Increment iterator only when it is used, NFC.Alexey Bataev2018-10-161-1/+2
| | | | llvm-svn: 344574
* [mips] Fix handling of GNUABIN32 environment in a target tripleSimon Atanasyan2018-10-1510-13/+115
| | | | | | | | | | | | The `GNUABIN32` environment in a target triple implies using the N32 ABI. This patch adds support for this environment and switches on N32 ABI if necessary. Patch by Patch by YunQiang Su. Differential revision: https://reviews.llvm.org/D51464 llvm-svn: 344570
* [Driver] Support direct split DWARF emission for FuchsiaPetr Hosek2018-10-153-4/+12
| | | | | | | | | This enables the driver support for direct split DWARF emission for Fuchsia in addition to Linux. Differential Revision: https://reviews.llvm.org/D53248 llvm-svn: 344556
* [analyzer] Add doxygen comments for the new CXXAllocatorCall APIs.Artem Dergachev2018-10-151-5/+7
| | | | | | Forgot to squeeze this into r344539. llvm-svn: 344540
* [analyzer] Teach CallEvent about C++17 aligned operator new().Artem Dergachev2018-10-153-3/+34
| | | | | | | | | | | | | | | | | | | | In C++17, when class C has large alignment value, a special case of overload resolution rule kicks in for expression new C that causes the aligned version of operator new() to be called. The aligned new has two arguments: size and alignment. However, the new-expression has only one "argument": the construct-expression for C(). This causes a false positive in core.CallAndMessage's check for matching number of arguments and number of parameters. Update CXXAllocatorCall, which is a CallEvent sub-class for operator new calls within new-expressions, so that the number of arguments always matched the number of parameters. rdar://problem/44738501 Differential Revision: https://reviews.llvm.org/D52957 llvm-svn: 344539
* [analyzer] NFC: RetainCountChecker: Don't dump() symbols into program point ↵Artem Dergachev2018-10-151-15/+2
| | | | | | | | | | | | | | | | tags. We don't need a separate node for every symbol, because whenever the first symbol leaks, a bug is emitted, the analysis is sinked, and the checker callback immediately returns due to State variable turning into null, so we never get to see the second leaking symbol. Additionally, we are no longer able to break normal analysis while experimenting with debug dumps. Differential Revision: https://reviews.llvm.org/D52804 llvm-svn: 344538
* [python] [tests] Disable python binding tests under LLVM_USE_SANITIZER=AddressArtem Dergachev2018-10-151-1/+16
| | | | | | | | | | | | They don't work yet. Patch by Dan Liew! rdar://problem/45242886 Differential Revision: https://reviews.llvm.org/D53239 llvm-svn: 344537
* Revert 344389 "Revert r344375 "[Driver] check for exit code from SIGPIPE""Nick Desaulniers2018-10-151-7/+18
| | | | | | | | | | | | | | | | | Summary: Add preprocessor guards for UNIX. This reverts commit r344389. Reviewers: rnk, majnemer, jfb Reviewed By: rnk Subscribers: cfe-commits, pirama, srhines Differential Revision: https://reviews.llvm.org/D53210 llvm-svn: 344536
* [Fixed Point Arithmetic] FixedPointCastLeonard Chan2018-10-1517-4/+517
| | | | | | | | | | | | | This patch is a part of https://reviews.llvm.org/D48456 in an attempt to split them up. This contains the code for casting between fixed point types and other fixed point types. The method for converting between fixed point types is based off the convert() method in APFixedPoint. Differential Revision: https://reviews.llvm.org/D50616 llvm-svn: 344530
* Revert "[CodeGenCXX] Treat 'this' as noalias in constructors"Sean Fertile2018-10-15148-875/+859
| | | | | | | This reverts commit https://reviews.llvm.org/rL344150 which causes MachineOutliner related failures on the ppc64le multistage buildbot. llvm-svn: 344526
* [CodeComplete] Make sure keyword 'template' is added even when code pattern ↵Eric Liu2018-10-152-0/+9
| | | | | | | | | | | | is disabled. Reviewers: sammccall, hokein Subscribers: arphaman, cfe-commits Differential Revision: https://reviews.llvm.org/D53284 llvm-svn: 344509
* [TI removal] Make `getTerminator()` return a generic `Instruction`.Chandler Carruth2018-10-152-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | This removes the primary remaining API producing `TerminatorInst` which will reduce the rate at which code is introduced trying to use it and generally make it much easier to remove the remaining APIs across the codebase. Also clean up some of the stragglers that the previous mechanical update of variables missed. Users of LLVM and out-of-tree code generally will need to update any explicit variable types to handle this. Replacing `TerminatorInst` with `Instruction` (or `auto`) almost always works. Most of these edits were made in prior commits using the perl one-liner: ``` perl -i -ple 's/TerminatorInst(\b.* = .*getTerminator\(\))/Instruction\1/g' ``` This also my break some rare use cases where people overload for both `Instruction` and `TerminatorInst`, but these should be easily fixed by removing the `TerminatorInst` overload. llvm-svn: 344504
* [Hexagon] Update tests account for non-hardcoded linker name.Sid Manning2018-10-142-27/+27
| | | | | | | | | Tests should not assume the linker's name, CLANG_DEFAULT_LINKER could change it. Differential Revision: https://reviews.llvm.org/D53219 llvm-svn: 344482
* Try harder to fix test/Driver/cl-showfilenames.cHans Wennborg2018-10-131-4/+4
| | | | | | Follow-up to r344462. llvm-svn: 344469
* Move some helpers from the global namespace into anonymous ones.Benjamin Kramer2018-10-133-1/+7
| | | | llvm-svn: 344468
* [analyzer] Improved cmake configuration for Z3Enrico Steffinlongo2018-10-133-15/+51
| | | | | | | | | | | | | | | | | | | | | | Summary: Enhanced support for Z3 in the cmake configuration of clang; now it is possible to specify any arbitrary Z3 install prefix (CLANG_ANALYZER_Z3_PREFIX) to cmake with lib (or bin) and include folders. Before the patch only in cmake default locations were searched (https://cmake.org/cmake/help/v3.4/command/find_path.html). Specifying any CLANG_ANALYZER_Z3_PREFIX will force also CLANG_ANALYZER_BUILD_Z3 to ON. Removed also Z3 4.5 version requirement since it was not checked, and now Clang works with Z3 4.7 Reviewers: NoQ, george.karpenkov, mikhail.ramalho Reviewed By: george.karpenkov Subscribers: rnkovacs, NoQ, esteffin, george.karpenkov, delcypher, ddcc, mgorny, xazax.hun, szepet, a.sidorin, Szelethus Tags: #clang Differential Revision: https://reviews.llvm.org/D50818 llvm-svn: 344464
OpenPOWER on IntegriCloud