Commit Graph

419892 Commits

Author SHA1 Message Date
Dávid Bolvanský e91fe08999 [NFCI] Regenerate PhaseOrdering test checks 2022-04-04 00:28:57 +02:00
Dávid Bolvanský 260679b000 [NFCI] Regenerate LoopIdiomRecognize test checks 2022-04-04 00:21:26 +02:00
Nico Weber 50186b63d1 Revert "[GH54588]Fix ItaniumMangler for NTTP unnamed unions w/ unnamed structs"
This reverts commit 4cf98f973a.
The test fails on mac bots, see comments on https://reviews.llvm.org/D122820

Also reverts follow-ups eb92098986 and
861c189d2a.
2022-04-03 17:21:27 -04:00
David Green 3c88ff44c5 [AArch64] Remove unsued WideningBaseCost. NFC
The WideningBaseCost is always 0. This removes it to clean up the code.
2022-04-03 22:16:39 +01:00
Louis Dionne e70533ae6c [libc++] Remove unused <iosfwd> include from <__debug>
Differential Revision: https://reviews.llvm.org/D122999
2022-04-03 16:15:48 -04:00
Dávid Bolvanský a113a582b1 [NFCI] Regenerate LoopVectorize test checks 2022-04-03 21:56:24 +02:00
Kazu Hirata d3684c3359 [IR] Remove unused forward declarations (NFC) 2022-04-03 12:54:54 -07:00
Dávid Bolvanský 11b41910dd [NFCI] Regenerate instsimplify test checks 2022-04-03 20:55:15 +02:00
Louis Dionne 896770c9a9 [libc++][NFC] Fix weird indentation in test 2022-04-03 12:47:28 -04:00
Vladislav Khmelevsky 3b1314f4de [BOLT] AArch64: Read all static relocations
Read static relocs on the same address, as dynamic in order to update
constant island data address properly.

Differential Revision: https://reviews.llvm.org/D122100
2022-04-03 19:03:35 +03:00
Kiran Chandramohan 0000030b18 Revert "[Flang][OpenMP] Add semantic check for OpenMP Private, Firstprivate and Lastprivate clauses."
This reverts commit a2ca6bbda6.

D93213 performs some checks to ensure that variables that appear in
statement functions are not in privatisation clauses. The point at
which this check is currently performed, there can be misparses that
cause more constructs to be identified as statement functions. This
can lead to various kinds of errors, hence reverting.

This revert hopefully fixes:
https://github.com/llvm/llvm-project/issues/54477
https://github.com/llvm/llvm-project/issues/54161
https://github.com/llvm/llvm-project/issues/54163

Reviewed By: shraiysh

Differential Revision: https://reviews.llvm.org/D122650
2022-04-03 15:54:02 +00:00
Luboš Luňák baebf23896 [lldb][gui] underline the current token
Just like the non-gui listing already does.
2022-04-03 17:52:01 +02:00
Luboš Luňák 5e79a00178 [lldb][gui] use symbolic names rather than hardcoded values 2022-04-03 17:52:01 +02:00
Luboš Luňák 5c540c751c [lldb][gui] fix background of syntax-highlighted non-selected PC line
It is the PC line, selected or not, that gets the blue-background
highlight. Without this, a keyword like 'bool' got black background
if the line wasn't selected.
And the blue-background highlight is handled by OutputColoredStringTruncated(),
so no point in setting it explicitly in the calling code.
2022-04-03 17:52:01 +02:00
Luboš Luňák 11b6d2f9cd [lldb][gui] draw highlight for selected line even if empty 2022-04-03 17:52:00 +02:00
Kazu Hirata e5121be910 Revert "Apply clang-tidy fixes for readability-redundant-declaration in Debug.cpp (NFC)"
This reverts commit 0fe01a9346658c0955b68b123f2b470b018114b1.

The commit caused build failures like:

  llvm/lib/Support/Debug.cpp:65:3: error: ‘setCurrentDebugTypes’ was
  not declared in this scope; did you mean ‘setCurrentDebugType’?
