- Aug 14, 2014
-
-
DeLesley Hutchins authored
Thread safety analysis: add -Wthread-safety-verbose flag, which adds additional notes that are helpful when compiling statistics on thread safety warnings. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@215677 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Aug 09, 2014
-
-
Fariborz Jahanian authored
use mis-cased property name (which is currently accepted silently due to the way property setters are named). rdar://17911746 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@215250 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Aug 05, 2014
-
-
DeLesley Hutchins authored
a mutex is acquired, but corresponding mutex is not provably not-held. This is based on the earlier negative requirements patch. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@214789 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jul 29, 2014
-
-
Fariborz Jahanian authored
mismatch. //rdar://17845264 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@214203 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jul 25, 2014
-
-
Fariborz Jahanian authored
expression is a forward declaration as this results in undefined behavior. rdar://17768630 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213968 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jul 24, 2014
-
-
Reid Kleckner authored
Reviewers: rsmith, nlewycky Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D4636 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213817 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jul 21, 2014
-
-
Mark Heffernan authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213574 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jul 18, 2014
-
-
Tyler Nowicki authored
Clang uses a diagnostic handler to grab diagnostic messages so it can print them with the line of source code they refer to. This patch extends this to handle optimization failures that were added to llvm to produce a warning when loop vectorization is explicitly specified (using a pragma clang loop directive) but fails. Update renames warning flag name to avoid indicating the flag's severity and adds a test. Reviewed by Alp Toker git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213400 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jul 17, 2014
-
-
Alp Toker authored
This commit is missing tests and there are a few points that need to be addressed before a new user-facing option can be added: http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20140714/110198.html This reverts commit r213112. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213260 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jul 16, 2014
-
-
Tyler Nowicki authored
Clang uses a diagnostic handler to grab diagnostic messages so it can print them with the line of source code they refer to. This patch extends this to handle diagnostic warnings that were added to llvm to produce a warning when loop vectorization is explicitly specified (using a pragma clang loop directive) but fails. Reviewed by: Aaron Ballman git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213112 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jun 26, 2014
-
-
Justin Bogner authored
Improve the warning when building with -fprofile-instr-use and a file appears not to have been profiled at all. This keys on whether a function is defined in the main file or not to avoid false negatives when one includes a header with functions that have been profiled. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211760 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jun 22, 2014
-
-
Alp Toker authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211475 91177308-0d34-0410-b5e6-96231b3b80d8
-
Benjamin Kramer authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211464 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jun 16, 2014
-
-
Richard Smith authored
[C++1z] Implement N4051: 'typename' is permitted instead of 'class' when declaring a template template parameter. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211031 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jun 10, 2014
-
-
Alp Toker authored
It turns out the trailing '=' really is part of the option name spelling and treating it as such gets us compatible with GCC's -Werror= and pragmas. (GCC doesn't appear to support any -Wno- form for this diagnostic but we do.) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@210503 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jun 06, 2014
-
-
Richard Trieu authored
to detect underfined behavior involving pointers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@210372 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Jun 03, 2014
-
-
Alexander Musman authored
This patch implements semantic analysis to make sure that the loop is in OpenMP canonical form. This is the form required for 'omp simd', 'omp for' and other loop pragmas. Differential revision: http://reviews.llvm.org/D3778 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@210095 91177308-0d34-0410-b5e6-96231b3b80d8
-
- May 29, 2014
-
-
Diego Novillo authored
Summary: These two flags are in the same family as -Rpass, but are used in different situations. -Rpass-missed is used by optimizers to inform the user when they tried to apply an optimization but couldn't (or wouldn't). -Rpass-analysis is used by optimizers to report analysis results back to the user (e.g., why the transformation could not be applied). Depends on D3682. Reviewers: rsmith Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D3683 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@209839 91177308-0d34-0410-b5e6-96231b3b80d8
-
- May 28, 2014
-
-
Fariborz Jahanian authored
in Objective-C container declarations (but not in their definitions. // rdar://10414277 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@209751 91177308-0d34-0410-b5e6-96231b3b80d8
-
- May 14, 2014
-
-
Reid Kleckner authored
None of our tests use /fallback, so this lets us gradually add RTTI support without breaking projects using /fallback. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208787 91177308-0d34-0410-b5e6-96231b3b80d8
-
- May 08, 2014
-
-
Ben Langmuir authored
But keep -Wnon-modular-include-in-[framework-]module This warning is too noisy and doesn't really indicate a problem for most people. Even though it would only really affect people using -Weverything, that seems bad so remove it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208345 91177308-0d34-0410-b5e6-96231b3b80d8
-
- May 05, 2014
-
-
Ben Langmuir authored
Warn on non-modular includes in various contexts. -Wnon-modular-include -Wnon-modular-include-in-module -Wnon-modular-include-in-framework-module Where each group is a subgroup of those above it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@208004 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 23, 2014
-
-
Richard Trieu authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@207037 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 22, 2014
-
-
Alexander Musman authored
Differential Revision: http://reviews.llvm.org/D3272 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@206891 91177308-0d34-0410-b5e6-96231b3b80d8
-
Richard Smith authored
-Wc++11-compat-deprecated-writable-strings. It's neither a C++11 compatibility warning nor a deprecated feature, it's just ill-formed. In passing, add that warning to -Wdeprecated, where it belongs. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@206833 91177308-0d34-0410-b5e6-96231b3b80d8
-
Richard Trieu authored
-Wconversion and into it's own group, -Wfloating-point-conversion. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@206832 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 16, 2014
-
-
Diego Novillo authored
Summary: This patch adds a new flag -Rpass=. The flag indicates the name of the optimization pass that should emit remarks stating when it made a transformation to the code. This implements the design I proposed in: https://docs.google.com/document/d/1FYUatSjZZO-zmFBxjOiuOzAy9mhHA8hqdvklZv68WuQ/edit?usp=sharing Other changes: - Add DiagnosticIDs::isRemark(). Use it in printDiagnosticOptions to print "-R" instead of "-W" in the diagnostic message. - In BackendConsumer::OptimizationRemarkHandler, get a SourceLocation object out of the file name, line and column number. Use that location in the call to Diags.Report(). - When -Rpass is used without debug info a note is emitted alerting the user that they need to use -gline-tables-only -gcolumn-info to get this information. CC: llvm-commits Differential Revision: http://llvm-reviews.chandlerc.com/D3226 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@206401 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 15, 2014
-
-
Justin Bogner authored
This adds a warning that triggers when profile data doesn't match for the source that's being compiled with -fprofile-instr-use=. This fires only once per translation unit, as warning on every mismatched function would be quite noisy. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@206322 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 05, 2014
-
-
Richard Trieu authored
which warns on compound conditionals that always evaluate to the same value. For instance, (x > 5 && x < 3) will always be false since no value for x can satisfy both conditions. This patch also changes the CFG to use these tautological values for better branch analysis. The test for -Wunreachable-code shows how this change catches additional dead code. Patch by Anders Rönnholm. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@205665 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Apr 04, 2014
-
-
Reid Kleckner authored
This is consistent with -Wbuiltin-macro-redefined, and puts this common extension warning under a flag. Reviewers: rsmith Differential Revision: http://llvm-reviews.chandlerc.com/D3283 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@205591 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Mar 26, 2014
-
-
Richard Trieu authored
Previously, -Waddress was empty. Fixes PR9043. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204776 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Mar 21, 2014
-
-
Ted Kremenek authored
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204430 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Mar 15, 2014
-
-
Ted Kremenek authored
Further refine -Wunreachable-code groups so that -Wno-unreachable-code-break doesn't turn off all unreachable code warnings. Also relax unreachable 'break' and 'return' to not check for being preceded by a call to 'noreturn'. That turns out to not be so interesting in practice. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@204000 91177308-0d34-0410-b5e6-96231b3b80d8
-
Ted Kremenek authored
Recent work on -Wunreachable-code has focused on suppressing uninteresting unreachable code that center around "configuration values", but there are still some set of cases that are sometimes interesting or uninteresting depending on the codebase. For example, a dead "break" statement may not be interesting for a particular codebase, potentially because it is auto-generated or simply because code is written defensively. To address these workflow differences, -Wunreachable-code is now broken into several diagnostic groups: -Wunreachable-code: intended to be a reasonable "default" for most users. and then other groups that turn on more aggressive checking: -Wunreachable-code-break: warn about dead break statements -Wunreachable-code-trivial-return: warn about dead return statements that return "trivial" values (e.g., return 0). Other return statements that return non-trivial values are still reported under -Wunreachable-code (this is an area subject to more refinement). -Wunreachable-code-aggressive: supergroup that enables all these groups. The goal is to eventually make -Wunreachable-code good enough to either be in -Wall or on-by-default, thus finessing these warnings into different groups helps achieve maximum signal for more users. TODO: the tests need to be updated to reflect this extra control via diagnostic flags. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203994 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Mar 11, 2014
-
-
David Majnemer authored
This warning was missing a flag, add one. test/Misc/warning-flags.c has one fewer entry. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203522 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Mar 05, 2014
-
-
Richard Smith authored
Also promote a couple of Warnings on ill-formed code found by this testing to ExtWarns. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@203021 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Feb 28, 2014
-
-
Tobias Grosser authored
A 'remark' is information that is not an error or a warning, but rather some additional information provided to the user. In contrast to a 'note' a 'remark' is an independent diagnostic, whereas a 'note' always depends on another diagnostic. A typical use case for remark nodes is information provided to the user, e.g. information provided by the vectorizer about loops that have been vectorized. This patch provides the initial implementation of 'remarks'. It includes the actual definiton of the remark nodes, their printing as well as basic parameter handling. We are reusing the existing diagnostic parameters which means a remark can be enabled with normal '-Wdiagnostic-name' flags and can be upgraded to an error using '-Werror=diagnostic-name'. '-Werror' alone does not upgrade remarks. This patch is by intention minimal in terms of parameter handling. More experience and more discussions will most likely lead to further enhancements in the parameter handling. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202475 91177308-0d34-0410-b5e6-96231b3b80d8
-
Richard Smith authored
Add a -Wclass-varargs to warn on objects of any class type being passed through an ellipsis. Since C++11 relaxed the rules on this, we allow a lot more bad code through silently, such as: const char *format = "%s"; std::experimental::string_view view = "foo"; printf(format, view); In this case, not only warn about a class type being used here, but also suggest that calling c_str() might be a good idea. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202461 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Feb 27, 2014
-
-
John McCall authored
or virtual functions, but permit that error to be downgraded to a warning (with -Wno-error=incompatible-ms-struct), and officially support this kind of dual, ABI-mixing layout. The basic problem here is that projects which use ms_struct are often not very circumspect about what types they annotate; for example, some projects enable the pragma in a prefix header and then only selectively disable it around system header inclusions. They may only care about binary compatibility with MSVC for a subset of those structs, but that doesn't mean they have no binary compatibility concerns at all for the rest; thus we are essentially forced into supporting this hybrid ABI. But it's reasonable for us to at least point out the places where we're not making any guarantees. The original diagnostic was for dynamic classes, i.e. those with virtual functions or virtual bases; I've extended it to include all classes with bases, because we are not actually making any attempt to duplicate MSVC's base subobject layout in ms_struct (and it is indeed quite different from Itanium, even for non-virtual bases). rdar://16178895 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202427 91177308-0d34-0410-b5e6-96231b3b80d8
-
- Feb 26, 2014
-
-
Richard Trieu authored
null comparison when the pointer is known to be non-null. This catches the array to pointer decay, function to pointer decay and address of variables. This does not catch address of function since this has been previously used to silence a warning. Pointer to bool conversion is under -Wbool-conversion. Pointer to null comparison is under -Wtautological-pointer-compare, a sub-group of -Wtautological-compare. void foo() { int arr[5]; int x; // warn on these conditionals if (foo); if (arr); if (&x); if (foo == null); if (arr == null); if (&x == null); if (&foo); // no warning } git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202216 91177308-0d34-0410-b5e6-96231b3b80d8
-