- Jan 03, 2018
-
-
Hans Wennborg authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321705 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jan 01, 2018
-
-
Serge Pavlov authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321623 91177308-0d34-0410-b5e6-96231b3b80d8
-
Serge Pavlov authored
Clang is inherently a cross compiler and can generate code for any target enabled during build. It however requires to specify many parameters in the invocation, which could be hardcoded during configuration process in the case of single-target compiler. The purpose of configuration files is to make specifying clang arguments easier. A configuration file is a collection of driver options, which are inserted into command line before other options specified in the clang invocation. It groups related options together and allows specifying them in simpler, more flexible and less error prone way than just listing the options somewhere in build scripts. Configuration file may be thought as a "macro" that names an option set and is expanded when the driver is called. Use of configuration files is described in `UserManual.rst`. Differential Revision: https://reviews.llvm.org/D24933 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321621 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 30, 2017
-
-
Serge Pavlov authored
Need to check targets in tests more carefully. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321588 91177308-0d34-0410-b5e6-96231b3b80d8
-
Serge Pavlov authored
Clang is inherently a cross compiler and can generate code for any target enabled during build. It however requires to specify many parameters in the invocation, which could be hardcoded during configuration process in the case of single-target compiler. The purpose of configuration files is to make specifying clang arguments easier. A configuration file is a collection of driver options, which are inserted into command line before other options specified in the clang invocation. It groups related options together and allows specifying them in simpler, more flexible and less error prone way than just listing the options somewhere in build scripts. Configuration file may be thought as a "macro" that names an option set and is expanded when the driver is called. Use of configuration files is described in `UserManual.rst`. Differential Revision: https://reviews.llvm.org/D24933 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321587 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 29, 2017
-
-
Alexey Bataev authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321562 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alexey Bataev authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321561 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 22, 2017
-
-
Bruno Cardoso Lopes authored
We used to advertise private modules to be declared as submodules (Foo.Private). This has proven to not scale well since private headers might carry several dependencies, introducing unwanted content into the main module and often causing dep cycles. Change the canonical way to name it to Foo_Private, forcing private modules as top level ones, and provide warnings under -Wprivate-module to suggest fixes for other private naming. Update documentation to reflect that. rdar://problem/31173501 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321337 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 21, 2017
-
-
Vedant Kumar authored
Diagnose 'unreachable' UB when a noreturn function returns. 1. Insert a check at the end of functions marked noreturn. 2. A decl may be marked noreturn in the caller TU, but not marked in the TU where it's defined. To diagnose this scenario, strip away the noreturn attribute on the callee and insert check after calls to it. Testing: check-clang, check-ubsan, check-ubsan-minimal, D40700 rdar://33660464 Differential Revision: https://reviews.llvm.org/D40698 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321231 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 18, 2017
-
-
Kostya Serebryany authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@321027 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 14, 2017
-
-
Aaron Ballman authored
Most attributes will now use the Clang<"name"> construct to provide both __attribute__((name)) and [[clang::name]] syntaxes for the attribute. Attributes deviating from this should be marked with a comment explaining why they are not supported under both spellings. Common reasons are: the attribute is provided by some other specification that controls the syntax or the attribute cannot be exposed under a particular spelling for some given reason. Because this is a mechanical change that only introduces new spellings, there are no test cases for the commit. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320752 91177308-0d34-0410-b5e6-96231b3b80d8
-
Alex Lorenz authored
builtin macros This patch implements the __is_target_arch, __is_target_vendor, __is_target_os, and __is_target_environment Clang preprocessor extensions that were proposed by @compnerd in Bob's cfe-dev post: http://lists.llvm.org/pipermail/cfe-dev/2017-November/056166.html. These macros can be used to examine the components of the target triple at compile time. A has_builtin(is_target_???) preprocessor check can be used to check for their availability. __is_target_arch allows you to check if an arch is specified without worring about a specific subarch, e.g. __is_target_arch(arm) returns 1 for the target arch "armv7" __is_target_arch(armv7) returns 1 for the target arch "armv7" __is_target_arch(armv6) returns 0 for the target arch "armv7" __is_target_vendor and __is_target_environment match the specific vendor or environment. __is_target_os matches the specific OS, but __is_target_os(darwin) will match any Darwin-based OS. "Unknown" can be used to test if the triple's component is specified. rdar://35753116 Differential Revision: https://reviews.llvm.org/D41087 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320734 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 11, 2017
-
-
Craig Topper authored
This adds a new command line option -mprefer-vector-width to specify a preferred vector width for the vectorizers. Valid values are 'none' and unsigned integers. The driver will check that it meets those constraints. Specific supported integers will be managed by the targets in the backend. Clang will take the value and add it as a new function attribute during CodeGen. This represents the alternate direction proposed by Sanjay in this RFC: http://lists.llvm.org/pipermail/llvm-dev/2017-November/118734.html The syntax here matches gcc, though gcc treats it as an x86 specific command line argument. gcc only allows values of 128, 256, and 512. I'm not having clang check any values. Differential Revision: https://reviews.llvm.org/D40230 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320419 91177308-0d34-0410-b5e6-96231b3b80d8
-
Craig Topper authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320418 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 09, 2017
-
-
Tim Northover authored
This is C++14 with conforming GNU extensions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320250 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 08, 2017
-
-
Kostya Serebryany authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320168 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 07, 2017
-
-
Aaron Ballman authored
This adds -std=c17, -std=gnu17, and -std=iso9899:2017 as language mode flags for C17 and updates the value of __STDC_VERSION__ to the value based on the C17 FDIS. Given that this ballot cannot succeed until 2018, it is expected that we (and GCC) will add c18 flags as aliases once the ballot passes. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320089 91177308-0d34-0410-b5e6-96231b3b80d8
-
Aaron Ballman authored
This behaves similar to the __has_cpp_attribute builtin macro in that it allows users to detect whether an attribute is supported with the [[]] spelling syntax, which can be enabled in C with -fdouble-square-bracket-attributes. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320088 91177308-0d34-0410-b5e6-96231b3b80d8
-
Kostya Serebryany authored
Summary: * use more readable name * document the hwasan attribute Reviewers: eugenis Reviewed By: eugenis Subscribers: llvm-commits, cfe-commits Differential Revision: https://reviews.llvm.org/D40938 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320075 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 05, 2017
-
-
Sylvestre Ledru authored
[clang-format] Releasenotes for rL319024 : Add option to group multiple #include blocks when sorting includes Summary: This change adds missing releasenotes for commit rL319024 https://reviews.llvm.org/rL319024 Patch by Krzysztof Kapusta Reviewers: sylvestre.ledru Reviewed By: sylvestre.ledru Differential Revision: https://reviews.llvm.org/D40827 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319748 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Dec 04, 2017
-
-
Kostya Serebryany authored
Summary: preliminary design document for a hardware-assisted memory safety (HWAMS) tool, similar to AddressSanitizer The name TaggedAddressSanitizer and the rest of the document, are early draft, suggestions are welcome. The code will follow shortly. Reviewers: eugenis, alekseyshl Reviewed By: eugenis Subscribers: davidxl, cryptoad, fedor.sergeev, cfe-commits, llvm-commits Differential Revision: https://reviews.llvm.org/D40568 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319684 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 30, 2017
-
-
Roman Lebedev authored
Summary: Currently clang static analyzer does warn on: ``` int x; x+=1; x-=1; x=x+1; x=x-1; ``` But does warn on: ``` int x; x++; x--; --x; ++x; ``` This differential should fix that. Fixes https://bugs.llvm.org/show_bug.cgi?id=35419 Reviewers: dcoughlin, NoQ Reviewed By: dcoughlin Subscribers: NoQ, xazax.hun, szepet, cfe-commits, a.sidorin Tags: #clang Differential Revision: https://reviews.llvm.org/D40463 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319411 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 29, 2017
-
-
Aaron Ballman authored
Patch by Julie Hockett. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319360 91177308-0d34-0410-b5e6-96231b3b80d8
-
Martell Malone authored
This is a re-apply of r319294. adds -fseh-exceptions and -fdwarf-exceptions flags clang will check if the user has specified an exception model flag, in the absense of specifying the exception model clang will then check the driver default and append the model flag for that target to cc1 -fno-exceptions has a higher priority then specifying the model move __SEH__ macro definitions out of Targets into InitPreprocessor behind the -fseh-exceptions flag move __ARM_DWARF_EH__ macrodefinitions out of verious targets and into InitPreprocessor behind the -fdwarf-exceptions flag and arm|thumb check remove unused USESEHExceptions from the MinGW Driver fold USESjLjExceptions into a new GetExceptionModel function that gives the toolchain classes more flexibility with eh models Reviewers: rnk, mstorsjo Differential Revision: https://reviews.llvm.org/D39673 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319297 91177308-0d34-0410-b5e6-96231b3b80d8
-
Martell Malone authored
This reverts rL319294. The windows sanitizer does not like seh on x86. Will re apply with None type for x86 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319295 91177308-0d34-0410-b5e6-96231b3b80d8
-
Martell Malone authored
adds -fseh-exceptions and -fdwarf-exceptions flags clang will check if the user has specified an exception model flag, in the absense of specifying the exception model clang will then check the driver default and append the model flag for that target to cc1 clang cc1 assumes dwarf is the default if none is passed and -fno-exceptions has a higher priority then specifying the model move __SEH__ macro definitions out of Targets into InitPreprocessor behind the -fseh-exceptions flag move __ARM_DWARF_EH__ macrodefinitions out of verious targets and into InitPreprocessor behind the -fdwarf-exceptions flag and arm|thumb check remove unused USESEHExceptions from the MinGW Driver fold USESjLjExceptions into a new GetExceptionModel function that gives the toolchain classes more flexibility with eh models Reviewers: rnk, mstorsjo Differential Revision: https://reviews.llvm.org/D39673 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319294 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 27, 2017
-
-
Krasimir Georgiev authored
Summary: This patch allows grouping multiple #include blocks together and sort all includes as one big block. Additionally, sorted includes can be regrouped after sorting based on configured categories. Contributed by @KrzysztofKapusta! Reviewers: krasimir Reviewed By: krasimir Subscribers: cfe-commits, klimek Differential Revision: https://reviews.llvm.org/D40288 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@319024 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 23, 2017
-
-
Adam Balogh authored
Two new matchers for `CXXNewExpr` are added which may be useful e.g. in `clang-tidy` checkers. One of them is `isArray` which matches `new[]` but not plain `new`. The other one, `hasArraySize` matches `new[]` for a given size. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318909 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 22, 2017
-
-
Peter Collingbourne authored
The default limit is 1000000 but it can be configured with a cache policy. The motivation is that some filesystems (notably ext4) have a limit on the number of files that can be contained in a directory (separate from the inode limit). Differential Revision: https://reviews.llvm.org/D40327 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318857 91177308-0d34-0410-b5e6-96231b3b80d8
-
Malcolm Parsons authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318827 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 21, 2017
-
-
Aaron Ballman authored
Add an AST matcher for hasDefaultArgument() to match on parameter declarations that have a default value. Patch by Julie Hockett. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318794 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 20, 2017
-
-
Craig Topper authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318672 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 17, 2017
-
-
Stephan Bergmann authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318530 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 14, 2017
-
-
Dave Lee authored
Summary: Allow the `isDefinition()` matcher to apply to `ObjCMethodDecl` nodes, in addition to those it already supports. For whatever reason, `ObjCMethodDecl` does not inherit from `FunctionDecl` and so this is specialization is necessary. Reviewers: aaron.ballman, malcolm.parsons, alexshap Reviewed By: aaron.ballman Subscribers: cfe-commits, klimek Differential Revision: https://reviews.llvm.org/D39948 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318152 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 13, 2017
-
-
Gabor Horvath authored
Differential Revision: https://reviews.llvm.org/D39543 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@318030 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 12, 2017
-
-
Dave Lee authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@317993 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 11, 2017
-
-
Dave Lee authored
Summary: Add AST matchers for Objective-C @throw, @try, @catch and @finally. Reviewers: aaron.ballman, malcolm.parsons, alexshap, compnerd Reviewed By: aaron.ballman Subscribers: cfe-commits, klimek Differential Revision: https://reviews.llvm.org/D39940 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@317992 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Nov 09, 2017
-
-
Krasimir Georgiev authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@317799 91177308-0d34-0410-b5e6-96231b3b80d8
-
Krasimir Georgiev authored
Summary: This patch improves using declarations sorting. Reviewers: bkramer Reviewed By: bkramer Subscribers: cfe-commits, klimek Differential Revision: https://reviews.llvm.org/D39786 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@317794 91177308-0d34-0410-b5e6-96231b3b80d8
-
Sam McCall authored
Summary: This is an alternative to JSONCompilationDatabase for simple projects that don't use a build system such as CMake. (You can also drop one in ~, to make your tools use e.g. C++11 by default) There's no facility for varying flags per-source-file or per-machine. Possibly this could be accommodated backwards-compatibly using cpp, but even if not the simplicity seems worthwhile for the cases that are addressed. Tested with clangd, works great! (requires clangd restart) Reviewers: klimek Subscribers: ilya-biryukov, cfe-commits Differential Revision: https://reviews.llvm.org/D39799 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@317777 91177308-0d34-0410-b5e6-96231b3b80d8
-