2022-04-03 08:14:11 -07:00
LLVM GN Syncbot 6020830e88 [gn build] Port e476df5629 2022-04-03 15:09:33 +00:00
Nikolas Klauser e476df5629 [libc++][ranges] Implement ranges::max
Reviewed By: Mordante, var-const, #libc

Spies: sstefan1, libcxx-commits, mgorny

Differential Revision: https://reviews.llvm.org/D122002
2022-04-03 17:04:56 +02:00
Kazu Hirata 1fe01a9346 Apply clang-tidy fixes for readability-redundant-declaration in Debug.cpp (NFC) 2022-04-03 08:04:12 -07:00
Kazu Hirata c45d369ced Apply clang-tidy fixes for readability-redundant-member-init in YAMLParser.cpp (NFC) 2022-04-03 08:04:11 -07:00
Danny Mösch ef19de52ed [clang-tidy] Add release notes for changes made in 2b21fc5520 2022-04-03 15:48:39 +02:00
Valentin Clement 3bcc928b1b
[flang][NFC] Add tests for fir.array_modify in array-value-copy pass
This patch adds some test for the `fir.array_modify` operation
in the array-value-copy pass

This patch is part of the upstreaming effort from fir-dev branch.

Reviewed By: jeanPerier

Differential Revision: https://reviews.llvm.org/D122809

Co-authored-by: V Donaldson <vdonaldson@nvidia.com>
Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
2022-04-03 15:26:14 +02:00
Valentin Clement 0371f3e232
[flang][NFC] Add more test cases for the array-value-copy pass
This patch adds some test cases for the array-value-copy pass with slices.

This patch is part of the upstreaming effort from fir-dev branch.

Reviewed By: jeanPerier

Differential Revision: https://reviews.llvm.org/D122807

Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
2022-04-03 15:25:10 +02:00
Valentin Clement 602dd6bd32
[flang][NFC] Add tests for fir.is_present
This patch adds tests for the `fir.is_present`
translation.

This patch is part of the upstreaming effort from fir-dev branch.

Reviewed By: jeanPerier

Differential Revision: https://reviews.llvm.org/D122813

Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
2022-04-03 15:22:33 +02:00
Valentin Clement e0c782bdc0
[flang] Add global and global box initialization tests
This patch addes some global initialization and global
box initialization tests.

This patch is part of the upstreaming effort from fir-dev branch.

Reviewed By: schweitz

Differential Revision: https://reviews.llvm.org/D122881

Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
2022-04-03 15:20:55 +02:00
Valentin Clement 2fb57d628c
[flang][NFC] Add tests for select constructs
Add tests for fir.select_rank and
fir.select_case.

This patch is part of the upstreaming effort from fir-dev branch.

Reviewed By: schweitz

Differential Revision: https://reviews.llvm.org/D122888

Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
2022-04-03 15:18:57 +02:00
Hirochika Matsumoto f138a9964b Reapply "[InstSimplify][NFC] Add baseline tests for folds of icmp with ctpop"
This change was previously reverted because I forgot rerunning
update_test_checks.py and tests were not actually baseline.

Extracted from: https://reviews.llvm.org/D122757
2022-04-03 22:07:04 +09:00
Louis Dionne 282b3eb723 [libunwind] Add missing licenses in test files 2022-04-03 08:55:57 -04:00
Dávid Bolvanský fb65aaf0be [NFCI] Fixed missing colon in CHECK directives - part 2 2022-04-03 14:42:59 +02:00
Iain Sandoe 1f0b8ba47a [C++20][Modules] Fix a testcase warning on Windows [NFC].
As reported, using "-DTDIR=%t" with a path name of 'C:\Users\...' causes
a warning to be emitted about the use of \U without following hex digits.

Since the value is only required for the FileCheck cases resolve this by
omitting the -D from the compile lines.
2022-04-03 11:39:00 +01:00
Dávid Bolvanský f02a0a69af [NFCI] Fixed missing colon in CHECK directives 2022-04-03 11:52:38 +02:00
Simon Pilgrim fbfd78f7aa [X86] lowerShuffleAsRepeatedMaskAndLanePermute - allow v16i32 sub-lane permutes for v64i8 shuffles
Without VBMI, we are better off permuting v16i32 sub-lanes, even though its a variable shuffle, if it allows us to then shuffle v64i8 inlane repeated masks (PSHUFB etc.)

