Brendon Cahoon [Wed, 6 Apr 2022 01:53:46 +0000 (20:53 -0500)]
[UnifyLoopExits] Reduce number of guard blocks
UnifyLoopExits creates a single exit, a control flow hub, for
loops with multiple exits. There is an input to the block for
each loop exiting block and an output from the block for each
loop exit block. Multiple checks, or guard blocks, are needed
to branch to the correct exit block.
For large loops with lots of exit blocks, all the extra guard
blocks cause problems for StructurizeCFG and subsequent passes.
This patch reduces the number of guard blocks needed when the
exit blocks branch to a common block (e.g., an unreachable
block). The guard blocks are reduced by changing the inputs
and outputs of the control flow hub. The inputs are the exit
blocks and the outputs are the common block.
Reducing the guard blocks enables StructurizeCFG to reorder the
basic blocks in the CFG to reduce the values that exit a loop
with multiple exits. This reduces the compile-time of
StructurizeCFG and also reduces register pressure.
Differential Revision: https://reviews.llvm.org/D123230
Evgenii Stepanov [Wed, 22 Jun 2022 18:19:56 +0000 (11:19 -0700)]
Revert "[Attributor] Ensure to use the proper liveness AA"
Reason: memory leaks
This reverts commit
083010312aa4a0ba0cd5299bd3b039af8fb6d58f.
Nathan James [Wed, 22 Jun 2022 20:37:16 +0000 (21:37 +0100)]
[clang-tidy][docs] Fix a couple of missed cases from
6e566bc5523
A few of the checks had documentation URLs that weren't updated in the aforementioned commit.
Valentin Clement [Wed, 22 Jun 2022 20:32:21 +0000 (22:32 +0200)]
[flang] Capture result interface of functions called in internal procedures
Character and array results are allocated on the caller side. This
require evaluating the result interface on the call site. When calling
such functions inside an internal procedure, it is possible that the
interface is defined in the host, in which case the lengths/bounds of
the function results must be captured so that they are available in
the internal function to emit the call.
To handle this case, extend the PFT symbol visit to visit the bounds and length
parameters of functions called in the internal procedure parse tree.
This patch is part of the upstreaming effort from fir-dev branch.
Reviewed By: klausler
Differential Revision: https://reviews.llvm.org/D128371
Co-authored-by: Jean Perier <jperier@nvidia.com>
Nathan James [Wed, 22 Jun 2022 20:21:24 +0000 (21:21 +0100)]
[clang-tidy][docs] Reorganise release notes
Jim Ingham [Wed, 22 Jun 2022 19:16:24 +0000 (12:16 -0700)]
Fix a bug with "process continue -b" when no breakpoints are
passed. I was passing the empty list of breakponts to the
VerifyBreakpointList routine, but that treats empty as "choose
the default breakpoint" which we don't want here.
Nicolas Vasilache [Tue, 21 Jun 2022 12:11:29 +0000 (05:11 -0700)]
[mlir][Linalg] SplitReduction implementation without tensor::ExpandShapeOp
This revision proposes a different implementation of the SplitReductoin transformation that does
not rely on tensor::ExpandShapeOp.
Previously, a dimension `[k]` would be split into `[k][kk]` via an ExpandShapeOp.
Instead, this revision proposes to rewrite `[k]` into `[factor * k + kk]`.
There are different tradeoffs involved but the proposed implementation is more general because
the affine rewrite is well-defined. In particular, it works naturally with `?` parallel dimensions and
non-trivial indexing maps.
A further rewrite of `[factor * k + kk]` + ExpandShapeOp is possible as a followup.
Differential Revision: https://reviews.llvm.org/D128266
Guillaume Gomez [Wed, 22 Jun 2022 18:48:31 +0000 (19:48 +0100)]
Rename GCCBuiltin into ClangBuiltin
This patch is needed because developers expect "GCCBuiltin" items to be the GCC intrinsics equivalent and not the Clang internals.
Reviewed By: #libc_abi, RKSimon, xbolva00
Differential Revision: https://reviews.llvm.org/D127460
Valentin Clement [Wed, 22 Jun 2022 18:47:48 +0000 (20:47 +0200)]
[flang] Remove some auto
This patch replaces some `auto` with proper type. This was done in fir-dev
but not upstreamed yet.
This patch is part of the upstreaming effort from fir-dev branch.
Reviewed By: klausler
Differential Revision: https://reviews.llvm.org/D128350
Valentin Clement [Wed, 22 Jun 2022 18:46:30 +0000 (20:46 +0200)]
[flang] Handle BINC(C) variables and add TODO for corner cases
- BIND(C) was ignored in lowering for objects (it can be used on
module and common blocks): use the bind name as the fir.global name.
- When an procedure is declared BIND(C) indirectly via an interface,
it should have a BIND(C) name. This was not the case because
GetBindName()/bindingName() return nothing in this case: detect this
case in mangler.cpp and use the symbol name.
Add TODOs for corner cases:
- BIND(C) module variables may be initialized on the C side. This does
not fit well with the current linkage strategy. Add a TODO until this
is revisited.
- BIND(C) internal procedures should not have a binding label (see
Fortran 2018 section 18.10.2 point 2), yet we currently lower them as
if they were BIND(C) external procedure.
I think this and the indirect interface case should really be
handled by symbol.GetBindName instead of adding more logic in
lowering to deal with this case: add a TODO.
This patch is part of the upstreaming effort from fir-dev branch.
Reviewed By: klausler
Differential Revision: https://reviews.llvm.org/D128340
Co-authored-by: Jean Perier <jperier@nvidia.com>
Joe Loser [Wed, 22 Jun 2022 17:25:43 +0000 (11:25 -0600)]
[libc++] Clarify std::function release note
Replace "This option it" with "This option" to make the sentence read a bit
clearer.
Differential Revision: https://reviews.llvm.org/D128362
Florian Mayer [Tue, 14 Jun 2022 22:41:27 +0000 (15:41 -0700)]
[MTE] [HWASan] Support diamond lifetimes.
We were overly conservative and required a ret statement to be dominated
completely be a single lifetime.end marker. This is quite restrictive
and leads to two problems:
* limits coverage of use-after-scope, as we degenerate to
use-after-return;
* increases stack usage in programs, as we have to remove all lifetime
markers if we degenerate to use-after-return, which prevents
reuse of stack slots by the stack coloring algorithm.
Reviewed By: eugenis
Differential Revision: https://reviews.llvm.org/D127905
Walter Erquinigo [Sat, 18 Jun 2022 22:44:37 +0000 (15:44 -0700)]
[trace] Add an option to dump instructions in json and to a file
In order to provide simple scripting support on top of instruction traces, a simple solution is to enhance the `dump instructions` command and allow printing in json and directly to a file. The format is verbose and not space efficient, but it's not supposed to be used for really large traces, in which case the TraceCursor API is the way to go.
- add a -j option for printing the dump in json
- add a -J option for pretty printing the json output
- add a -F option for specifying an output file
- add a -a option for dumping all the instructions available starting at the initial point configured with the other flags
- add tests for all cases
- refactored the instruction dumper and abstracted the actual "printing" logic. There are two writer implementations: CLI and JSON. This made the dumper itself much more readable and maintanable
sample output:
```
(lldb) thread trace dump instructions -t -a --id 100 -J
[
{
"id": 100,
"tsc": "
43591204528448966"
"loadAddress": "0x407a91",
"module": "a.out",
"symbol": "void std::deque<Foo, std::allocator<Foo>>::_M_push_back_aux<Foo>(Foo&&)",
"mnemonic": "movq",
"source": "/usr/include/c++/8/bits/deque.tcc",
"line": 492,
"column": 30
},
...
```
Differential Revision: https://reviews.llvm.org/D128316
Richard [Fri, 17 Jun 2022 01:02:47 +0000 (19:02 -0600)]
[clang-tidy] Organize test files into subdirectories by module (NFC)
Eliminate clutter by reorganizing the Lit test files for clang-tidy:
- Move checkers/<module>-* to checkers/<module>/*.
- Move module specific inputs from Inputs to <module>/Inputs. Remove
any module prefix from the file or subdirectory name as they are no
longer needed.
- Introduce a Lit substitution %clang_tidy_headers for the system
headers in checkers/Inputs/Headers and use this throughout. This
avoids referencing system headers through a relative path to the
parent directory and makes it clear that these fake system headers are
shared among all modules.
- Update add_new_check.py to follow the above conventions when creating
the boiler plate test files for a new check.
- Update Contributing.rst to describe per-module Inputs directory and
fix link to test source code.
Differential Revision: https://reviews.llvm.org/D128072
Alexander Yermolovich [Wed, 22 Jun 2022 17:52:19 +0000 (10:52 -0700)]
[LLDB] Handle DIE with DW_AT_low_pc and empty ranges
The case comes out of how BOLT handles transformation of
DW_AT_low_pc/DW_AT_high_pc into DW_AT_low_pc/DW_AT_high_pc
with latter being 0.
Reviewed By: clayborg
Differential Revision: https://reviews.llvm.org/D127889
Florian Mayer [Wed, 15 Jun 2022 22:54:12 +0000 (15:54 -0700)]
[NFC] [HWASan] Remove indirection for getting analyses.
This was necessary for code reuse between the old and new passmanager.
With the old pass-manager gone, this is no longer necessary.
Reviewed By: eugenis, myhsu
Differential Revision: https://reviews.llvm.org/D127913
Argyrios Kyrtzidis [Wed, 22 Jun 2022 17:49:31 +0000 (10:49 -0700)]
[Support/BLAKE3] Fix error in prior commit, apply `-mavx512vl` for `blake3_avx512_x86-64_unix.S` when including it
Alvin Wong [Wed, 22 Jun 2022 17:48:01 +0000 (20:48 +0300)]
[lldb] Second attempt at fixing command-target-create-resolve-exe.test on the buildbot
Mark de Wever [Tue, 14 Jun 2022 15:47:51 +0000 (17:47 +0200)]
[libc++][NFC] Merges unused functions in callers.
This is a follow up based on a request of @jloser in D127594.
As drive-by qualified the function calls in the <bit> header.
Reviewed By: #libc, EricWF
Differential Revision: https://reviews.llvm.org/D127760
Joseph Huber [Wed, 22 Jun 2022 15:17:14 +0000 (11:17 -0400)]
[LinkerWrapper][NFC] Change interface to use a StringRef to TempFiles
Summary:
Currently we use temporary files to write the intermediate results to.
However, these are stored as regular strings and we do a few unnecessary
copies and conversions of them. This patch simply replaces these strings
with a reference to the filename stored in the list of temporary files.
The temporary files will stay alive during the whole linking phase and
have stable pointers, so we should be able to cheaply pass references to
them rather than copying them every time.
Mingming Liu [Fri, 17 Jun 2022 15:49:04 +0000 (08:49 -0700)]
[Support] Change TrackingStatistic and NoopStatistic to use uint64_t instead of unsigned.
Binary size of `clang` is trivial; namely, numerical value doesn't
change when measured in MiB, and `.data` section increases from 139Ki to
173 Ki.
Differential Revision: https://reviews.llvm.org/D128070
lorenzo chelini [Wed, 22 Jun 2022 17:04:40 +0000 (19:04 +0200)]
[MLIR] Fix top-level comment (NFC)
Daniel Thornburgh [Fri, 29 Apr 2022 19:09:19 +0000 (19:09 +0000)]
[Symbolize] Parse multi-line markup elements.
This allows registering certain tags as possibly beginning multi-line
elements in the symbolizer markup parser. The parser is kept agnostic to
how lines are delimited; it reports the entire contents, including line
endings, once the end of element marker is reached.
Reviewed By: peter.smith
Differential Revision: https://reviews.llvm.org/D124798
Jim Ingham [Wed, 8 Jun 2022 01:03:23 +0000 (18:03 -0700)]
Add a "-b" option to "process continue" to run to a set of breakpoints,
temporarily ignoring the others.
Differential Revision: https://reviews.llvm.org/D126513
serge-sans-paille [Wed, 22 Jun 2022 14:20:21 +0000 (16:20 +0200)]
[iwyu] Handle regressions in libLLVM header include
Running iwyu-diff on LLVM codebase since
fb67d683db46dfd88da09d99 detected a few
regressions, fixing them.
The impact on preprocessed output is negligible: -4k lines.
Richard [Wed, 22 Jun 2022 16:46:27 +0000 (10:46 -0600)]
[clang-tidy] Fix documentation (NFC)
The documentation files were reorganized into subdirectories, but a new
check was added concurrently and wasn't rebased correctly before
submitting. Sort the new clang-tidy checks by check name and fix the
indentation of bugprone-unchecked-optional-access.
Mark de Wever [Mon, 20 Jun 2022 16:28:34 +0000 (18:28 +0200)]
[libc++] Reduces std::to_chars instantiations.
Instead of instantiating all functions called by std::to_chars for the
integral types only instantiate them for 32 and 64 bit integral types.
This results in a smaller binary when using different types.
In an example using the types: signed char, short, int, long, long long,
unsigned char, unsigned short, unsigned int, unsigned long, and
unsigned long long this saved 2792 bytes of code size. For libc++.so.1
is saves 688 bytes of code size (64-bit Linux).
This was discovered while investigating a solution for #52709.
Reviewed By: #libc, ldionne
Differential Revision: https://reviews.llvm.org/D128215
Aart Bik [Tue, 21 Jun 2022 23:03:25 +0000 (16:03 -0700)]
[mlir][sparse] fix typo in CHECK test
Thanks Peiming for reporting!
Reviewed By: Peiming
Differential Revision: https://reviews.llvm.org/D128308
Aart Bik [Tue, 21 Jun 2022 23:47:44 +0000 (16:47 -0700)]
[mlir][sparse] accept sparse reshape (expand/collapse)
This revision makes sure we accept sparse tensors as arguments
of the expand/collapse reshaping operations in the tensor dialect.
Note that the actual lowering to runnable IR is still TBD.
Reviewed By: springerm
Differential Revision: https://reviews.llvm.org/D128311
Arjun P [Wed, 22 Jun 2022 16:29:46 +0000 (18:29 +0200)]
[MLIR][Presburger] introduce SlowMPInt, an auto-resizing APInt for fully correct signed integer computations
The Presburger library currently uses int64_t throughout for its integers.
This runs the risk of silently producing incorrect results when overflows occur.
Fixing this issue requires some sort of multiprecision integer
that transparently supports aribtrary arithmetic computations.
The class SlowMPInt provides this functionality, and is intended to be used
as the slow path fallback for a more optimized upcoming class, MPInt, that optimizes
for the Presburger library's workloads.
Reviewed By: ftynse
Differential Revision: https://reviews.llvm.org/D123758
Max Kazantsev [Wed, 22 Jun 2022 13:48:47 +0000 (20:48 +0700)]
[LSR] Don't allow zero quotient as scale ref. PR56160
Scale reg should never be zero, so when the quotient is zero, we
cannot assign it there. Limit this transform to avoid this situation.
Differential Revision: https://reviews.llvm.org/D128339
Reviewed By: eopXD
Craig Topper [Wed, 22 Jun 2022 16:00:15 +0000 (09:00 -0700)]
[RISCV] Add RISCVISD opcodes for the rest of get*Addr.
This adds RISCVISD opccodes for LA, LA_TLS_IE, and LA_TLS_GD to
remove creation of MachineSDNodes form get*Addr. This makes the
code consistent with the previous patches that added RISCVISD::HI,
ADD_LO, LLA, and TPREL_ADD.
Reviewed By: asb
Differential Revision: https://reviews.llvm.org/D128325
Mark de Wever [Wed, 22 Jun 2022 16:11:19 +0000 (18:11 +0200)]
[libc++][CI] Use GCC 12 labels.
Xiang Li [Tue, 14 Jun 2022 00:15:56 +0000 (17:15 -0700)]
[DirectX] Support opaque ptr for ValueAsMetadata in DXILBitcodeWriter
When writeValueAsMetadata for GlobalVariable and Function, write TypedPointerType for ValueType and FunctionType.
Reviewed By: bogner
Differential Revision: https://reviews.llvm.org/D127705
Peixin Qiao [Wed, 22 Jun 2022 16:04:24 +0000 (00:04 +0800)]
[flang] Add semantic check for C1520
As Fortran 2018 C1520, if proc-language-binding-spec with NAME= is
specified, then proc-decl-list shall contain exactly one proc-decl,
which shall neither have the POINTER attribute nor be a dummy procedure.
Add this check.
Reviewed By: klausler
Differential Revision: https://reviews.llvm.org/D127725
Peixin Qiao [Wed, 22 Jun 2022 15:56:34 +0000 (23:56 +0800)]
[flang][Driver] Refine _when_ driver diagnostics are formatted
This patch refines //when// driver diagnostics are formatted so that
`flang-new` and `flang-new -fc1` behave consistently with `clang` and
`clang -cc1`, respectively. This change only applies to driver diagnostics.
Scanning, parsing and semantic diagnostics are separate and not covered here.
**NEW BEHAVIOUR**
To illustrate the new behaviour, consider the following input file:
```! file.f90
program m
integer :: i = k
end
```
In the following invocations, "error: Semantic errors in file.f90" _will be_
formatted:
```
$ flang-new file.f90
error: Semantic errors in file.f90
./file.f90:2:18: error: Must be a constant value
integer :: i = k
$ flang-new -fc1 -fcolor-diagnostics file.f90
error: Semantic errors in file.f90
./file.f90:2:18: error: Must be a constant value
integer :: i = k
```
However, in the following invocations, "error: Semantic errors in file.f90"
_will not be_ formatted:
```
$ flang-new -fno-color-diagnostics file.f90
error: Semantic errors in file.f90
./file.f90:2:18: error: Must be a constant value
integer :: i = k
$ flang-new -fc1 file.f90
error: Semantic errors in file.f90
./file.f90:2:18: error: Must be a constant value
integer :: i = k
```
Before this change, none of the above would be formatted. Note also that the
default behaviour in `flang-new` is different to `flang-new -fc1` (this is
consistent with Clang).
**NOTES ON IMPLEMENTATION**
Note that the diagnostic options are parsed in `createAndPopulateDiagOpt`s in
driver.cpp. That's where the driver's `DiagnosticEngine` options are set. Like
most command-line compiler driver options, these flags are "claimed" in
Flang.cpp (i.e. when creating a frontend driver invocation) by calling
`getLastArg` rather than in driver.cpp.
In Clang's Options.td, `defm color_diagnostics` is replaced with two separate
definitions: `def fcolor_diagnostics` and def fno_color_diagnostics`. That's
because originally `color_diagnostics` derived from `OptInCC1FFlag`, which is a
multiclass for opt-in options in CC1. In order to preserve the current
behaviour in `clang -cc1` (i.e. to keep `-fno-color-diagnostics` unavailable in
`clang -cc1`) and to implement similar behaviour in `flang-new -fc1`, we can't
re-use `OptInCC1FFlag`.
Formatting is only available in consoles that support it and will normally mean that
the message is printed in bold + color.
Co-authored-by: Andrzej Warzynski <andrzej.warzynski@arm.com>
Reviewed By: rovka
Differential Revision: https://reviews.llvm.org/D126164
Peixin Qiao [Wed, 22 Jun 2022 15:53:38 +0000 (23:53 +0800)]
[NFC][flang] Add the test case for D125371
This adds the test case with portability warning preparing for D125804,
which supports checking for portability warnings in test_errors.py.
Reviewed By: ekieri
Differential Revision: https://reviews.llvm.org/D127821
Martin Storsjö [Wed, 22 Jun 2022 15:48:04 +0000 (18:48 +0300)]
[lldb] Tentative attempt to fix command-target-create-resolve-exe.test on buildbot
This test does succeed in my local test environment though, but
fails on the buildbot.
Jonathan Peyton [Thu, 5 May 2022 14:15:41 +0000 (09:15 -0500)]
[OpenMP][libomp] Hold old __kmp_threads arrays until library shutdown
When many nested teams are formed, __kmp_threads may be reallocated
to accommodate new threads. This reallocation causes a data
race when another existing team's thread simultaneously references
__kmp_threads. This patch keeps the old thread arrays around until library
shutdown so these lingering references can complete without issue and
access to __kmp_threads remains a simple array reference.
Fixes: https://github.com/llvm/llvm-project/issues/54708
Differential Revision: https://reviews.llvm.org/D125013
Nikita Popov [Wed, 22 Jun 2022 15:25:35 +0000 (17:25 +0200)]
[X86PreAMXConfig] Use IRBuilder to insert instructions (NFC)
Use an IRBuilder to insert instructions in preWriteTileCfg().
While here, also remove some unnecessary bool return values.
There are some test changes because the IRBuilder folds
"trunc i16 8 to i8" to "i8 8", and that has knock-on effects on
instruction naming.
I ran into this when converting tests to opaque pointers and
noticed that this pass introduces unnecessary "bitcast ptr to ptr"
instructions.
Mark de Wever [Wed, 22 Jun 2022 15:26:17 +0000 (17:26 +0200)]
[libc++] Fixes GCC-12 build.
Nikita Popov [Wed, 22 Jun 2022 15:00:10 +0000 (17:00 +0200)]
[X86] Regenerate test checks (NFC)
This runs the test through -instnamer and generates test checks
using update_test_checks.py. (The previous comment indicated that
update_llc_test_checks.py was used, but I rather doubt that.)
This relies on the non-determinism fix from
fbb72530fe80a95678a7d643d7a3f5ee8d693c93,
the previous check lines have apparently been written to accomodate
that non-determinism.
Nikita Popov [Wed, 22 Jun 2022 14:56:43 +0000 (16:56 +0200)]
[X86PreAMXConfig] Use MapVector to fix non-determinism
We generate code by iterating over this map, so make sure that the
order is deterministic.
Guillaume Chatelet [Wed, 22 Jun 2022 14:55:47 +0000 (14:55 +0000)]
Revert "[NFC] Remove dead code"
This reverts commit
8ba2cbff70f2c49a8926451c59cc260d67b706cf.
Nikita Popov [Wed, 22 Jun 2022 14:43:21 +0000 (16:43 +0200)]
[X86] Name instructions in test (NFC)
Run the test through -instnamer, to make it easier to modify.
Nico Weber [Wed, 22 Jun 2022 14:44:07 +0000 (10:44 -0400)]
[gn build] Port
c3574ef739fb slightly better
The name of the host binary changed from make_confusable_table to
make-confusable-table, so match that.
Nico Weber [Fri, 3 Jun 2022 11:49:28 +0000 (07:49 -0400)]
Reland "[gn build] (manually) port
b94db7ed7eaf (Confusables.inc)"
b94db7ed7eaf relanded in
c3574ef739fb.
This relands commit
180bae08a04d4dc, rebased across the new version of
commit
c3574ef739fb, and rebased across
10f7255d32b690.
serge-sans-paille [Fri, 15 Oct 2021 13:20:22 +0000 (15:20 +0200)]
[clang-tidy] Confusable identifiers detection
Detect identifiers that are confusable using a variant of Unicode definition
http://www.unicode.org/reports/tr39/#Confusable_Detection
and have conflicting scopes.
This a recommit (with portability and feature fixes) of
b94db7ed7eaf4a3b21f600653a09c55cab77b79f
Differential Revision: https://reviews.llvm.org/D112916
Alvin Wong [Wed, 22 Jun 2022 13:16:04 +0000 (16:16 +0300)]
[lldb] Add setting to override PE/COFF ABI by module name
The setting `plugin.object-file.pe-coff.module-abi` is a string-to-enum
map that allows specifying an ABI to a module name. For example:
ucrtbase.dll=msvc
libstdc++-6.dll=gnu
This allows for debugging a process which mixes both modules built using
the MSVC ABI and modules built using the MinGW ABI.
Depends on D127048
Reviewed By: DavidSpickett
Differential Revision: https://reviews.llvm.org/D127234
Alvin Wong [Wed, 22 Jun 2022 13:15:34 +0000 (16:15 +0300)]
[lldb][windows] Fix crash on getting nested exception
LLDB tries to follow `EXCEPTION_RECORD::ExceptionRecord` to follow the
nested exception chain. In practice this code just causes Access
Violation whenever there is a nested exception. Since there does not
appear to be any code in LLDB that is actually using the nested
exceptions, this change just removes the crashing code and adds a
comment for future reference.
Fixes https://github.com/mstorsjo/llvm-mingw/issues/292
Reviewed By: DavidSpickett
Differential Revision: https://reviews.llvm.org/D128201
Alvin Wong [Wed, 22 Jun 2022 13:13:57 +0000 (16:13 +0300)]
[lldb] Resolve exe location for `target create`
This fixes an issue that, when you start lldb or use `target create`
with a program name which is on $PATH, or not specify the .exe suffix of
a program in the working directory on Windows, you get a confusing
error, for example:
(lldb) target create notepad
error: 'C:\WINDOWS\SYSTEM32\notepad.exe' doesn't contain any 'host'
platform architectures: i686, x86_64, i386, i386
Fixes https://github.com/mstorsjo/llvm-mingw/issues/265
Reviewed By: DavidSpickett
Differential Revision: https://reviews.llvm.org/D127436
Martin Storsjö [Tue, 21 Jun 2022 12:31:32 +0000 (15:31 +0300)]
[lldb] Fix reading i686-windows executables with GNU environment
25c8a061c5739677d2fc0af29a8cc9520207b923 / D127048 added an option
for setting the ABI to GNU.
When an object file is loaded, there's only minimal verification
done for the architecture spec set for it, if the object file only
provides one.
However, for i386 object files, the PECOFF object file plugin
provides two architectures, i386-pc-windows and i686-pc-windows.
This picks a totally different codepath in
TargetList::CreateTargetInternal, where it's treated as a fat
binary. This goes through more verifications to see if the
architectures provided by the object file matches what the
platform plugin supports.
The PlatformWindows() constructor explicitly adds the
"i386-pc-windows" and "i686-pc-windows" architectures (even when
running on other architectures), which allows this "fat binary
verification" to succeed for the i386 object files that provide
two architectures.
However, after that commit, if the object file is advertised with
the different environment (either when lldb is built in a mingw
environment, or if that setting is set), the fat binary validation
won't accept the file any longer.
Update ArchSpec::IsEqualTo with more logic for the Windows use
cases; mismatching vendors is not an issue (they don't have any
practical effect on Windows), and GNU and MSVC environments are
compatible to the point that PlatformWindows can handle object
files for both environments/ABIs.
As a separate path forward, one could also consider to stop returning
two architecture specs from ObjectFilePECOFF::GetModuleSpecifications
for i386 files.
Differential Revision: https://reviews.llvm.org/D128268
James Y Knight [Wed, 22 Jun 2022 13:41:59 +0000 (09:41 -0400)]
Clang AttributeReference: emit entries for "Undocumented" attributes.
Almost all attributes currently marked `Undocumented` are user-facing
attributes which _ought_ to be documented, but nobody has written it
yet. This change ensures that we at least acknowledge that these
attributes exist in the documentation, even if we have no description
of their semantics.
A new category, `InternalOnly` has been added for those few attributes
which are not user-facing, and should remain omitted from the docs.
Guillaume Chatelet [Sat, 18 Jun 2022 11:36:02 +0000 (11:36 +0000)]
[Alignment] Use Align for MaxKernArgAlign
Differential Revision: https://reviews.llvm.org/D128118
Joseph Huber [Wed, 22 Jun 2022 13:37:54 +0000 (09:37 -0400)]
[LinkerWrapper] Fix calls to deleted Error constructor on older compilers
Summary:
A recent patch added some new code paths to the linker wrapper. Older
compilers seem to have problems with returning errors wrapped in
an Excepted type without explicitly moving them. This caused failures in
some of the buildbots. This patch fixes that.
Nikita Popov [Wed, 22 Jun 2022 12:51:00 +0000 (14:51 +0200)]
[X86] Migrate more tests to opaque pointers (NFC)
Migrate some more tests that required manual fixups (e.g. due to
phi nodes), but have no codegen changes.
Also tweak some more tests that had leftover no-op constant
expressions.
Valentin Clement [Wed, 22 Jun 2022 13:34:29 +0000 (15:34 +0200)]
[flang] Add FIR tests missing from fir-dev
This patch is part of the upstreaming effort from fir-dev branch.
Reviewed By: jeanPerier, PeteSteinfeld
Differential Revision: https://reviews.llvm.org/D128331
Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
Co-authored-by: Kiran Chandramohan <kiran.chandramohan@arm.com>
Guillaume Chatelet [Wed, 22 Jun 2022 13:33:40 +0000 (13:33 +0000)]
[NFC] Remove dead code
Florian Hahn [Wed, 22 Jun 2022 13:27:59 +0000 (15:27 +0200)]
[ConstraintElimination] Transfer info from SGE to unsigned system.
This patch adds a new transferToOtherSystem helper that tries to
transfer information from signed predicates to the unsigned system and
vice versa.
The initial version adds A >=u B for A >=s B && B >=s 0
https://alive2.llvm.org/ce/z/8b6F9i
Joseph Huber [Mon, 20 Jun 2022 14:17:40 +0000 (10:17 -0400)]
[Clang] Allow multiple comma separated arguments to `--offload-arch=`
This patch updates the `--[no-]offload-arch` command line arguments to
allow the user to pass in many architectures in a single argument rather
than specifying it multiple times. This means that the following command
line,
```
clang foo.cu --offload-arch=sm_70 --offload-arch=sm_80
```
can become:
```
clang foo.cu --offload-arch=sm_70,sm_80
```
Reviewed By: ye-luo
Differential Revision: https://reviews.llvm.org/D128206
Joseph Huber [Mon, 6 Jun 2022 15:36:45 +0000 (11:36 -0400)]
[LinkerWrapper] Rework the linker wrapper and use owning binaries
The linker wrapper currently eagerly extracts all identified offloading
binaries to a file. This isn't ideal because we will soon open these
files again to examine their symbols for LTO and other things.
Additionally, we may not use every extracted file in the case of static
libraries. This would be very noisy in the case of static libraries that
may contain code for several targets not participating in the current
link.
Recent changes allow us to treat an Offloading binary as a standard
binary class. So that allows us to use an OwningBinary to model the
file. Now we keep it in memory and only write it once we know which
files will be participating in the final link job. This also reworks a
lot of the structure around how we handle this by removing the old
DeviceFile class.
The main benefit from this is that the following doesn't output 32+ files and
instead will only output a single temp file for the linked module.
```
$ clang input.c -fopenmp --offload-arch=sm_70 -foffload-lto -save-temps
```
Reviewed By: JonChesterfield
Differential Revision: https://reviews.llvm.org/D127246
Nikita Popov [Wed, 22 Jun 2022 13:16:37 +0000 (15:16 +0200)]
[X86] Name instructions in test (NFC)
Run the test through -instnamer, which makes it simpler to modify
it.
Guillaume Chatelet [Wed, 22 Jun 2022 13:11:30 +0000 (13:11 +0000)]
[NFC] Remove dead code
Martin Storsjö [Mon, 20 Jun 2022 21:21:00 +0000 (00:21 +0300)]
[lldb] Remove an outdated comment. NFC.
This comment became outdated in
053eb35651906e693906fad6c695fce11415ade7
(but was moved along); that commit moved the code and the comment
to a separate function, with a separate local variable
`num_of_bytes_read`. On error, the possibly garbage value is never
copied back to the caller's reference, thus the comment is no longer
relevant (and slightly confusing as is).
Differential Revision: https://reviews.llvm.org/D128226
Aaron Ballman [Wed, 22 Jun 2022 12:06:08 +0000 (08:06 -0400)]
Don't treat invalid parameters as being unused
The misc-unused-parameters check would trigger false positive warnings
about the parameter being unused when the parameter declaration was
invalid. No longer issue the warning in that case on the assumption
that most parameters are used in practice, so the extra diagnostic is
most likely a false positive.
Fixes #56152
Igor Kudrin [Wed, 22 Jun 2022 12:51:29 +0000 (05:51 -0700)]
[NVPTX] Keep metadata attached to module-scope variables
This helps to preserve the debug information of global variables.
Differential Revision: https://reviews.llvm.org/D127510
Simon Pilgrim [Wed, 22 Jun 2022 11:07:27 +0000 (12:07 +0100)]
[DAG] SelectionDAG::GetDemandedBits - don't recurse back into GetDemandedBits
Another minor cleanup as we work toward removing GetDemandedBits entirely - call SimplifyMultipleUseDemandedBits directly.
Nikita Popov [Wed, 22 Jun 2022 12:33:12 +0000 (14:33 +0200)]
[X86] Migrate tests to use opaque pointers (NFC)
Test updates were performed using:
https://gist.github.com/nikic/
98357b71fd67756b0f064c9517b62a34
These are only the test updates where the test passed without
further modification (which is almost all of them, as the backend
is largely pointer-type agnostic).
Guillaume Chatelet [Wed, 22 Jun 2022 12:21:25 +0000 (12:21 +0000)]
Re-land [libc] Apply no-builtin everywhere, remove unnecessary flags
This is a reland of D126773 /
b2a9ea4420127d10b18ae648b16757665f8bbd7c.
The removal of `-mllvm -combiner-global-alias-analysis` has landed separately
in D128051 /
7b73f53790f3db9ee589dc26a05a481a5e9e6915.
And the removal of `-mllvm --tail-merge-threshold=0` is scheduled for
removal in a subsequent patch.
Nikita Popov [Wed, 22 Jun 2022 12:06:12 +0000 (14:06 +0200)]
[Tests] Remove unnecessary bitcasts from opaque pointer tests (NFC)
Previously left these behind due to the required instruction
renumbering, drop them now. This more accurately represents
opaque pointer input IR.
Also drop duplicate opaque pointer check lines in one SROA test.
Nikita Popov [Wed, 22 Jun 2022 11:02:18 +0000 (13:02 +0200)]
[AlignmentFromAssumptions] Migrate tests to opaque pointers (NFC)
Tests were updated with (without manual fixup):
https://gist.github.com/nikic/
98357b71fd67756b0f064c9517b62a34
Guillaume Chatelet [Tue, 14 Jun 2022 11:34:13 +0000 (11:34 +0000)]
[libc][mem*] Introduce Sized/Backends for new mem framework
This patch is a subpart of D125768 intented to make the review easier.
The `SizedOp` struct represents operations to be performed on a certain number of bytes.
It is responsible for breaking them down into platform types and forwarded to the `Backend`.
The `Backend` struct represents a lower level abstraction that works only on types (`uint8_t`, `__m128i`, ...).
It is similar to instruction selection.
Differential Revision: https://reviews.llvm.org/D126768
Nikita Popov [Wed, 22 Jun 2022 10:47:12 +0000 (12:47 +0200)]
[AddDiscriminators] Migrate tests to opaque pointers (NFC)
Update performed using:
https://gist.github.com/nikic/
98357b71fd67756b0f064c9517b62a34
memcpy-discriminator.ll was fixed up to use named instructions
and drop the no longer needed bitcasts.
Nikita Popov [Wed, 22 Jun 2022 10:27:21 +0000 (12:27 +0200)]
[AggressiveInstCombine] Update tests to use opaque pointers (NFC)
Update performed using (without manual fixup):
https://gist.github.com/nikic/
98357b71fd67756b0f064c9517b62a34
Nikita Popov [Wed, 22 Jun 2022 10:24:43 +0000 (12:24 +0200)]
[ADCE] Update tests to use opaque pointers (NFC)
Update performed using:
https://gist.github.com/nikic/
98357b71fd67756b0f064c9517b62a34
This time without any manual fixup.
esmeyi [Wed, 22 Jun 2022 10:23:36 +0000 (06:23 -0400)]
[XCOFF] write the real source file name in C_FILE symbol.
The symbol table starts with all the C_FILE symbols.
Reviewed By: shchenz
Differential Revision: https://reviews.llvm.org/D126623
David Green [Wed, 22 Jun 2022 10:04:22 +0000 (11:04 +0100)]
[ARM] Fix MVE gather/scatter merged gep offsets
This fixes the combining of constant vector GEP operands in the
optimization of MVE gather/scatter addresses, when opaque pointers are
enabled. As opaque pointers reduce the number of bitcasts between geps,
more can be folded than before. This can cause problems if the index
types are now different between the two geps.
This fixes that by making sure each constant is scaled appropriately,
which has the effect of transforming the geps to have a scale of 1,
changing [r0, q0, uxtw #1] gathers to [r0, q0] with a larger q0. This
helps use a simpler instruction that doesn't need the extra uxtw.
Differential Revision: https://reviews.llvm.org/D127733
Nikita Popov [Wed, 22 Jun 2022 09:36:38 +0000 (11:36 +0200)]
[X86] Don't run O2 pipeline in codegen test (NFC)
Regenerate the test with current O2 result and only run CGP.
David Sherwood [Thu, 16 Jun 2022 10:46:15 +0000 (11:46 +0100)]
[AArch64][SME] Add some SME PSTATE setting/query intrinsics
This patch adds support for:
* Querying the PSTATE.SM state with @llvm.aarch64.sme.get.pstatesm
* Reading/writing the TPIDR2 register with new
@llvm.aarch64.sme.get.tpidr2 and @llvm.aarch64.sme.set.tpidr2
intrinsics.
Tests added here:
CodeGen/AArch64/sme-get-pstatesm.ll
CodeGen/AArch64/sme-read-write-tpidr2.ll
Differential Revision: https://reviews.llvm.org/D127957
Hui Xie [Wed, 22 Jun 2022 08:24:09 +0000 (09:24 +0100)]
[libc++] fix views::all hard error on lvalue move only views instead of SFINAE
For an lvalue reference to a move only view x, views::all(x) gives hard error because the expression inside noexcept is not well formed and it is not SFINAE friendly.
Given a move only view type `V`, and a concept
```
template <class R>
concept can_all = requires {
std::views::all(std::declval<R>());
};
```
The expression `can_all<V&>` returns
libstdc++: false
msvc stl : false
libc++ : error: static_cast from 'V' to 'typename decay<decltype((std::forward<V &>(__t)))>::type' (aka 'V') uses deleted function
noexcept(noexcept(_LIBCPP_AUTO_CAST(std::forward<_Tp>(__t))))
The standard spec has its own problem, the spec says it is expression equivalent to `decay-copy(E)` but the spec of `decay-copy` does not have any constraint, which means the expression `decay-copy(declval<V&>())` is well-formed and the concept `can_all<V&>` should return true and should error when instantiating the function body of decay-copy. This is clearly wrong behaviour in the spec and we will probably create an LWG issue. But the libc++'s behaviour is clearly not correct. The `noexcept` is an "extension" in libc++ which is not in the spec, but the expression inside `noexpect` triggers hard error, which is not right.
Reviewed By: #libc, ldionne, var-const
Differential Revision: https://reviews.llvm.org/D128281
Nikita Popov [Fri, 3 Jun 2022 09:42:07 +0000 (11:42 +0200)]
[SCCP] Don't mark edges feasible when resolving undefs
As branch on undef is immediate undefined behavior, there is no need
to mark one of the edges as feasible. We can leave all the edges
non-feasible. In IPSCCP, we can replace the branch with an unreachable
terminator.
Differential Revision: https://reviews.llvm.org/D126962
Nicolas Vasilache [Wed, 22 Jun 2022 07:47:56 +0000 (00:47 -0700)]
[mlir][Transform] NFC - Pass TransformState as an argument to applyToOne methods
This will allow implementing state-dependent behavior in the future.
Differential Revision: https://reviews.llvm.org/D128327
Serge Pavlov [Wed, 20 Apr 2022 03:57:34 +0000 (10:57 +0700)]
Fix interaction of pragma FENV_ACCESS with other pragmas
Previously `#pragma STDC FENV_ACCESS ON` always set dynamic rounding
mode and strict exception handling. It is not correct in the presence
of other pragmas that also modify rounding mode and exception handling.
For example, the effect of previous pragma FENV_ROUND could be
cancelled, which is not conformant with the C standard. Also
`#pragma STDC FENV_ACCESS OFF` turned off only FEnvAccess flag, leaving
rounding mode and exception handling unchanged, which is incorrect in
general case.
Concrete rounding and exception mode depend on a combination of several
factors like various pragmas and command-line options. During the review
of this patch an idea was proposed that the semantic actions associated
with such pragmas should only set appropriate flags. Actual rounding
mode and exception handling should be calculated taking into account the
state of all relevant options. In such implementation the pragma
FENV_ACCESS should not override properties set by other pragmas but
should set them if such setting is absent.
To implement this approach the following main changes are made:
- Field `FPRoundingMode` is removed from `LangOptions`. Actually there
are no options that set it to arbitrary rounding mode, the choice was
only `dynamic` or `tonearest`. Instead, a new boolean flag
`RoundingMath` is added, with the same meaning as the corresponding
command-line option.
- Type `FPExceptionModeKind` now has possible value `FPE_Default`. It
does not represent any particular exception mode but indicates that
such mode was not set and default value should be used. It allows to
distinguish the case:
{
#pragma STDC FENV_ACCESS ON
...
}
where the pragma must set FPE_Strict, from the case:
{
#pragma clang fp exceptions(ignore)
#pragma STDC FENV_ACCESS ON
...
}
where exception mode should remain `FPE_Ignore`.
- Class `FPOptions` has now methods `getRoundingMode` and
`getExceptionMode`, which calculates the respective properties from
other specified FP properties.
- Class `LangOptions` has now methods `getDefaultRoundingMode` and
`getDefaultExceptionMode`, which calculates default modes from the
specified options and should be used instead of `getRoundingMode` and
`getFPExceptionMode` of the same class.
Differential Revision: https://reviews.llvm.org/D126364
Nikolas Klauser [Wed, 22 Jun 2022 08:11:14 +0000 (10:11 +0200)]
[libc++] Complete the implementation of N4190
Fixes #37402
Reviewed By: ldionne
Spies: EricWF, avogelsgesang, libcxx-commits, arphaman
Differential Revision: https://reviews.llvm.org/D124346
Nikolas Klauser [Mon, 20 Jun 2022 14:48:31 +0000 (16:48 +0200)]
[libc++] Remove std::function in C++03
`std::function` has been deprecated for a few releases now. Remove it with an option to opt-back-in with a note that this option will be removed in LLVM 16.
Reviewed By: ldionne, #libc
Spies: #libc_vendors, EricWF, jloser, libcxx-commits
Differential Revision: https://reviews.llvm.org/D127908
Valentin Clement [Wed, 22 Jun 2022 07:38:32 +0000 (09:38 +0200)]
[flang] Cleanup code and add test from fir-dev
This patch clean up some code for upstreaming and add couple of
missing tests that were left in fir-dev.
This patch is part of the upstreaming effort from fir-dev branch.
Reviewed By: jeanPerier, PeteSteinfeld
Differential Revision: https://reviews.llvm.org/D128258
Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
Florian Hahn [Wed, 22 Jun 2022 06:36:40 +0000 (08:36 +0200)]
[ConstraintElimination] Update addFact to take Predicate and ops (NFC).
This allows adding facts without necessarily having a corresponding
CmpInst.
Martin Storsjö [Tue, 24 May 2022 12:18:36 +0000 (15:18 +0300)]
[CMake] Don't pass CMAKE_C(XX)_COMPILER to the nested NATIVE build when cross compiling
Originally, the nested build was set up with the CMake command
`execute_process` which implicitly passes CC/CXX variables for
the configured compiler, which then was picked up by the nested
CMake. (This CMake behaviour, to implicitly pass such variables
is up for discussion and might change in the future; see
https://gitlab.kitware.com/cmake/cmake/-/issues/21378.)
How the nested cmake build is set up was changed in
aa7d6db5c8fc449b2908c6d629d6d9a067f49896 / D40229 - the old behaviour
was brought along by manually passing
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER} to the nested cmake
configuration. This was then later made optional in
f5f0fffea5ace079cc208fafa65150d23935a4d9 / D40947. But still,
the default if the user doesn't pass
CROSS_TOOLCHAIN_FLAGS_${target_name} (e.g. CROSS_TOOLCHAIN_FLAGS_NATIVE)
is to pass in the surrounding build's compiler - which usually
doesn't work, and is quite non-obvious to figure out.
Just drop the default passing of the outer compiler, when cross
compiling. This should avoid surprising cases of using the cross
compiler for the native build for essentially all new users trying
to cross compile, until they've discovered CROSS_TOOLCHAIN_FLAGS_NATIVE.
Keep passing these when not cross compiling, e.g. if building with
optimized tablegen.
This was already suggested at the end in D40229, but apparently never
acted upon.
Differential Revision: https://reviews.llvm.org/D126313
Pavel Samolysov [Fri, 17 Jun 2022 16:25:18 +0000 (19:25 +0300)]
[DeadArgElim] Reformat the pass in accordance with the code style
The code has been reformatted in accordance with the code style. Some
function comments were extended to the Doxygen ones and reworded a bit
to eliminate the duplication of the function's/class' name in the
comment.
Differential Revision: https://reviews.llvm.org/D128168
LLVM GN Syncbot [Wed, 22 Jun 2022 05:44:50 +0000 (05:44 +0000)]
[gn build] Port
77ad77c0710f
Siva Chandra Reddy [Tue, 21 Jun 2022 20:46:59 +0000 (20:46 +0000)]
[libc] Fix bug in UInt comparison operators.
Reviewed By: lntue
Differential Revision: https://reviews.llvm.org/D128303
Mark de Wever [Tue, 28 Dec 2021 17:48:04 +0000 (18:48 +0100)]
[libc++][format] Improve string formatters
This changes the implementation of the formatter. Instead of inheriting
from a specialized parser all formatters will use the same generic
parser. This reduces the binary size.
The new parser contains some additional fields only used in the chrono
formatting. Since this doesn't change the size of the parser the fields
are in the generic parser. The parser is designed to fit in 128-bit,
making it cheap to pass by value.
The new format function is a const member function. This isn't required
by the Standard yet, but it will be after LWG-3636 is accepted.
Additionally P2286 adds a formattable concept which requires the member
function to be const qualified in C++23. This paper is likely to be
accepted in the 2022 July plenary.
Depends on D121530
NOTE parts of the code now contains duplicates for the current and new parser.
The intention is to remove the duplication in followup patches. A general
overview of the final code is available in D124620. That review however lacks a
bit of polish.
Most of the new code is based on the same algorithms used in the current code.
The final version of this code reduces the binary size by 17 KB for this example
code
```
int main() {
{
std::string_view sv{"hello world"};
std::format("{}{}|{}{}{}{}{}{}|{}{}{}{}{}{}|{}{}{}|{}{}|{}", true, '*',
(signed char)(42), (short)(42), (int)(42), (long)(42), (long long)(42), (__int128_t)(42),
(unsigned char)(42), (unsigned short)(42), (unsigned int)(42), (unsigned long)(42),
(unsigned long long)(42), (__uint128_t)(42),
(float)(42), (double)(42), (long double)(42),
"hello world", sv,
nullptr);
}
{
std::wstring_view sv{L"hello world"};
std::format(L"{}{}|{}{}{}{}{}{}|{}{}{}{}{}{}|{}{}{}|{}{}|{}", true, L'*',
(signed char)(42), (short)(42), (int)(42), (long)(42), (long long)(42), (__int128_t)(42),
(unsigned char)(42), (unsigned short)(42), (unsigned int)(42), (unsigned long)(42),
(unsigned long long)(42), (__uint128_t)(42),
(float)(42), (double)(42), (long double)(42),
L"hello world", sv,
nullptr);
}
}
```
Reviewed By: #libc, ldionne
Differential Revision: https://reviews.llvm.org/D125606
Tom Stellard [Wed, 22 Jun 2022 05:16:02 +0000 (22:16 -0700)]
HowToReleaseLLVM: Add description of the bug triage process
Reviewed By: andreil99
Differential Revision: https://reviews.llvm.org/D126985
Ruiling Song [Fri, 17 Jun 2022 13:55:41 +0000 (21:55 +0800)]
AMDGPU: Skip unexpected CFG in SIOptimizeVGPRLiveRange
There are some cases that we use si_if/si_else in unatural way.
Just skip them.
Fixes: https://github.com/llvm/llvm-project/issues/55922
Reviewed by: critson
Differential Revision: https://reviews.llvm.org/D128193
chenglin.bi [Wed, 22 Jun 2022 04:24:48 +0000 (12:24 +0800)]
[NewGVN] add context instruction for SimplifyQuery
NewGVN will find operator from other context. ValueTracking currently doesn't have a way to run completely without context instruction.
So it will use operator itself as conext instruction.
If the operator in another branch will never be executed but it has an assume, it may caused value tracking use the assume to do wrong simpilfy.
It would be better to make these simplification queries not use context at all, but that would require some API changes.
For now we just use the orignial instruction as context instruction to fix the issue.
Fix #56039
Reviewed By: nikic
Differential Revision: https://reviews.llvm.org/D127942
Serguei Katkov [Fri, 17 Jun 2022 06:10:57 +0000 (13:10 +0700)]
[LoopVectorize] Uninitialized phi node leads to a crash in SSAUpdater.
createInductionResumeValues creates a phi node placeholder
without filling incoming values. Then it generates the incoming values.
It includes triggering of SCEV expander which may invoke SSAUpdater.
SSAUpdater has an optimization to detect number of predecessors
basing on incoming values if there is phi node.
In case phi node is not filled with incoming values - the number of predecessors
is detected as 0 and this leads to segmentation fault.
In other words SSAUpdater expects that phi is in good shape while
LoopVectorizer breaks this requirement.
The fix is just prepare all incoming values first and then build a phi node.
Reviewed By: fhahn
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D128033
Michał Górny [Wed, 22 Jun 2022 03:36:15 +0000 (05:36 +0200)]
[lldb] [test] Mark TestNonStop as LLGS-specific
Thanks for Med Ismail Bennani for reporting the debugserver failures.
Joseph Huber [Wed, 22 Jun 2022 02:30:25 +0000 (22:30 -0400)]
[Libomptarget] Remove duplicate data environment exit
Summary:
This patch removes a duplicated exit from the OpenMP data envrionment.
We already have an RAII method that guards this environment so it is
unnecessary.
Johannes Doerfert [Tue, 21 Jun 2022 19:52:37 +0000 (14:52 -0500)]
[Attributor][FIX] Avoid empty bin in AAPointerInfo
This avoid creating empty bins in AAPointerInfo which can lead to
segfaults. Also ensure we do not try to translate from callee to caller
except if we really take the argument state and move it to the call site
argument state.
Fixes: https://github.com/llvm/llvm-project/issues/55726
Johannes Doerfert [Thu, 19 May 2022 18:35:58 +0000 (13:35 -0500)]
[Attributor] Ensure to use the proper liveness AA
When determining liveness via Attributor::isAssumedDead(...) we might
end up without a liveness AA or with one pointing into another function.
Neither is helpful and we will avoid both from now on.
Reapplied after fixing the ASAN error which caused the revert:
https://github.com/llvm/llvm-project/commit/
db68a25ca90e0da46c9c33b027fa83260073bd28