OSDN Git Service
Joseph Huber [Thu, 7 Jan 2021 18:41:49 +0000 (13:41 -0500)]
[OpenMP] Add example in Libomptarget Information docs
Add an example to the OpenMP Documentation on the LIBOMPTARGET_INFO environment variable
Reviewed By: jdoerfert
Differential Revision: https://reviews.llvm.org/D94246
dfukalov [Fri, 25 Dec 2020 15:52:14 +0000 (18:52 +0300)]
[NFC][AMDGPU] Reduce include files dependency.
Reviewed By: rampitec
Differential Revision: https://reviews.llvm.org/D93813
Reid Kleckner [Thu, 7 Jan 2021 18:21:44 +0000 (10:21 -0800)]
Simplify vectorcall argument classification of HVAs, NFC
This reduces the number of `WinX86_64ABIInfo::classify` call sites from
3 to 1. The call sites were similar, but passed different values for
FreeSSERegs. Use variables instead of `if`s to manage that argument.
Sanjay Patel [Thu, 7 Jan 2021 19:06:10 +0000 (14:06 -0500)]
[SLP] remove opcode identifier for reduction; NFC
Another step towards allowing intrinsics in reduction matching.
Alex Zinenko [Thu, 7 Jan 2021 10:29:17 +0000 (11:29 +0100)]
[mlir] don't match the text produced only in debug mode in Python tests
Some Python bindings tests were using FileCheck to match parts of the
error description produced only in the debug compilation mode. Remove
these parts (but keep the main message) to ensure tests also pass when
running them in the release compilation mode.
Reviewed By: mehdi_amini
Differential Revision: https://reviews.llvm.org/D94221
Alex Zinenko [Wed, 6 Jan 2021 15:19:04 +0000 (16:19 +0100)]
[mlir] replace LLVMIntegerType with built-in integer type
The LLVM dialect type system has been closed until now, i.e. did not support
types from other dialects inside containers. While this has had obvious
benefits of deriving from a common base class, it has led to some simple types
being almost identical with the built-in types, namely integer and floating
point types. This in turn has led to a lot of larger-scale complexity: simple
types must still be converted, numerous operations that correspond to LLVM IR
intrinsics are replicated to produce versions operating on either LLVM dialect
or built-in types leading to quasi-duplicate dialects, lowering to the LLVM
dialect is essentially required to be one-shot because of type conversion, etc.
In this light, it is reasonable to trade off some local complexity in the
internal implementation of LLVM dialect types for removing larger-scale system
complexity. Previous commits to the LLVM dialect type system have adapted the
API to support types from other dialects.
Replace LLVMIntegerType with the built-in IntegerType plus additional checks
that such types are signless (these are isolated in a utility function that
replaced `isa<LLVMType>` and in the parser). Temporarily keep the possibility
to parse `!llvm.i32` as a synonym for `i32`, but add a deprecation notice.
Reviewed By: mehdi_amini, silvas, antiagainst
Differential Revision: https://reviews.llvm.org/D94178
Wouter van Oortmerssen [Wed, 6 Jan 2021 00:58:21 +0000 (16:58 -0800)]
[WebAssembly] Fixed byval args missing DWARF DW_AT_LOCATION
A struct in C passed by value did not get debug information. Such values are currently
lowered to a Wasm local even in -O0 (not to an alloca like on other archs), which becomes
a Target Index operand (TI_LOCAL). The DWARF writing code was not emitting locations
in for TI's specifically if the location is a single range (not a list).
In addition, the ExplicitLocals pass which removes the ARGUMENT pseudo instructions did
not update the associated DBG_VALUEs, and couldn't even find these values since the code
assumed such instructions are adjacent, which is not the case here.
Also fixed asm printing of TIs needed by a test.
Differential Revision: https://reviews.llvm.org/D94140
Matt Arsenault [Fri, 22 Feb 2019 18:15:39 +0000 (13:15 -0500)]
CodeGen: Refactor regallocator command line and target selection
Make the sequence of passes to select and rewrite instructions to
physical registers be a target callback. This is to prepare to allow
targets to split register allocation into multiple phases.
Hiroshi Yamauchi [Wed, 6 Jan 2021 22:42:26 +0000 (14:42 -0800)]
[PGO][PGSO] Let unroll hints take precedence over PGSO.
Differential Revision: https://reviews.llvm.org/D94199
Alexandre Ganea [Sun, 27 Dec 2020 19:15:50 +0000 (14:15 -0500)]
Silence warning: comparison of integers of different signs: 'const unsigned int' and 'const long' [-Wsign-compare]
(off_t being a signed type)
Mircea Trofin [Thu, 7 Jan 2021 16:26:45 +0000 (08:26 -0800)]
[NFC] Removed unused prefixes from CodeGen/AMDGPU
Last bulk batch.
Differential Revision: https://reviews.llvm.org/D94236
Mehdi Amini [Thu, 7 Jan 2021 17:42:55 +0000 (17:42 +0000)]
Fix GCC5 build, require explicit this->... in this call inside a lambda (NFC)
Error was:
mlir/lib/Dialect/LLVMIR/IR/LLVMDialect.cpp:2247:36: error: cannot call member function 'mlir::LLVM::FastmathFlags mlir::LLVM::FMFAttr::getFlags() const' without object
return bitEnumContains(getFlags(), flag);
^
Eric Schweitz [Thu, 7 Jan 2021 17:38:21 +0000 (09:38 -0800)]
Alan Phipps [Wed, 6 Jan 2021 23:40:32 +0000 (17:40 -0600)]
[Coverage] Refactor three tests from commit rG9f2967bcfe2f
Refactor three tests to not depend on other test files as input but to instead
refer to "Inputs" subdirectory.
Erich Keane [Thu, 17 Dec 2020 20:09:11 +0000 (12:09 -0800)]
Add element-type to the Vector TypeLoc types.
As shown by bug 48540, GCC vector types would cause a crash when the
declaration hada ParenType. This was because the walking of the
declaration would try to expand the 'inner' type, but there was no
ability to get it from the vector type. This patch adds that element
type access to the vector type loc objects.
Differential Revision: https://reviews.llvm.org/D93483
Thomas Preud'homme [Tue, 1 Dec 2020 18:08:31 +0000 (18:08 +0000)]
[AST][NFC] Silence GCC warning about multiline comments
Remove continuation line in code snippet to prevent GCC warning about
multiline comments (-Wcomment) when building a project using libclang
with GCC.
Reviewed By: rjmccall
Differential Revision: https://reviews.llvm.org/D92409
Kazuaki Ishizaki [Thu, 7 Jan 2021 17:09:48 +0000 (02:09 +0900)]
[mlir] NFC: fix trivial typos
fix typo under include and lib directories
Reviewed By: antiagainst
Differential Revision: https://reviews.llvm.org/D94220
Jeroen Dobbelaere [Thu, 7 Jan 2021 17:03:56 +0000 (17:03 +0000)]
[NFC] make clang/test/CodeGen/arm_neon_intrinsics.c resistent to function attribute id changes
When introducing support for @llvm.experimental.noalias.scope.decl, this tests started failing because it checks
(for no good reason) for a function attribute id of '#8' which now becomes '#9'
Reviewed By: pratlucas
Differential Revision: https://reviews.llvm.org/D94233
Eric Schweitz [Tue, 5 Jan 2021 00:32:48 +0000 (16:32 -0800)]
Adds argument attributes for using LLVM's sret and byval attributes to
the conversion of LLVM IR dialect. These attributes are used in FIR to
support the lowering of Fortran using target-specific calling
conventions.
Add roundtrip tests. Add changes per review comments/concerns.
Reviewed By: ftynse
Differential Revision: https://reviews.llvm.org/D94052
Varun Gandhi [Thu, 17 Dec 2020 01:01:12 +0000 (17:01 -0800)]
[IR] Use LLVM_ENABLE_ABI_BREAKING_CHECKS to guard ABI changes.
Incorrect usage of NDEBUG to guard ABI changes can prevent clients
from enabling assertions for their C++ code while having assertions in
LLVM turned off. So we use LLVM_ENABLE_ABI_BREAKING_CHECKS instead, as
described in llvm/docs/ProgrammersManual.rst. Most types already use this
macro, however, there were a couple of stragglers in ValueHandle.h, which
are fixed by this revision.
Reviewed By: dblaikie, dexonsmith
Differential Revision: https://reviews.llvm.org/D93433
Mircea Trofin [Wed, 6 Jan 2021 18:34:21 +0000 (10:34 -0800)]
[NFC] Removed unused prefixes in CodeGen/AMDGPU
This covers tests starting with s.
Differential Revision: https://reviews.llvm.org/D94184
Cameron McInally [Thu, 7 Jan 2021 15:47:50 +0000 (09:47 -0600)]
[SVE] Add unpacked scalable floating point ZIP/UZP/TRN patterns
Differential Revision: https://reviews.llvm.org/D94193
Bardia Mahjour [Thu, 7 Jan 2021 15:51:14 +0000 (10:51 -0500)]
[DDG] Data Dependence Graph - DOT printer tests
Adds some tests to check the formatting of the dot
file produced when using -dot-ddg.
Reviewed By: Meinersbur
Differential Revision: https://reviews.llvm.org/D93949
Matt Arsenault [Tue, 7 Jul 2020 21:49:52 +0000 (17:49 -0400)]
AMDGPU/GlobalISel: Start cleaning up calling convention lowering
There are various hacks working around limitations in
handleAssignments, and the logical split between different parts isn't
correct. Start separating the type legalization to satisfy going
through the DAG infrastructure from the code required to split into
register types. The type splitting should be moved to generic code.
Bardia Mahjour [Thu, 7 Jan 2021 15:31:11 +0000 (10:31 -0500)]
[DDG] Fix duplicate edge removal during pi-block formation
When creating pi-blocks we try to avoid creating duplicate edges
between outside nodes and the pi-block when an edge is of the
same kind and direction as another one that has already been
created. We do this by keeping track of the edges in an
enumerated array called EdgeAlreadyCreated. The problem is that
this array is declared local to the loop that iterates over the
nodes in the pi-block, so the information gets lost every time a
new inside-node is iterated over. The fix is to move the
declaration to the outer loop.
Reviewed By: Meinersbur
Differential Revision: https://reviews.llvm.org/D94094
Roman Lebedev [Thu, 7 Jan 2021 15:04:37 +0000 (18:04 +0300)]
[SimplifyCFG] FoldValueComparisonIntoPredecessors(): drop reachable errneous assert
I have added it in
d15d81c because it *seemed* correct, was holding
for all the tests so far, and was validating the fix added in the same
commit, but as David Major is pointing out (with a reproducer),
the assertion isn't really correct after all. So remove it.
Note that the
d15d81c still fine.
Roman Lebedev [Thu, 7 Jan 2021 14:28:25 +0000 (17:28 +0300)]
[llvm-reduce] ReduceGlobalVarInitializers delta pass: fix handling of globals w/ comdat/non-external linkage
Much like with ReduceFunctionBodies delta pass,
we need to remove comdat and set linkage to external,
else verifier will complain, and our deltas are invalid.
Sidharth Baveja [Thu, 7 Jan 2021 14:49:23 +0000 (14:49 +0000)]
[SplitEdge] Add new parameter to SplitEdge to name the newly created basic block
Summary:
Currently SplitEdge does not support passing in parameter which allows you to
name the newly created BasicBlock.
This patch updates the function such that the name of the block can be passed
in, if users of this utility decide to do so.
Reviewed By: Whitney, bmahjour, asbirlea, jamieschmeiser
Differential Revision: https://reviews.llvm.org/D94176
Paul C. Anagnostopoulos [Thu, 31 Dec 2020 19:50:51 +0000 (14:50 -0500)]
[TableGen] Add field kind to the RecordVal class.
Differential Revision: https://reviews.llvm.org/D93969
Valentin Clement [Thu, 7 Jan 2021 14:25:00 +0000 (09:25 -0500)]
[flang][openacc] Enforce delcare directive restriction
Add semantic check for most of the restrictions for the declare directive.
Reviewed By: kiranktp
Differential Revision: https://reviews.llvm.org/D92741
Simon Pilgrim [Thu, 7 Jan 2021 14:21:29 +0000 (14:21 +0000)]
[AArch64] SVEIntrinsicOpts - use range loop and cast<> instead of dyn_cast<> for dereferenced pointer. NFCI.
Don't directly dereference a dyn_cast<> - use cast<> so we assert for the correct type.
Also, simplify the for loop to a range loop.
Fixes clang static analyzer warning.
Simon Pilgrim [Thu, 7 Jan 2021 13:58:13 +0000 (13:58 +0000)]
[Analysis] MemoryDepChecker::couldPreventStoreLoadForward - remove dead store. NFCI.
As we're breaking from the loop when clamping MaxVF, clang static analyzer was warning that the VF iterator was being updated and never used.
Andrzej Warzynski [Thu, 7 Jan 2021 14:03:39 +0000 (14:03 +0000)]
[flang][driver] Rename driver tests (nfc)
As per [1]:
```
File names should use dashes, not underscores.
```
This patch updates the names of Flang driver tests accordingly.
[1] https://github.com/llvm/llvm-project/blob/main/flang/docs/C%2B%2Bstyle.md
Caroline Concatto [Thu, 7 Jan 2021 09:07:06 +0000 (09:07 +0000)]
[AArch64][CostModel]Fix gather scatter cost model
This patch fixes a bug introduced in the patch:
https://reviews.llvm.org/D93030
This patch pulls the test for scalable vector to be the first instruction
to be checked. This avoids the Gather and Scatter cost model for AArch64 to
compute the number of vector elements for something that is not a vector and
therefore crashing.
Jan Svoboda [Wed, 6 Jan 2021 14:18:43 +0000 (15:18 +0100)]
[clang][cli] NFC: Make parsing macro reusable
This is necessary for a future patch, where we start using this macro in another function.
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D93702
Alex Zinenko [Thu, 7 Jan 2021 13:19:30 +0000 (14:19 +0100)]
[mlir] remove a use of deprecated OpState::setAttr
Jan Svoboda [Wed, 6 Jan 2021 13:58:19 +0000 (14:58 +0100)]
[clang][cli] NFC: Move parseSimpleArgs
This patch moves `parseSimpleArgs` closer to `ParseDiagnosticArgs` so that sharing the parsing macro between them can be done more locally in a future patch.
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D94172
Jan Svoboda [Tue, 22 Dec 2020 14:05:16 +0000 (15:05 +0100)]
[clang][cli] NFC: Ensure non-null DiagnosticsEngine in ParseDiagnosticArgs
Before this patch, ParseDiagnosticArgs can be called with a nullptr DiagnosticsEngine *. This happens early on in the compilation process, where no proper DiagnosticEngine exists, because the diagnostic options (passed through command line) are not known yet.
This patch ensures nullptr is replaced by an ignoring DiagnosticEngine in ParseDiagnosticArgs, which allows to switch from pointer to a reference in some utility functions.
Besides simplifying the code, this patch enables a future patch (D84673) that ports diagnostic options to the new marshalling infrastructure.
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D93701
Ivan Butygin [Thu, 7 Jan 2021 12:56:37 +0000 (13:56 +0100)]
[mlir] Add fastmath flags support to some LLVM dialect ops
Add fastmath enum, attributes to some llvm dialect ops, `FastmathFlagsInterface` op interface, and `translateModuleToLLVMIR` support.
Reviewed By: ftynse
Differential Revision: https://reviews.llvm.org/D92485
Simon Pilgrim [Thu, 7 Jan 2021 12:34:11 +0000 (12:34 +0000)]
[llvm-objdump] Pass Twine by const reference instead of by value. NFCI.
Simon Pilgrim [Thu, 7 Jan 2021 12:23:01 +0000 (12:23 +0000)]
[DWARF] DWARFDebugLoc::dumpRawEntry - remove dead stores. NFCI.
Don't bother zeroing local (unused) variables just before returning.
Fixes clang static analyzer warning.
Simon Pilgrim [Thu, 7 Jan 2021 12:15:01 +0000 (12:15 +0000)]
[CompilationDatabase] Pass Twine by const reference instead of by value. NFCI.
Alexey Bataev [Fri, 1 Jan 2021 16:43:33 +0000 (08:43 -0800)]
[SLP]Need shrink the load vector after reordering.
After merging the shuffles, we cannot rely on the previous shuffle
anymore and need to shrink the final shuffle, if it is required.
Reported in D92668
Differential Revision: https://reviews.llvm.org/D93967
Sam McCall [Thu, 7 Jan 2021 10:40:33 +0000 (11:40 +0100)]
[clangd] Add server capability advertising hot-reloading of CDBs.
Currently some clients watch for CDB changes and restart clangd, now that we
can reload compile_commands.json ourselves this is counterproductive.
The capability allows this behavior to be phased out.
This is going to be a mild regression, as we do not actually watch for files on
disk and so new diagnostics need to wait until a rebuild is requested e.g. due
to file change (and the internal caches have expired).
However this is still a better tradeoff (and if it's important, we can request
the client to watch files for us in the future).
Differential Revision: https://reviews.llvm.org/D94222
Alex Zinenko [Tue, 5 Jan 2021 15:04:00 +0000 (16:04 +0100)]
[mlir] Refactor translation of OpenMP dialect ops to LLVM IR
The original implementation of the OpenMP dialect to LLVM IR translation has
been relying on a stack of insertion points for delayed insertion of branch
instructions that correspond to terminator ops. This is an intrusive into
ModuleTranslation and makes the translation non-local. A recent addition of the
WsLoop translation exercised another approach where the parent op is
responsible for converting terminators of all blocks in its regions. Use this
approach for other OpenMP dialect operations with regions, remove the stack and
deduplicate the code for converting such regions.
Reviewed By: kiranchandramohan
Differential Revision: https://reviews.llvm.org/D94086
Marek Kurdej [Thu, 7 Jan 2021 11:29:04 +0000 (12:29 +0100)]
[libc++] Use c++20 instead of c++2a consistently.
* The only exception is that the flag -std=c++2a is still used not to break compatibility with older compilers (clang <= 9, gcc <= 9).
* Bump _LIBCPP_STD_VER for C++20 to 20 and use 21 for the future standard (C++2b).
That's a preparation step to add c++2b support to libc++.
Reviewed By: ldionne, #libc
Differential Revision: https://reviews.llvm.org/D93383
Mikhail Maltsev [Thu, 7 Jan 2021 12:06:08 +0000 (12:06 +0000)]
[libcxx] Mark a test as unsupported for C++03
The nullptr_t_integral_cast.pass.cpp test is currently xfailed for
C++03, but actually, it only fails with the first version of libc++
ABI.
This patch changes XFAIL to UNSUPPORTED to avoid unexpected passes
with ABI v2 or later.
Reviewed By: ldionne, #libc
Differential Revision: https://reviews.llvm.org/D93941
Simon Pilgrim [Thu, 7 Jan 2021 12:02:50 +0000 (12:02 +0000)]
[DAG] Simplify OR(X,SHL(Y,BW/2)) eq/ne 0/-1 'all/any-of' style patterns
Attempt to simplify all/any-of style patterns that concatenate 2 smaller integers together into an and(x,y)/or(x,y) + icmp 0/-1 instead.
This is mainly to help some bool predicate reduction patterns where we end up concatenating bool vectors that have been bitcasted to integers.
Differential Revision: https://reviews.llvm.org/D93599
Jan Svoboda [Tue, 22 Dec 2020 14:00:31 +0000 (15:00 +0100)]
[clang][cli] Report the actual argument parsing result
Reviewed By: Bigcheese
Differential Revision: https://reviews.llvm.org/D93700
Marek Kurdej [Thu, 7 Jan 2021 11:02:56 +0000 (12:02 +0100)]
[libc++] [CI] Install Tip-of-Trunk clang.
* Check created symlinks.
Reviewed By: ldionne, #libc
Differential Revision: https://reviews.llvm.org/D93520
Jan Svoboda [Tue, 22 Dec 2020 09:01:51 +0000 (10:01 +0100)]
[clang][cli] Port getAllArgumentValues to the marshalling infrastructure
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D93679
Andrzej Warzynski [Thu, 7 Jan 2021 09:08:54 +0000 (09:08 +0000)]
[flang][driver] Add support for `-c` and `-emit-obj`
This patch adds a frontend action for emitting object files. While Flang
does not support code-generation, this action remains a placeholder.
This patch simply provides glue-code to connect the compiler driver
with the appropriate frontend action.
The new action is triggered with the `-c` compiler driver flag, i.e.
`flang-new -c`. This is then translated to `flang-new -fc1 -emit-obj`,
so `-emit-obj` has to be marked as supported as well.
As code-generation is not available yet, `flang-new -c` results in a
driver error:
```
error: code-generation is not available yet
```
Hopefully this will help communicating the level of available
functionality within Flang.
The definition of `emit-obj` is updated so that it can be shared between
Clang and Flang. As the original definition was enclosed within a
Clang-specific TableGen `let` statement, it is extracted into a new `let`
statement. That felt like the cleanest option.
I also commented out `-triple` in Flang::ConstructJob and updated some
comments there. This is similar to https://reviews.llvm.org/D93027. I
wanted to make sure that it's clear that we can't support `-triple`
until we have code-generation. However, once code-generation is
available we _will need_ `-triple`.
As this patch adds `-emit-obj`, the emit-obj.f90 becomes irrelevant and
is deleted. Instead, phases.f90 is added to demonstrate that users can
control compilation phases (indeed, `-c` is a phase control flag).
Reviewed By: SouraVX, clementval
Differential Revision: https://reviews.llvm.org/D93301
Jan Svoboda [Mon, 21 Dec 2020 15:35:32 +0000 (16:35 +0100)]
[clang][cli] Port a CommaJoined option to the marshalling infrastructure
Reviewed By: dexonsmith
Differential Revision: https://reviews.llvm.org/D93698
David Spickett [Tue, 5 Jan 2021 11:46:18 +0000 (11:46 +0000)]
[lldb][ARM/AArch64] Update disasm flags to latest v8.7a ISA
Add optional memory tagging extension on AArch64.
Use isAArch64() instead of listing the AArch64 triples,
which fixes us not recognising aarch64_be.
Reviewed By: omjavaid
Differential Revision: https://reviews.llvm.org/D94084
Balázs Kéri [Thu, 7 Jan 2021 07:41:08 +0000 (08:41 +0100)]
[clang][ASTImporter] Fix a possible assertion failure `NeedsInjectedClassNameType(Decl)'.
The assertion can happen if ASTImporter imports a CXXRecordDecl in a template
and then imports another redeclaration of this declaration, while the first import is in progress.
The process of first import did not set the "described template" yet
and the second import finds the first declaration at setting the injected types.
Setting the injected type requires in the assertion that the described template is set.
The exact assertion was:
clang/lib/AST/ASTContext.cpp:4411:
clang::QualType clang::ASTContext::getInjectedClassNameType(clang::CXXRecordDecl*, clang::QualType) const:
Assertion `NeedsInjectedClassNameType(Decl)' failed.
Reviewed By: shafik
Differential Revision: https://reviews.llvm.org/D94067
Jan Svoboda [Thu, 7 Jan 2021 09:14:48 +0000 (10:14 +0100)]
Reapply "[clang][cli] Allow users to specify a conditional to prevent parsing options with MarshallingInfo"
This reverts commit
d0fa7a05 and fixes failing OptionMarshallingTest by adding the SHOULD_PARSE macro argument
Fraser Cormack [Tue, 5 Jan 2021 11:55:03 +0000 (11:55 +0000)]
[RISCV] Add vector mask arithmetic ISel patterns
The patterns that want to use 'vnot' use a custom PatFrag. This is
because 'vnot' uses immAllOnesV which implicitly uses BUILD_VECTOR
rather than SPLAT_VECTOR.
Reviewed By: craig.topper
Differential Revision: https://reviews.llvm.org/D94078
Oliver Stannard [Thu, 7 Jan 2021 09:43:33 +0000 (09:43 +0000)]
Revert "[llvm] Use BasicBlock::phis() (NFC)"
Reverting because this causes crashes on the 2-stage buildbots, for
example http://lab.llvm.org:8011/#/builders/7/builds/1140.
This reverts commit
9b228f107d43341ef73af92865f73a9a076c5a76.
Jan Svoboda [Thu, 7 Jan 2021 09:12:53 +0000 (10:12 +0100)]
Revert "[clang][cli] Allow users to specify a conditional to prevent parsing options with MarshallingInfo"
This reverts commit
77db83ae
Jan Svoboda [Mon, 21 Dec 2020 15:13:43 +0000 (16:13 +0100)]
[clang][cli] Implement ContainsN Google Test matcher
This allows us to verify that we don't emit options multiple times.
In most cases, that would be benign, but for options with `MarshallingInfoVectorString`, emitting wrong number of arguments might change the semantics.
Reviewed By: Bigcheese
Differential Revision: https://reviews.llvm.org/D93636
Jan Svoboda [Fri, 18 Dec 2020 14:02:43 +0000 (15:02 +0100)]
[clang][cli] Allow users to specify a conditional to prevent parsing options with MarshallingInfo
Depends on D84189 & D93540.
Reviewed By: Bigcheese
Differential Revision: https://reviews.llvm.org/D84674
LLVM GN Syncbot [Thu, 7 Jan 2021 08:29:23 +0000 (08:29 +0000)]
[gn build] Port
d2ddc694ff9
Artem Dergachev [Wed, 6 Jan 2021 14:35:09 +0000 (06:35 -0800)]
Revert "Revert "[analyzer] NFC: Move path diagnostic consumer implementations to libAnalysis.""
This reverts commit
5663bf201f5c444d6fb56fb1bd471bc53c17d837.
The cyclic dependency problem is addressed now.
This is the ~fifth attempt to land this change.
Christian Sigg [Thu, 7 Jan 2021 06:52:37 +0000 (07:52 +0100)]
[mlir] Mark methods from mlir::OpState that just forward to mlir::Operation as deprecated.
The functions will be removed by January 20th.
All call sites within MLIR have been converted in previous changes.
Reviewed By: rriddle
Differential Revision: https://reviews.llvm.org/D94191
Martin Storsjö [Wed, 28 Oct 2020 10:24:11 +0000 (12:24 +0200)]
[libcxx] Handle backslash as path separator on windows
Differential Revision: https://reviews.llvm.org/D91138
Martin Storsjö [Wed, 30 Dec 2020 21:02:01 +0000 (23:02 +0200)]
[LLD] [MinGW] Pass the --demangle and --no-demangle options to the COFF linker
Differential Revision: https://reviews.llvm.org/D93950
Gil Rapaport [Thu, 7 Jan 2021 07:01:02 +0000 (09:01 +0200)]
[LV] Merge tests into a single file (NFC)
In response to https://reviews.llvm.org/D94088#inline-879268
River Riddle [Thu, 7 Jan 2021 06:24:05 +0000 (22:24 -0800)]
[mlir][ODS] Fix missed rename of TypeParameter 'description' to 'summary'
This fixes document generation for type parameters.
Ganesh Gopalasubramanian [Wed, 6 Jan 2021 19:29:38 +0000 (00:59 +0530)]
[X86] Update tests for znver3
Differential Revision: https://reviews.llvm.org/D92812
Kazushi (Jam) Marukawa [Thu, 7 Jan 2021 03:23:38 +0000 (12:23 +0900)]
[VE][NFC] Update comments to match the generated instructions
Fangrui Song [Thu, 7 Jan 2021 05:58:40 +0000 (21:58 -0800)]
[PowerPC] Delete dead Lower*
Fangrui Song [Thu, 7 Jan 2021 05:40:40 +0000 (21:40 -0800)]
[PowerPC] Delete remnant Darwin ISelLowering code
Fangrui Song [Thu, 7 Jan 2021 05:18:35 +0000 (21:18 -0800)]
[PowerPC] Delete remnant isOSDarwin references
Chris Lattner [Thu, 7 Jan 2021 01:38:37 +0000 (17:38 -0800)]
Update for review feedback: Inline var declaration and expand names.
Depends on D93908.
Differential Revision: https://reviews.llvm.org/D94208
Chris Lattner [Tue, 29 Dec 2020 19:05:45 +0000 (11:05 -0800)]
[AsmPrinter] Make OpAsmPrinter::printFunctionalType be resilient to null values.
A previous patch made Value::getType() be resilient to null values which was
considered to be too sweeping. This is a more targeted change which requires
deabstracting some templates.
A middle ground would be to make ValueTypeIterator be tolerant to null values.
Differential Revision: https://reviews.llvm.org/D93908
Fangrui Song [Thu, 7 Jan 2021 04:39:07 +0000 (20:39 -0800)]
[debuginfo-test] Fix -Wunused-value
Sanjoy Das [Wed, 6 Jan 2021 17:46:43 +0000 (09:46 -0800)]
[NFC] Don't copy MachineFrameInfo on each invocation of HasAlias
Also fix a typo in a comment. This fixes a compile time issue in XLA
(https://www.tensorflow.org/xla).
Differential Revision: https://reviews.llvm.org/D94182
Nathan James [Thu, 7 Jan 2021 02:40:20 +0000 (02:40 +0000)]
[clangd][NFC] Use PathRef for getCorrespondingHeaderOrSource
Kazu Hirata [Thu, 7 Jan 2021 02:27:36 +0000 (18:27 -0800)]
[llvm] Use llvm::all_of (NFC)
Kazu Hirata [Thu, 7 Jan 2021 02:27:35 +0000 (18:27 -0800)]
[llvm] Use BasicBlock::phis() (NFC)
Kazu Hirata [Thu, 7 Jan 2021 02:27:33 +0000 (18:27 -0800)]
[llvm] Use llvm::append_range (NFC)
Jonas Devlieghere [Thu, 7 Jan 2021 01:10:20 +0000 (17:10 -0800)]
[lldb] Skip scoped enum checks with Dwarf <4
The scoped enum tests depend on DW_AT_enum_class which was added in
Dwarf 4.
I made part of the test conditional on the Dwarf version instead of
splitting it into a separate test and using the decorator to avoid the
overhead of setting up the test.
Michał Górny [Fri, 20 Nov 2020 08:44:33 +0000 (09:44 +0100)]
[lldb] [debugserver] Add stN aliases for stmmN for compatibility
Add stN aliases for the FPU (stmmN) registers on MacOSX. This should
improve compatibility between MacOSX and other platforms, and partially
fix x86*-fp-write tests without having to duplicate them. Note that
the tests are currently still broken due to ftag incompatibility.
Differential Revision: https://reviews.llvm.org/D91847
Juneyoung Lee [Sun, 3 Jan 2021 17:02:19 +0000 (02:02 +0900)]
[InstSimplify] Fold insertelement vec, poison, idx into vec
This is a simple patch that adds folding from `insertelement vec, poison, idx` into `vec`.
Alive2 proof: https://alive2.llvm.org/ce/z/2y2vbC
Reviewed By: nikic
Differential Revision: https://reviews.llvm.org/D93994
Juneyoung Lee [Thu, 7 Jan 2021 01:08:01 +0000 (10:08 +0900)]
[Constant] Add tests for ConstantVector::get (NFC)
Varun Gandhi [Wed, 6 Jan 2021 22:34:20 +0000 (14:34 -0800)]
[NFC] Move readAPValue/writeAPValue up the inheritance hierarchy
The implementation for (de)serialization of APValues can be shared
between Clang and Swift, so we prefer pushing the methods up
the inheritance hierarchy, instead of having the methods live in
ASTReader/ASTWriter. Fixes rdar://
72592937.
Reviewed By: rjmccall
Differential Revision: https://reviews.llvm.org/D94196
Craig Topper [Wed, 6 Jan 2021 23:59:30 +0000 (15:59 -0800)]
[RISCV] Fix a few section number comments in RISCVInstrInfoVPseudos.td to match the V extension 1.0 draft spec. NFC
The majority of the comments use the 1.0 draft spec section numbers.
Pedro Tammela [Wed, 16 Dec 2020 21:34:44 +0000 (21:34 +0000)]
[lldb/Lua] add support for multiline scripted breakpoints
1 - Partial Statements
The interpreter loop runs every line it receives, so partial
Lua statements are not being handled properly. This is a problem for
multiline breakpoint scripts since the interpreter loop, for this
particular case, is just an abstraction to a partially parsed function
body declaration.
This patch addresses this issue and as a side effect improves the
general Lua interpreter loop as well. It's now possible to write partial
statements in the 'script' command.
Example:
(lldb) script
>>> do
..> local a = 123
..> print(a)
..> end
123
The technique implemented is the same as the one employed by Lua's own REPL implementation.
Partial statements always errors out with the '<eof>' tag in the error
message.
2 - CheckSyntax in Lua.h
In order to support (1), we need an API for just checking the syntax of string buffers.
3 - Multiline scripted breakpoints
Finally, with all the base features implemented this feature is
straightforward. The interpreter loop behaves exactly the same, the
difference is that it will aggregate all Lua statements into the body of
the breakpoint function. An explicit 'quit' statement is needed to exit the
interpreter loop.
Example:
(lldb) breakpoint command add -s lua
Enter your Lua command(s). Type 'quit' to end.
The commands are compiled as the body of the following Lua function
function (frame, bp_loc, ...) end
..> print(456)
..> a = 123
..> quit
Differential Revision: https://reviews.llvm.org/D93481
Juneyoung Lee [Thu, 7 Jan 2021 00:24:39 +0000 (09:24 +0900)]
[Constant] Update ConstantVector::get to return poison if all input elems are poison
The diff was reviewed at D93994
Daniel Hwang [Wed, 6 Jan 2021 23:35:06 +0000 (15:35 -0800)]
[analyzer] Update Fuchsia checker to catch releasing unowned handles.
Certain Fuchsia functions may return handles that are not owned by the
current closure. This adds a check in order to determine when these
handles are released.
Differential Revision: https://reviews.llvm.org/D93868
Kit Barton [Wed, 6 Jan 2021 22:48:41 +0000 (16:48 -0600)]
[PPC] Remove old PPCSubTarget variable.
The PPCSubTarget variable has been replaced with the Subtarget variable. This
removes the remaining instances of PPCSubTarget as they are no longer necessary.
Arthur O'Dwyer [Wed, 16 Dec 2020 00:32:29 +0000 (19:32 -0500)]
[libc++] ADL-proof vector<bool> by adding _VSTD:: qualification on calls.
This affects only vectors with weird/malicious allocators,
the same corner case covered in D91708, but for `vector<bool>` this time.
Also ADL-proof <__tree>, which affects only sets and maps with weird/malicious
allocators where the ADL trap is in the *fancy pointer type*.
Also drive-by _VSTD:: qualification in the guts of std::bind,
std::packaged_task, std::condition_variable.
Differential Revision: https://reviews.llvm.org/D93424
Jonas Devlieghere [Wed, 6 Jan 2021 22:37:17 +0000 (14:37 -0800)]
[lldb] Ad os_signpost support to lldb_private::Timer
Emit os_signposts when supported from LLDB's timer class. A vast amount
of performance sensitive places in LLDB are already instrumented with
the Timer class.
By emitting signposts we can examine this information in Instruments. I
recommend looking at Daniel's differential for why this is so powerful:
https://reviews.llvm.org/D52954.
Differential revision: https://reviews.llvm.org/D93657
Jonas Devlieghere [Wed, 6 Jan 2021 22:35:07 +0000 (14:35 -0800)]
[Support] Untie the llvm::Signpost interface from llvm::Timer
Make llvm::Signpost more generic by untying from llvm::Timer. This
allows signposts to be used in a different context.
My motivation for doing this is being able to use signposts in LLDB.
Differential revision: https://reviews.llvm.org/D93655
Thomas Raoux [Wed, 6 Jan 2021 17:34:50 +0000 (09:34 -0800)]
[mlir][vector] Support transfer op on tensor optimizations
Support store to load forwarding and dead store transformations for transfer op
on tensor.
Differential Revision: https://reviews.llvm.org/D94148
Siva Chandra Reddy [Wed, 6 Jan 2021 22:39:07 +0000 (14:39 -0800)]
[libc] Use a wrapper for rand instead of calling std::rand in fma tests.
Reviewed By: lntue
Differential Revision: https://reviews.llvm.org/D94198
River Riddle [Wed, 6 Jan 2021 22:54:39 +0000 (14:54 -0800)]
[mlir][TypeDefGen] Remove the need to define parser/printer for singleton types
This allows for singleton types without an explicit parser/printer to simply use
the mnemonic as the assembly format, removing the need for these types to provide the parser/printer
fields.
Differential Revision: https://reviews.llvm.org/D94194
Amara Emerson [Wed, 6 Jan 2021 22:40:17 +0000 (14:40 -0800)]
Fix failing triple test for macOS 11 with non-zero minor versions.
Differential Revision: https://reviews.llvm.org/D94197
Alina Sbirlea [Mon, 14 Dec 2020 19:53:35 +0000 (11:53 -0800)]
[DominatorTree] Add support for mixed pre/post CFG views.
Add support for mixed pre/post CFG views.
Update usages of the MemorySSAUpdater to use the new DT API by
requesting the DT updates to be done by the MSSAUpdater.
Differential Revision: https://reviews.llvm.org/D93371
Hansang Bae [Wed, 6 Jan 2021 22:14:37 +0000 (16:14 -0600)]
[OpenMP] Use c_int/c_size_t in Fortran target memory routine interface
The Fortran interface is now in line with 5.1 specification.
Differential Revision: https://reviews.llvm.org/D94042