Fixes #54658
2022-04-03 10:05:10 +01:00
Alexander Shaposhnikov 6cf10b7e6e [InstCombine] Fold srem(X, PowerOf2) == C into (X & Mask) == C for positive C
This diff extends InstCombinerImpl::foldICmpSRemConstant to handle the cases
srem(X, PowerOf2) == C and
srem(X, PowerOf2) != C
for positive C.
This addresses the issue https://github.com/llvm/llvm-project/issues/54650

Differential revision: https://reviews.llvm.org/D122942

Test plan: make check-all
2022-04-03 03:57:05 +00:00
Alexander Shaposhnikov 911cfcd7f5 [InstCombine][NFC] Add baseline tests for folds of srem(X, PowerOf2) == C
Extracted from: https://reviews.llvm.org/D122942

Test plan: make check-all
2022-04-03 03:26:47 +00:00
Sanjay Patel 5f8c2b884d [InstCombine] limit icmp fold with sub if other sub user is a phi
This is a hacky fix for:
https://github.com/llvm/llvm-project/issues/54558

As discussed there, codegen regressed when we opened up this transform
to allow extra uses ( 61580d0949 ), and it's not clear how to
undo the transforms at the later stage of compilation.

As noted in the code comments, there's a set of remaining folds that
are still limited to one-use, so we can try harder to refine and
expand the limitations on these folds, but it's likely to be an
up-and-down battle as we find and overcome similar regressions.

Differential Revision: https://reviews.llvm.org/D122909
2022-04-02 19:23:42 -04:00
Sanjay Patel 97ac0cd6c4 [InstCombine] fold fcmp with lossy casted constant (2nd try)
This is a retry of 9397bdc67e - that was reverted until
we had a clang warning in place to alert users about a
possible mistake in source. The warning was added with
ab982eace6.

This is noted as a missing clang warning in #54222,
but it is also a missing optimization opportunity.

Alive2 proofs:
https://alive2.llvm.org/ce/z/Q8drDq
https://alive2.llvm.org/ce/z/pE6LRt

I don't see a single conversion for all predicates
using "getFCmpCode" logic, so other predicates are
left as a TODO item.
2022-04-02 19:23:01 -04:00
Groverkss bab2a4f2fb [MLIR][Presburger] Use PresburgerSpace in SetCoalescer
This patch changes the implementation of SetCoalescer to use PresburgerSpace
instead of reimplementing parts of PresburgerSpace.

Reviewed By: arjunp

Differential Revision: https://reviews.llvm.org/D122984
2022-04-03 04:06:47 +05:30
Roman Lebedev 308ca349cb
[InstCombine] Fold `(X | C2) ^ C1 --> (X & ~C2) ^ (C1^C2)`
These two are equivalent,
and i *think* the `and` form is more-ish canonical.

General proof: https://alive2.llvm.org/ce/z/RrF5s6

If constant on the (outer) `xor` is an `undef`,
the whole lane is dead: https://alive2.llvm.org/ce/z/mu4Sh2

However, if the constant on the (inner) `or` is an `undef`,
we must sanitize it first: https://alive2.llvm.org/ce/z/MHYJL7
I guess, producing a zero `and`-mask is optimal in that case.

alive-tv is happy about the entirety of `xor-of-or.ll`.
2022-04-03 00:12:56 +03:00
Roman Lebedev 3ae08dac8f
[NFC][InstCombine] Autogenerate check lines in a test affected by the future change 2022-04-03 00:12:56 +03:00
Roman Lebedev b3fca02a6d
[NFC][InstCombine] Add some tests for `(X | C2) ^ C1` pattern 2022-04-03 00:12:48 +03:00
Martin Storsjö 578d85e924 [Support] [BLAKE3] Fix compilation with CMAKE_OSX_ARCHITECTURES
With CMake, one can build for multiple macOS architectures
at the same time by setting CMAKE_OSX_ARCHITECTURES to multiple
architectures (avoiding needing to do two separate builds and
gluing the binaries together after the build).

