| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
| |
Ref_Compatible_With_Added_Qualification. We always treated these two values the
same way.
llvm-svn: 284895
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This has two significant effects:
1) Direct relational comparisons between null pointer constants (0 and nullopt)
and pointers are now ill-formed. This was always the case for C, and it
appears that C++ only ever permitted by accident. For instance, cases like
nullptr < &a
are now rejected.
2) Comparisons and conditional operators between differently-cv-qualified
pointer types now work, and produce a composite type that both source
pointer types can convert to (when possible). For instance, comparison
between 'int **' and 'const int **' is now valid, and uses an intermediate
type of 'const int *const *'.
Clang previously supported #2 as an extension.
We do not accept the cases in #1 as an extension. I've tested a fair amount of
code to check that this doesn't break it, but if it turns out that someone is
relying on this, we can easily add it back as an extension.
This is a re-commit of r284800.
llvm-svn: 284890
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
SetVector already used DenseSet, but SmallSetVector used std::set. This
leads to surprising performance differences. Moreover, it means that
the set of key types accepted by SetVector and SmallSetVector are
quite different!
In order to make this change, we had to convert some callsites that used
SmallSetVector<std::string, N> to use SmallSetVector<CachedHashString, N>
instead.
Reviewers: timshen
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D25648
llvm-svn: 284887
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
clang-tidy's modernize-use-auto check uses the SourceRange of a
TypeLoc when replacing the type with auto.
This was producing the wrong result for multi-token builtin types
like long long:
-long long *ll = new long long();
+auto long *ll = new long long();
Reviewers: alexfh, hokein, rsmith, Prazek, aaron.ballman
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25363
llvm-svn: 284885
|
| |
|
|
|
|
|
|
| |
Instead of repeating the diagnostic, use "expected-note N".
Test-only change.
llvm-svn: 284882
|
| |
|
|
| |
llvm-svn: 284879
|
| |
|
|
|
|
| |
Thanks to Manman for spotting this.
llvm-svn: 284877
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Summary: NFC
Reviewers: rnk
Subscribers: cfe-commits
Differential Revision: https://reviews.llvm.org/D25797
llvm-svn: 284869
|
| |
|
|
| |
llvm-svn: 284856
|
| |
|
|
|
|
| |
Differential Revision: https://reviews.llvm.org/D25839
llvm-svn: 284843
|
| |
|
|
|
|
| |
Clang can generate LLVM IR for x86 without a registered x86 backend.
llvm-svn: 284836
|
| |
|
|
|
|
| |
This picked up a builtin header if it happened to be available.
llvm-svn: 284815
|
| |
|
|
|
|
|
|
| |
rules."
This reverts commit r284800, as it failed all ARM/AArch64 bots.
llvm-svn: 284811
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Previously, automatic semicolon insertion would add an unwrapped line
when a template string contained a line break.
var x = `foo${
bar}`;
Would be formatted with `bar...` on a separate line and no indent.
Reviewers: djasper
Subscribers: cfe-commits, klimek
Differential Revision: https://reviews.llvm.org/D25675
llvm-svn: 284807
|
| |
|
|
|
|
|
|
|
|
|
| |
we don't collapse that down to a single entry if it's not a redeclaration.
Instead, set the Redeclaration bit on the Declarator to indicate whether a
function is a redeclaration (which may not have been linked into the
redeclaration chain if it's a dependent context friend).
Fixes a rejects-valid; see testcase.
llvm-svn: 284802
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This has two significant effects:
1) Direct relational comparisons between null pointer constants (0 and nullopt)
and pointers are now ill-formed. This was always the case for C, and it
appears that C++ only ever permitted by accident. For instance, cases like
nullptr < &a
are now rejected.
2) Comparisons and conditional operators between differently-cv-qualified
pointer types now work, and produce a composite type that both source
pointer types can convert to (when possible). For instance, comparison
between 'int **' and 'const int **' is now valid, and uses an intermediate
type of 'const int *const *'.
Clang previously supported #2 as an extension.
We do not accept the cases in #1 as an extension. I've tested a fair amount of
code to check that this doesn't break it, but if it turns out that someone is
relying on this, we can easily add it back as an extension.
llvm-svn: 284800
|
| |
|
|
|
|
|
|
|
|
| |
Recent versions of ld64 run a deduplicate pass, which is on by default.
Disable the pass by using -no_deduplicate in certain condition and
enhance total compile time.
rdar://problem/25455336
llvm-svn: 284798
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
The 'no_undeclared_includes' attribute should be used in a module to
tell that only non-modular headers and headers from used modules are
accepted.
The main motivation behind this is to prevent dep cycles between system
libraries (such as darwin) and libc++.
Patch by Richard Smith!
llvm-svn: 284797
|
| |
|
|
| |
llvm-svn: 284794
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Tests fall into one of the following categories:
- The requirement was unnecessary
- Additional quoting was required for backslashes in paths (see "sed -e
's/\\/\\\\/g'") in the sanitizer tests.
- OpenMP used 'REQUIRES: shell' as a proxy for the test failing on
Windows. Those tests fail there reliably, so use XFAIL instead.
I tried not to remove shell requirements that were added to suppress
flaky test failures, but if I screwed up, we can add it back as needed.
llvm-svn: 284793
|
| |
|
|
|
|
|
|
|
|
| |
Original commit message:
[c++1z] Teach composite pointer type computation how to compute the composite
pointer type of two function pointers with different noexcept specifications.
While I'm here, also teach it how to merge dynamic exception specifications.
llvm-svn: 284785
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Code cleanup: address FIXME in the file
include/clang/Basic/FileManager.h and remove
copy-constructor of the class FileEntry.
Test plan: make check-clang
Differential revision: https://reviews.llvm.org/D22712
llvm-svn: 284782
|
| |
|
|
|
|
|
|
|
|
|
| |
windows bots"
This reverts commit r284174. The tests pass for me locally. It must have
been a 2015 only crash.
Fixes PR30699
llvm-svn: 284781
|
| |
|
|
|
|
|
|
| |
compute the composite"
It caused PR30749.
llvm-svn: 284778
|
| |
|
|
|
|
|
|
|
|
|
| |
This assert is intended to defend against backtracking into the middle
of a sequence of tokens that is being replaced with an annotation, but
it's OK if we backtrack to the exact position of the start of the
annotation sequence. Use a <= comparison instead of <.
Fixes PR25946
llvm-svn: 284777
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Refactor the DetectDistro() function to take a single vfs::FileSystem
reference only, instead of Driver and llvm::Triple::ArchType.
The ArchType parameter was not used anyway, and Driver was only used to
obtain the VFS.
Aside to making the API simpler and more transparent, it makes it
easier to add unit tests for the function in the future -- since
the tests would need only to provide an appropriate VFS.
Differential Revision: https://reviews.llvm.org/D25819
llvm-svn: 284774
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Replace the string matching for /etc/debian_version with split
integer/string matching algorithm. When the file contains 'major.minor'
version number, parse the major version as integer and use a switch
clause to match it. Otherwise, attempt 'codename/sid' matching using
a StringSwitch.
Differential Revision: https://reviews.llvm.org/D25696
llvm-svn: 284770
|
| |
|
|
|
|
|
|
|
|
| |
If we see a virtual method call to Base::foo() but can infer that the
object is an instance of Derived, and that 'foo' is marked 'final' in
Derived, we can devirtualize the call to Derived::foo().
Differential Revision: https://reviews.llvm.org/D25813
llvm-svn: 284766
|
| |
|
|
|
|
| |
struct with unnamed bitfields.
llvm-svn: 284761
|
| |
|
|
|
|
|
|
|
|
| |
With this patch, 75% of the intrinsics in this file will be documented now. The patches for the rest of the intrisics in this file will be send out later.
The doxygen comments are automatically generated based on Sony's intrinsics document.
I got an OK from Eric Christopher to commit doxygen comments without prior code review upstream. This patch was internally reviewed by Yunzhong Gao.
llvm-svn: 284754
|
| |
|
|
|
|
|
| |
pointer type of two function pointers with different noexcept specifications.
While I'm here, also teach it how to merge dynamic exception specifications.
llvm-svn: 284753
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The clang-cl test required x86-registered-target but it defaulted to the
host's triple and AArch64 still doesn't support COFF, so the test failed.
The triple was "aarch64-pc-windows-msvc18.0.0" with ObjectFormat equals
llvm::Triple::COFF, failing assertion:
Assertion `(TT.isOSBinFormatELF() || TT.isOSBinFormatMachO()) &&
"Only expect Darwin and ELF targets"
in AArch64MCTargetDesc.cpp:78.
Making the test only run on Windows hosts obviously fixes the problem.
llvm-svn: 284749
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
Remove colon and commas after replacing constructor body with = default.
Fix annotation of TT_CtorInitializerColon when preceded by a comment.
Reviewers: djasper
Subscribers: cfe-commits, klimek
Differential Revision: https://reviews.llvm.org/D25768
llvm-svn: 284732
|
| |
|
|
|
|
| |
No functionality change intended.
llvm-svn: 284730
|
| |
|
|
| |
llvm-svn: 284729
|
| |
|
|
|
|
|
| |
that a member is default-initializable even if it's initialized by a default
member initializer.
llvm-svn: 284701
|
| |
|
|
|
|
| |
from llvm/Support in r284681
llvm-svn: 284690
|
| |
|
|
|
|
| |
change intended.
llvm-svn: 284685
|
| |
|
|
| |
llvm-svn: 284684
|
| |
|
|
| |
llvm-svn: 284683
|
| |
|
|
|
|
|
|
|
|
| |
Preparation to implement DW_AT_alignment support:
- We pass non-zero align value to DIBuilder only when alignment was forced
- Modify tests to match this change
Differential Revision: https://reviews.llvm.org/D24426
llvm-svn: 284679
|
| |
|
|
|
|
| |
Walker for spotting the bug.
llvm-svn: 284673
|
| |
|
|
|
|
| |
also cover libstdc++'s std::__debug::array and std::__profile::array.
llvm-svn: 284669
|
| |
|
|
| |
llvm-svn: 284667
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This is needed by downstream projects such as swift to get proper cmake
dependency information for LLVM/Clang targets.
A few months ago I added support for exporting this information for Clang
libraries. In order to be incremental, I did not add support for exporting clang
tools as well at that time. Now such support is needed, so I am committing this
incremental code.
llvm-svn: 284658
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
corresponding arguments are unexpanded pack expansions, we can compute the
result without substituting them. This significantly improves the memory usage
and performance of make_integer_sequence implementations that do this kind of
thing:
using result = integer_sequence<T, Ns ..., sizeof...(Ns) + Ns ...>;
... but note that such an implementation will still perform O(sizeof...(Ns)^2)
work while building the second pack expansion (we just have a somewhat lower
constant now).
In principle we could get this down to linear time by caching whether the
number of expansions of a pack is constant, or checking whether we're within an
alias template before scanning the pack for pack expansions (since that's the
only case in which we do substitutions within a dependent context at the
moment), but this patch doesn't attempt that.
llvm-svn: 284653
|
| |
|
|
|
|
|
|
| |
Fixes regression from r279445.
Differential Revision: https://reviews.llvm.org/D25793
llvm-svn: 284652
|
| |
|
|
|
|
|
|
|
| |
LLVM now uses uint32_t for DebugInfo alignment for space efficiency,
in this patch we change frontend DebugInfo-related variables to uint32_t too.
Differential Revision: https://reviews.llvm.org/D25621
llvm-svn: 284651
|
| |
|
|
|
|
|
|
| |
Having this target allows other parts of the build system to add to the bootstrap dependencies without needing to be defined before the bootstrap targets are created.
This will specifically be used connect the builtins build from the LLVM runtimes directory as a dependency of the next build stage.
llvm-svn: 284648
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
callstack.
Summary:
Previously, when you did something not allowed in a host+device function
and then caused it to be codegen'ed, we would print out an error telling
you that you did something bad, but we wouldn't tell you how we decided
that the function needed to be codegen'ed.
This change causes us to print out a callstack when emitting deferred
errors. This is immensely helpful when debugging highly-templated code,
where it's often unclear how a function became known-emitted.
We only print the callstack once per function, after we print the all
deferred errors.
This patch also switches all of our hashtables to using canonical
FunctionDecls instead of regular FunctionDecls. This prevents a number
of bugs, some of which are caught by tests added here, in which we
assume that two FDs for the same function have the same pointer value.
Reviewers: rnk
Subscribers: cfe-commits, tra
Differential Revision: https://reviews.llvm.org/D25704
llvm-svn: 284647
|