Revision tags: llvmorg-7.0.1, llvmorg-7.0.1-rc3 |
|
#
407659ab |
| 30-Nov-2018 |
Fangrui Song <maskray@google.com> |
Revert "Revert r347417 "Re-Reinstate 347294 with a fix for the failures.""
It seems the two failing tests can be simply fixed after r348037
Fix 3 cases in Analysis/builtin-functions.cpp Delete the
Revert "Revert r347417 "Re-Reinstate 347294 with a fix for the failures.""
It seems the two failing tests can be simply fixed after r348037
Fix 3 cases in Analysis/builtin-functions.cpp Delete the bad CodeGen/builtin-constant-p.c for now
llvm-svn: 348053
show more ...
|
#
f5d3335d |
| 30-Nov-2018 |
Fangrui Song <maskray@google.com> |
Revert r347417 "Re-Reinstate 347294 with a fix for the failures."
Kept the "indirect_builtin_constant_p" test case in test/SemaCXX/constant-expression-cxx1y.cpp while we are investigating why the fo
Revert r347417 "Re-Reinstate 347294 with a fix for the failures."
Kept the "indirect_builtin_constant_p" test case in test/SemaCXX/constant-expression-cxx1y.cpp while we are investigating why the following snippet fails:
extern char extern_var; struct { int a; } a = {__builtin_constant_p(extern_var)};
llvm-svn: 348039
show more ...
|
#
48ee4ad3 |
| 28-Nov-2018 |
Hans Wennborg <hans@hanshq.net> |
Re-commit r347417 "Re-Reinstate 347294 with a fix for the failures."
This was reverted in r347656 due to me thinking it caused a miscompile of Chromium. Turns out it was the Chromium code that was b
Re-commit r347417 "Re-Reinstate 347294 with a fix for the failures."
This was reverted in r347656 due to me thinking it caused a miscompile of Chromium. Turns out it was the Chromium code that was broken.
llvm-svn: 347756
show more ...
|
#
8c79706e |
| 27-Nov-2018 |
Hans Wennborg <hans@hanshq.net> |
Revert r347417 "Re-Reinstate 347294 with a fix for the failures."
This caused a miscompile in Chrome (see crbug.com/908372) that's illustrated by this small reduction:
static bool f(int *a, int *
Revert r347417 "Re-Reinstate 347294 with a fix for the failures."
This caused a miscompile in Chrome (see crbug.com/908372) that's illustrated by this small reduction:
static bool f(int *a, int *b) { return !__builtin_constant_p(b - a) || (!(b - a)); }
int arr[] = {1,2,3};
bool g() { return f(arr, arr + 3); }
$ clang -O2 -S -emit-llvm a.cc -o -
g() should return true, but after r347417 it became false for some reason.
This also reverts the follow-up commits.
r347417: > Re-Reinstate 347294 with a fix for the failures. > > Don't try to emit a scalar expression for a non-scalar argument to > __builtin_constant_p(). > > Third time's a charm!
r347446: > The result of is.constant() is unsigned.
r347480: > A __builtin_constant_p() returns 0 with a function type.
r347512: > isEvaluatable() implies a constant context. > > Assume that we're in a constant context if we're asking if the expression can > be compiled into a constant initializer. This fixes the issue where a > __builtin_constant_p() in a compound literal was diagnosed as not being > constant, even though it's always possible to convert the builtin into a > constant.
r347531: > A "constexpr" is evaluated in a constant context. Make sure this is reflected > if a __builtin_constant_p() is a part of a constexpr.
llvm-svn: 347656
show more ...
|
#
6ff1751f |
| 21-Nov-2018 |
Bill Wendling <isanbard@gmail.com> |
Re-Reinstate 347294 with a fix for the failures.
Don't try to emit a scalar expression for a non-scalar argument to __builtin_constant_p().
Third time's a charm!
llvm-svn: 347417
|
#
9f0246d4 |
| 21-Nov-2018 |
Nico Weber <nicolasweber@gmx.de> |
Revert r347364 again, the fix was incomplete.
llvm-svn: 347389
|
#
91549ed1 |
| 20-Nov-2018 |
Bill Wendling <isanbard@gmail.com> |
Reinstate 347294 with a fix for the failures.
EvaluateAsInt() is sometimes called in a constant context. When that's the case, we need to specify it as so.
llvm-svn: 347364
|
Revision tags: llvmorg-7.0.1-rc2, llvmorg-7.0.1-rc1, llvmorg-7.0.0, llvmorg-7.0.0-rc3, llvmorg-7.0.0-rc2, llvmorg-7.0.0-rc1 |
|
#
99337e24 |
| 20-Jul-2018 |
Fangrui Song <maskray@google.com> |
Change \t to spaces
llvm-svn: 337530
|
Revision tags: llvmorg-6.0.1, llvmorg-6.0.1-rc3, llvmorg-6.0.1-rc2 |
|
#
8419cf30 |
| 26-May-2018 |
Artem Dergachev <artem.dergachev@gmail.com> |
[analyzer] Add security checks for bcmp(), bcopy(), bzero().
These functions are obsolete. The analyzer would advice to replace them with memcmp(), memcpy() or memmove(), or memset().
Patch by Tom
[analyzer] Add security checks for bcmp(), bcopy(), bzero().
These functions are obsolete. The analyzer would advice to replace them with memcmp(), memcpy() or memmove(), or memset().
Patch by Tom Rix!
Differential Revision: https://reviews.llvm.org/D41881
llvm-svn: 333326
show more ...
|
Revision tags: llvmorg-6.0.1-rc1, llvmorg-5.0.2, llvmorg-5.0.2-rc2, llvmorg-5.0.2-rc1, llvmorg-6.0.0, llvmorg-6.0.0-rc3, llvmorg-6.0.0-rc2, llvmorg-6.0.0-rc1 |
|
#
1ebd1c4f |
| 12-Jan-2018 |
Artem Dergachev <artem.dergachev@gmail.com> |
[analyzer] Don't flag strcpy of string literals into sufficiently large buffers.
In the security package, we have a simple syntactic check that warns about strcpy() being insecure, due to potential
[analyzer] Don't flag strcpy of string literals into sufficiently large buffers.
In the security package, we have a simple syntactic check that warns about strcpy() being insecure, due to potential buffer overflows.
Suppress that check's warning in the trivial situation when the source is an immediate null-terminated string literal and the target is an immediate sufficiently large buffer.
Patch by András Leitereg!
Differential Revision: https://reviews.llvm.org/D41384
llvm-svn: 322410
show more ...
|
Revision tags: llvmorg-5.0.1, llvmorg-5.0.1-rc3, llvmorg-5.0.1-rc2, llvmorg-5.0.1-rc1 |
|
#
50657f6b |
| 06-Sep-2017 |
George Karpenkov <ekarpenkov@apple.com> |
[CSA] [NFC] Move AnalysisContext.h to AnalysisDeclContext.h
The implementation is in AnalysisDeclContext.cpp and the class is called AnalysisDeclContext.
Making those match up has numerous benefits
[CSA] [NFC] Move AnalysisContext.h to AnalysisDeclContext.h
The implementation is in AnalysisDeclContext.cpp and the class is called AnalysisDeclContext.
Making those match up has numerous benefits, including:
- Easier jump from header to/from implementation. - Easily identify filename from class.
Differential Revision: https://reviews.llvm.org/D37500
llvm-svn: 312671
show more ...
|
Revision tags: llvmorg-5.0.0, llvmorg-5.0.0-rc5, llvmorg-5.0.0-rc4, llvmorg-5.0.0-rc3, llvmorg-5.0.0-rc2, llvmorg-5.0.0-rc1 |
|
#
2b9657b5 |
| 21-Jul-2017 |
Erich Keane <erich.keane@intel.com> |
Remove Bitrig: Clang Changes
Bitrig code has been merged back to OpenBSD, thus the OS has been abandoned.
Differential Revision: https://reviews.llvm.org/D35708
llvm-svn: 308797
|
Revision tags: llvmorg-4.0.1, llvmorg-4.0.1-rc3, llvmorg-4.0.1-rc2, llvmorg-4.0.1-rc1, llvmorg-4.0.0, llvmorg-4.0.0-rc4, llvmorg-4.0.0-rc3, llvmorg-4.0.0-rc2, llvmorg-4.0.0-rc1, llvmorg-3.9.1, llvmorg-3.9.1-rc3, llvmorg-3.9.1-rc2, llvmorg-3.9.1-rc1, llvmorg-3.9.0, llvmorg-3.9.0-rc3, llvmorg-3.9.0-rc2, llvmorg-3.9.0-rc1, llvmorg-3.8.1, llvmorg-3.8.1-rc1, llvmorg-3.8.0, llvmorg-3.8.0-rc3, llvmorg-3.8.0-rc2, llvmorg-3.8.0-rc1, llvmorg-3.7.1 |
|
#
2a3ca840 |
| 26-Nov-2015 |
Pierre Gousseau <pierregousseau14@gmail.com> |
Test commit Remove tabs.
llvm-svn: 254181
|
Revision tags: llvmorg-3.7.1-rc2, llvmorg-3.7.1-rc1 |
|
#
3a0678e3 |
| 08-Sep-2015 |
Ted Kremenek <kremenek@apple.com> |
[analyzer] Apply whitespace cleanups by Honggyu Kim.
llvm-svn: 246978
|
Revision tags: llvmorg-3.7.0, llvmorg-3.7.0-rc4, llvmorg-3.7.0-rc3, studio-1.4, llvmorg-3.7.0-rc2, llvmorg-3.7.0-rc1 |
|
#
973431b2 |
| 03-Jul-2015 |
Benjamin Kramer <benny.kra@googlemail.com> |
Rewrite users of Stmt::child_begin/end into for-range loops.
No functionality change intended.
llvm-svn: 241355
|
Revision tags: llvmorg-3.6.2, llvmorg-3.6.2-rc1 |
|
#
ab9db510 |
| 22-Jun-2015 |
Alexander Kornienko <alexfh@google.com> |
Revert r240270 ("Fixed/added namespace ending comments using clang-tidy").
llvm-svn: 240353
|
#
3d9d929e |
| 22-Jun-2015 |
Alexander Kornienko <alexfh@google.com> |
Fixed/added namespace ending comments using clang-tidy. NFC
The patch is generated using this command:
$ tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \ -checks=-*,llvm-namespace-comme
Fixed/added namespace ending comments using clang-tidy. NFC
The patch is generated using this command:
$ tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \ -checks=-*,llvm-namespace-comment -header-filter='llvm/.*|clang/.*' \ work/llvm/tools/clang
To reduce churn, not touching namespaces spanning less than 10 lines.
llvm-svn: 240270
show more ...
|
Revision tags: llvmorg-3.6.1, llvmorg-3.6.1-rc1, llvmorg-3.5.2, llvmorg-3.5.2-rc1 |
|
#
e5bdc851 |
| 11-Mar-2015 |
Ed Schouten <ed@nuxi.nl> |
Enable security checks for arc4random() on CloudABI as well.
CloudABI also supports the arc4random() function. We can enable compiler warnings for rand(), random() and *rand48() on this system as we
Enable security checks for arc4random() on CloudABI as well.
CloudABI also supports the arc4random() function. We can enable compiler warnings for rand(), random() and *rand48() on this system as well.
llvm-svn: 231914
show more ...
|
Revision tags: llvmorg-3.6.0, llvmorg-3.6.0-rc4, llvmorg-3.6.0-rc3, llvmorg-3.6.0-rc2, llvmorg-3.6.0-rc1, llvmorg-3.5.1, llvmorg-3.5.1-rc2, llvmorg-3.5.1-rc1, llvmorg-3.5.0, llvmorg-3.5.0-rc4, llvmorg-3.5.0-rc3, llvmorg-3.5.0-rc2, llvmorg-3.5.0-rc1 |
|
#
0dbb783c |
| 27-May-2014 |
Craig Topper <craig.topper@gmail.com> |
[C++11] Use 'nullptr'. StaticAnalyzer edition.
llvm-svn: 209642
|
Revision tags: llvmorg-3.4.2, llvmorg-3.4.2-rc1 |
|
#
c3f36af8 |
| 15-May-2014 |
Alp Toker <alp@nuanti.com> |
Fix typos
llvm-svn: 208838
|
Revision tags: llvmorg-3.4.1, llvmorg-3.4.1-rc2, llvmorg-3.4.1-rc1 |
|
#
4aca9b1c |
| 11-Feb-2014 |
Alexander Kornienko <alexfh@google.com> |
Expose the name of the checker producing each diagnostic message.
Summary: In clang-tidy we'd like to know the name of the checker producing each diagnostic message. PathDiagnostic has BugType and C
Expose the name of the checker producing each diagnostic message.
Summary: In clang-tidy we'd like to know the name of the checker producing each diagnostic message. PathDiagnostic has BugType and Category fields, which are both arbitrary human-readable strings, but we need to know the exact name of the checker in the form that can be used in the CheckersControlList option to enable/disable the specific checker.
This patch adds the CheckName field to the CheckerBase class, and sets it in the CheckerManager::registerChecker() method, which gets them from the CheckerRegistry.
Checkers that implement multiple checks have to store the names of each check in the respective registerXXXChecker method.
Reviewers: jordan_rose, krememek
Reviewed By: jordan_rose
CC: cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D2557
llvm-svn: 201186
show more ...
|
#
9cacbabd |
| 20-Jan-2014 |
Alp Toker <alp@nuanti.com> |
Rename FunctionProtoType accessors from 'arguments' to 'parameters'
Fix a perennial source of confusion in the clang type system: Declarations and function prototypes have parameters to which argume
Rename FunctionProtoType accessors from 'arguments' to 'parameters'
Fix a perennial source of confusion in the clang type system: Declarations and function prototypes have parameters to which arguments are supplied, so calling these 'arguments' was a stretch even in C mode, let alone C++ where default arguments, templates and overloading make the distinction important to get right.
Readability win across the board, especially in the casting, ADL and overloading implementations which make a lot more sense at a glance now.
Will keep an eye on the builders and update dependent projects shortly.
No functional change.
llvm-svn: 199686
show more ...
|
Revision tags: llvmorg-3.4.0, llvmorg-3.4.0-rc3, llvmorg-3.4.0-rc2, llvmorg-3.4.0-rc1 |
|
#
42b4248f |
| 07-Oct-2013 |
Jordan Rose <jordan_rose@apple.com> |
[analyzer] ArrayRef-ize BugReporter::EmitBasicReport.
No functionality change.
llvm-svn: 192114
|
Revision tags: llvmorg-3.3.1-rc1 |
|
#
57d1f1c8 |
| 24-Jun-2013 |
Eli Friedman <eli.friedman@gmail.com> |
Use getAs<> where appropriate on QualTypes instead of using dyn_cast.
llvm-svn: 184775
|
#
7f62b954 |
| 24-Jun-2013 |
Reid Kleckner <reid@kleckner.net> |
Check the canonical parameter type with getAs<>() in a static checker
This will prevent breakage when I introduce the DecayedType sugar node.
llvm-svn: 184755
|