In this case, while targeting x86_64 and arm64, neither IS_X64
nor IS_ARM64 is set, while compilation of the individual source
files will hit those cases (in either architecture mode).

Therefore, if we on the CMake level decide not to include the
architecture specific SIMD implementation files, also tell the
source this explicitly by passing the defines indicating that we
don't expect to use them.

Such a build clearly is less ideal than explicitly targeting one
architecture at a time if it won't include all the SIMD optimizations,
but that's a tradeoff that is up to the one deciding to do such an
universal build.

This also fixes builds for i386. The blake3 source code automatically
enables the SIMD implementations when building for i386, but we don't
provide the sources for that build configuration.

Differential Revision: https://reviews.llvm.org/D122884
2022-04-03 00:02:59 +03:00
Martin Storsjö d0abdc22b8 [Support] [BLAKE3] Remove .hidden directives from windows-gnu assembly sources
COFF symbols don't have anything corresponding to a `.hidden` flag;
both GNU binutils as and LLVM's built-in assembler errors out on
these directives.

This reverts one part of
7f05aa2d4c, fixing builds for
mingw x86_64.

Differential Revision: https://reviews.llvm.org/D122893
2022-04-02 23:58:31 +03:00
Florian Hahn 95b2aa511e
[VPlan] Set VPlan header block name to vector.body.
This brings the VPlan block naming in line with the naming of the
generated basic blocks.
2022-04-02 19:34:32 +01:00
Groverkss 1483fb33b3 [MLIR][Presburger][NFC] Rename getCompatibleSpace to getSpaceWithoutLocals
Reviewed By: arjunp

Differential Revision: https://reviews.llvm.org/D122973
2022-04-02 23:39:57 +05:30
Walter Erquinigo 1e5083a563 [trace][intel pt] Handle better tsc in the decoder
A problem that I introduced in the decoder is that I was considering TSC decoding
errors as actual instruction errors, which mean that the trace has a gap. This is
wrong because a TSC decoding error doesn't mean that there's a gap in the trace.
Instead, now I'm just counting how many of these errors happened and I'm using
the `dump info` command to check for this number.

Besides that, I refactored the decoder a little bit to make it simpler, more
readable, and to handle TSCs in a cleaner way.

Differential Revision: https://reviews.llvm.org/D122867
2022-04-02 11:06:26 -07:00
Hirochika Matsumoto f65c78a094 Revert "[InstSimplify][NFC] Add baseline tests for folds of icmp with ctpop"
This reverts commit b48abeea44.

Accidentally added already optimized tests, not baseline tests.
2022-04-03 02:27:59 +09:00
Hirochika Matsumoto b48abeea44 [InstSimplify][NFC] Add baseline tests for folds of icmp with ctpop
Extracted from: https://reviews.llvm.org/D122757
2022-04-03 02:19:24 +09:00
Florian Hahn 5bedc1f093
[ConstraintElimination] Move logic to build worklist to helper (NFC).
This refactor makes it easier to extend the logic to collect information
from blocks in the future, without even further increasing the size of
eliminateConstriants.
2022-04-02 16:55:05 +01:00
tyb0807 43d758b142 [Driver][AArch64] Split up aarch64-cpus.c tests further
This is the continuation of https://reviews.llvm.org/D120875. Now
aarch64-cpus-[12].c are further splitted and renamed to better reflect
the tests.

Differential Revision: https://reviews.llvm.org/D121093
2022-04-02 14:51:24 +01:00
tyb0807 9a015ee1f9 [AArch64] Avoid scanning feature list for target parsing
As discussed in https://reviews.llvm.org/D120111, this patch proposes an
alternative implementation to avoid scanning feature list for
architecture version over and over again. The insertion position for
default extensions is also captured during this single scan of the
feature list.

Differential Revision: https://reviews.llvm.org/D120864
2022-04-02 14:51:23 +01:00