platform/upstream/llvm.git
3 years ago[libc++] Disable some tests using gcc 9.
Mark de Wever [Sat, 28 Nov 2020 19:08:09 +0000 (20:08 +0100)]
[libc++] Disable some tests using gcc 9.

This should fix running the libc++ unit tests.
They failed due to the changes introduced in 67c88e.

3 years ago[BasicAA] Add tests for suboptimal speculation results (NFC)
Nikita Popov [Sat, 28 Nov 2020 18:14:04 +0000 (19:14 +0100)]
[BasicAA] Add tests for suboptimal speculation results (NFC)

While we determine that (phi1, phi2) is noalias, we don't
determine that (gep phi1 + 1, gep phi2 + 1) are also noalias.

3 years ago[X86] Add -verify-machineinstrs to pic.ll
Harald van Dijk [Sat, 28 Nov 2020 17:54:44 +0000 (17:54 +0000)]
[X86] Add -verify-machineinstrs to pic.ll

This ensures that failures show up in regular builds, rather than only
when expensive checks are enabled.

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

3 years ago[X86] Do not allow FixupSetCC to relax constraints
Harald van Dijk [Sat, 28 Nov 2020 17:46:56 +0000 (17:46 +0000)]
[X86] Do not allow FixupSetCC to relax constraints

The build bots caught two additional pre-existing problems exposed by the test change part of my change https://reviews.llvm.org/D91339, when expensive checks are enabled. https://reviews.llvm.org/D91924 fixes one of them, this fixes the other.

FixupSetCC will change code in the form of

  %setcc = SETCCr ...
  %ext1 = MOVZX32rr8 %setcc

to

  %zero = MOV32r0
  %setcc = SETCCr ...
  %ext2 = INSERT_SUBREG %zero, %setcc, %subreg.sub_8bit

and replace uses of %ext1 with %ext2.

The register class for %ext2 did not take into account any constraints on %ext1, which may have been required by its uses. This change ensures that the original constraints are honoured, by instead of creating a new %ext2 register, reusing %ext1 and further constraining it as needed. This requires a slight reorganisation to account for the fact that it is possible for the constraining to fail, in which case no changes should be made.

Reviewed By: RKSimon

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

3 years ago[ConstantFold] Fold operations to poison if possible
Juneyoung Lee [Fri, 27 Nov 2020 02:04:04 +0000 (11:04 +0900)]
[ConstantFold] Fold operations to poison if possible

This patch updates ConstantFold, so operations are folded into poison if possible.

<alive2 proofs>
casts: https://alive2.llvm.org/ce/z/WSj7rw
binary operations (arithmetic): https://alive2.llvm.org/ce/z/_7dEyJ
binary operations (bitwise): https://alive2.llvm.org/ce/z/cezjVN
vector/aggregate operations: https://alive2.llvm.org/ce/z/BQ7hWz
unary ops: https://alive2.llvm.org/ce/z/yBRs4q
other ops: https://alive2.llvm.org/ce/z/iXbcFD

Reviewed By: nikic

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

3 years ago[X86] Have indirect calls take 64-bit operands in 64-bit modes
Harald van Dijk [Sat, 28 Nov 2020 16:46:30 +0000 (16:46 +0000)]
[X86] Have indirect calls take 64-bit operands in 64-bit modes

The build bots caught two additional pre-existing problems exposed by the test change part of my change https://reviews.llvm.org/D91339, when expensive checks are enabled. This fixes one of them.

X86 has CALL64r and CALL32r opcodes, where CALL64r takes a 64-bit register, and CALL32r takes a 32-bit register. CALL64r can only be used in 64-bit mode, CALL32r can only be used in 32-bit mode. LLVM would assume that after picking the appropriate CALLr opcode, a pointer-sized register would be a valid operand, but in x32 mode, a 64-bit mode, pointers are 32 bits. In this mode, it is invalid to directly pass a pointer to CALL64r, it needs to be extended to 64 bits first.

Reviewed By: RKSimon

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

3 years ago[Timer] Add a command option to enable/disable timer sorting.
Paul C. Anagnostopoulos [Thu, 26 Nov 2020 02:00:28 +0000 (21:00 -0500)]
[Timer] Add a command option to enable/disable timer sorting.

Add one more timer to DAGISelEmitter to test the option.

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

3 years ago[libc++] P1645 constexpr for <numeric>
Mark de Wever [Sat, 28 Nov 2020 13:50:53 +0000 (14:50 +0100)]
[libc++] P1645 constexpr for <numeric>

Implements P1645: constexpr for <numeric> algorithms

Reviewed By: ldionne, #libc

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

3 years ago[clangd] Add symbol origin for remote index
Kirill Bobyrev [Sat, 28 Nov 2020 14:38:04 +0000 (15:38 +0100)]
[clangd] Add symbol origin for remote index

Makes it easier to diagnose remote index issues with --debug-origins flag.

Reviewed By: sammccall

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

3 years ago[mlir] Fix bad rebase landed in acb69f3b7c83.
Christian Sigg [Sat, 28 Nov 2020 12:46:43 +0000 (13:46 +0100)]
[mlir] Fix bad rebase landed in acb69f3b7c83.

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

3 years ago[mlir] Change ConvertOpToLLVMPattern::matchAndRewrite argument to concrete operand...
Christian Sigg [Fri, 27 Nov 2020 20:09:13 +0000 (21:09 +0100)]
[mlir] Change ConvertOpToLLVMPattern::matchAndRewrite argument to concrete operand type.

Reviewed By: herhut, ftynse

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

3 years ago[BasicAA] Remove unnecessary known size requirement
Nikita Popov [Sat, 14 Nov 2020 17:01:14 +0000 (18:01 +0100)]
[BasicAA] Remove unnecessary known size requirement

The size requirement on V2 was present because it was not clear
whether an unknown size would allow an access before the start of
V2, which could then overlap. This is clarified since D91649: In
this part of BasicAA, all accesses can occur only after the base
pointer, even if they have unknown size.

This makes the positive and negative offset cases symmetric.

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

3 years ago[RISCV] Add tests for existing (rotr (bswap X), (i32 16))->grevi pattern for RV32...
Craig Topper [Fri, 27 Nov 2020 23:17:34 +0000 (15:17 -0800)]
[RISCV] Add tests for existing (rotr (bswap X), (i32 16))->grevi pattern for RV32. Extend same pattern to rotl and GREVIW.

Not sure why bswap was treated specially. This also applies to bitreverse
or generic grevi. We can improve this in future patches.
For now I just wanted to get the consistency and the test coverage
as I plan to make some other changes around bswap.

3 years ago[gn build] Port a8a43b63388
LLVM GN Syncbot [Sat, 28 Nov 2020 01:56:55 +0000 (01:56 +0000)]
[gn build] Port a8a43b63388

3 years agoRevert "[IRSim][IROutliner] Adding the extraction basics for the IROutliner."
Andrew Litteken [Sat, 28 Nov 2020 01:54:11 +0000 (19:54 -0600)]
Revert "[IRSim][IROutliner] Adding the extraction basics for the IROutliner."

Reverting commit due to address sanitizer errors.

> Extracting the similar regions is the first step in the IROutliner.
>
> Using the IRSimilarityIdentifier, we collect the SimilarityGroups and
> sort them by how many instructions will be removed.  Each
> IRSimilarityCandidate is used to define an OutlinableRegion.  Each
> region is ordered by their occurrence in the Module and the regions that
> are not compatible with previously outlined regions are discarded.
>
> Each region is then extracted with the CodeExtractor into its own
> function.
>
> We test that correctly extract in:
> test/Transforms/IROutliner/extraction.ll
> test/Transforms/IROutliner/address-taken.ll
> test/Transforms/IROutliner/outlining-same-globals.ll
> test/Transforms/IROutliner/outlining-same-constants.ll
> test/Transforms/IROutliner/outlining-different-structure.ll
>
> Reviewers: paquette, jroelofs, yroux
>
> Differential Revision: https://reviews.llvm.org/D86975

This reverts commit bf899e891387d07dfd12de195ce2a16f62afd5e0.

3 years ago[gn build] Port bf899e89138
LLVM GN Syncbot [Sat, 28 Nov 2020 01:09:33 +0000 (01:09 +0000)]
[gn build] Port bf899e89138

3 years ago[IRSim][IROutliner] Adding the extraction basics for the IROutliner.
Andrew Litteken [Tue, 15 Sep 2020 23:05:38 +0000 (18:05 -0500)]
[IRSim][IROutliner] Adding the extraction basics for the IROutliner.

Extracting the similar regions is the first step in the IROutliner.

Using the IRSimilarityIdentifier, we collect the SimilarityGroups and
sort them by how many instructions will be removed.  Each
IRSimilarityCandidate is used to define an OutlinableRegion.  Each
region is ordered by their occurrence in the Module and the regions that
are not compatible with previously outlined regions are discarded.

Each region is then extracted with the CodeExtractor into its own
function.

We test that correctly extract in:
test/Transforms/IROutliner/extraction.ll
test/Transforms/IROutliner/address-taken.ll
test/Transforms/IROutliner/outlining-same-globals.ll
test/Transforms/IROutliner/outlining-same-constants.ll
test/Transforms/IROutliner/outlining-different-structure.ll

Reviewers: paquette, jroelofs, yroux

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

3 years ago[libc++] s/constpexr/constexpr/ in some comments. NFC.
Arthur O'Dwyer [Fri, 27 Nov 2020 23:51:57 +0000 (18:51 -0500)]
[libc++] s/constpexr/constexpr/ in some comments. NFC.

3 years ago[VE] Optimize emitSPAdjustment function
Kazushi (Jam) Marukawa [Thu, 26 Nov 2020 13:27:34 +0000 (22:27 +0900)]
[VE] Optimize emitSPAdjustment function

Optimize emitSPAdjustment function to generate as small as possible
instructions to adjust SP.

Reviewed By: simoll

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

3 years ago[libc++] Support no libc++ namespace in the iterator test.
Vladimir Vereschaka [Fri, 27 Nov 2020 23:01:09 +0000 (15:01 -0800)]
[libc++] Support no libc++ namespace in the iterator test.

The 5f12f4ff9078455cad9d4806da01f570553a5bf9 commit suppress printing of
inline namespace names in diagnostics by default that breaks the libc++
iterator test, which expects __1 in the namespace.

This patch fixes the test by supporting a test case without __1 in the
namespace.

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

3 years ago[libc++] Consistently unparenthesize `numeric_limits<T>::max`. NFCI.
Arthur O'Dwyer [Fri, 27 Nov 2020 19:13:05 +0000 (14:13 -0500)]
[libc++] Consistently unparenthesize `numeric_limits<T>::max`. NFCI.

I think people were sometimes parenthesizing `(foo::max)()` out of
misplaced concern that an unparenthesized `foo::max()` would trip up
Windows' `max(a,b)` macro. However, this is not the case: `max(a,b)`
should be tripped up only by an unparenthesized call to `foo::max(a,b)`,
and in fact we already do `_VSTD::max(a,b)` all over the place anyway
without any guards.

However, in order to do it without guards, we must also
wrap the header in _LIBCPP_PUSH_MACROS, which <span> was not.

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

3 years agoAdd -fintegrated-as to clang invocation
Zarko Todorovski [Fri, 27 Nov 2020 20:54:37 +0000 (15:54 -0500)]
Add -fintegrated-as to clang invocation

On platforms where the integrated as isn't called by default this
test fails since the output is not what it expects.  Adding this
option generates the expected output on those platforms as well.

3 years ago[RISCV] Replace getSimpleValueType() with getValueType() in DAG combines to prevent...
Craig Topper [Fri, 27 Nov 2020 20:41:55 +0000 (12:41 -0800)]
[RISCV] Replace getSimpleValueType() with getValueType() in DAG combines to prevent asserts with weird types.

3 years ago[NFC] SmallVector<char...> to SmallString<...>
Nathan James [Fri, 27 Nov 2020 20:36:09 +0000 (20:36 +0000)]
[NFC] SmallVector<char...> to SmallString<...>

3 years ago[ValueTracking] Fix assert on shufflevector of pointers
Nikita Popov [Fri, 27 Nov 2020 20:17:48 +0000 (21:17 +0100)]
[ValueTracking] Fix assert on shufflevector of pointers

In this case getScalarSizeInBits() is not well-defined. Use the
existing TyBits variable that handles vectors of pointers correctly.

3 years ago[RISCV] Remove stale FIXMEs from a couple test cases. NFC
Craig Topper [Fri, 27 Nov 2020 20:06:04 +0000 (12:06 -0800)]
[RISCV] Remove stale FIXMEs from a couple test cases. NFC

3 years agoRevert "[BasicAA] Fix BatchAA results for phi-phi assumptions"
Martin Storsjö [Fri, 27 Nov 2020 19:38:39 +0000 (21:38 +0200)]
Revert "[BasicAA] Fix BatchAA results for phi-phi assumptions"

This reverts commit 8166ed1a7a26ee8ea8db9005cc8ee5d156adad9b,
as it caused some compilations to hang/loop indefinitely, see
https://reviews.llvm.org/D91936 for details.

3 years ago[RISCV][LegalizeTypes] Teach type legalizer that it can promote UMIN/UMAX using SExtP...
Craig Topper [Fri, 27 Nov 2020 19:20:24 +0000 (11:20 -0800)]
[RISCV][LegalizeTypes] Teach type legalizer that it can promote UMIN/UMAX using SExtPromotedInteger if that's better for the target.

If Sext is cheaper than Zext for a target, we can use that to promote the operands of UMIN/UMAX. Using sext just makes numbers with the sign bit set even larger when treated as an unsigned number and it has no effect on number without the sign bit set. So the relative order doesn't change. This is similar to what we already do for promoting SETCC.

This is helpful on RISCV where i32 arguments are sign extended on RV64 and many instructions are able to produce results with 33 sign bits.

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

3 years ago[RISCV] Replace sexti32/zexti32 in isel patterns where only one part of their PatFrag...
Craig Topper [Fri, 27 Nov 2020 19:11:41 +0000 (11:11 -0800)]
[RISCV] Replace sexti32/zexti32 in isel patterns where only one part of their PatFrags can match. NFCI

We had an zexti32 after a sign_extend_inreg. The AND X, 0xffffffff
part of the zexti32 should never occur since SimplifyDemandedBits
from the sign_extend_inreg would have removed it.

We also had sexti32 as the root node of a pattern, but SelectionDAGISel
matches assertsext early before the tablegen based patterns are
evaluated.

3 years ago[Hexagon] Improve check for HVX types
Krzysztof Parzyszek [Fri, 27 Nov 2020 19:09:34 +0000 (13:09 -0600)]
[Hexagon] Improve check for HVX types

Allow non-simple types, like <17 x i32> to be treated as HVX vector
types.

3 years ago[libc++] Use std::move in numeric algorithms (P0616R0).
zoecarver [Fri, 27 Nov 2020 19:05:03 +0000 (11:05 -0800)]
[libc++] Use std::move in numeric algorithms (P0616R0).

This patch updates algorithms in <numeric> to use std::move
based on p0616r0. Moving values instead of copying them
creates huge speed improvements (see the paper for details).

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

3 years ago[AIX][XCOFF][NFC] Change geNumberOfVRSaved function name to getNumberOfVRSaved.
diggerlin [Fri, 27 Nov 2020 18:37:43 +0000 (13:37 -0500)]
[AIX][XCOFF][NFC] Change geNumberOfVRSaved function name to getNumberOfVRSaved.

SUMMARY:

  Change geNumberOfVRSaved function name to getNumberOfVRSaved of class TBVectorExt

Reviewers: hubert.reinterpretcast, Jason Liu
Differential Revision: https://reviews.llvm.org/D92225

3 years agolld-link: Let LLD_REPRODUCE control /reproduce:, like in ld.lld
Nico Weber [Fri, 27 Nov 2020 18:33:55 +0000 (13:33 -0500)]
lld-link: Let LLD_REPRODUCE control /reproduce:, like in ld.lld

Also sync help texts for the option between elf and coff ports.

Decisions:
- Do this even if /lldignoreenv is passed. /reproduce: does not affect
  the main output, and this makes the env var more convenient to use.
  (On the other hand, it's now possible to set this env var and forget
  about it, and all future builds in the same shell will be much slower.
  That's true for ld.lld, but posix shells have an easy way to set an
  env var for a single command; in cmd.exe this is not possible without
  contortions. Then again, lld-link runs in posix shells too.)

Original patch rebased across D68378 and D68381.

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

3 years ago[AArch64] Define __ARM_FEATURE_{CRC32,ATOMICS}
Andre Vieira [Fri, 13 Nov 2020 13:56:43 +0000 (13:56 +0000)]
[AArch64] Define __ARM_FEATURE_{CRC32,ATOMICS}

This patch implements the definition of __ARM_FEATURE_ATOMICS and fixes the
missing definition of __ARM_FEATURE_CRC32 for Armv8.1-A.

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

3 years agoTargetProcessControl.cpp - Remove warning: extra ‘;’
Sylvestre Ledru [Fri, 27 Nov 2020 17:19:35 +0000 (18:19 +0100)]
TargetProcessControl.cpp - Remove warning: extra ‘;’

3 years ago[VPlan] Use VPTransformState::set in widenGEP.
Florian Hahn [Fri, 27 Nov 2020 16:59:30 +0000 (16:59 +0000)]
[VPlan] Use VPTransformState::set in widenGEP.

This patch updates widenGEP to manage the resulting vector values using
the VPValue of VPWidenGEP recipe.

3 years ago[libc++] Introduce an indirection to create threads in the test suite
Louis Dionne [Mon, 23 Nov 2020 20:52:03 +0000 (15:52 -0500)]
[libc++] Introduce an indirection to create threads in the test suite

We create threads using std::thread in various places in the test suite.
However, the usual std::thread constructor may not work on all platforms,
e.g. on platforms where passing a stack size is required to create a thread.

This commit introduces a simple indirection that makes it easier to tweak
how threads are created inside the test suite on various platforms. Note
that tests that are purposefully calling std::thread's constructor directly
(e.g. because that is what they're testing) were not modified.

3 years ago[AllocaInst] Update `getAllocationSizeInBits` to return `TypeSize`.
Francesco Petrogalli [Fri, 27 Nov 2020 16:32:05 +0000 (16:32 +0000)]
[AllocaInst] Update `getAllocationSizeInBits` to return `TypeSize`.

Reviewed By: peterwaller-arm, sdesmalen

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

3 years ago[X86] Add AVX2/AVX512 test coverage in sat-add.ll
Simon Pilgrim [Fri, 27 Nov 2020 16:11:02 +0000 (16:11 +0000)]
[X86] Add AVX2/AVX512 test coverage in sat-add.ll

Shows the failure to combine to uaddsat

3 years ago[Hexagon] Add HVX support for ISD::SMAX/SMIN/UMAX/UMIN instead of custom dag patterns
Simon Pilgrim [Fri, 27 Nov 2020 15:45:58 +0000 (15:45 +0000)]
[Hexagon] Add HVX support for ISD::SMAX/SMIN/UMAX/UMIN instead of custom dag patterns

Followup to D92112 now that I've learnt about HVX type splitting.

This is some necessary cleanup work for min/max ops to eventually help us move the add/sub sat patterns into DAGCombine - D91876.

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

3 years ago[libomptarget][cuda] Detect missing symbols in plugin at build time
Jon Chesterfield [Fri, 27 Nov 2020 15:39:20 +0000 (15:39 +0000)]
[libomptarget][cuda] Detect missing symbols in plugin at build time

[libomptarget][cuda] Detect missing symbols in plugin at build time

Passes -z,defs to the linker. Error on unresolved symbol references.

Otherwise, those unresolved symbols present as target code running on the host
as the plugin fails to load. This is significantly harder to debug than a link
time error. Flag matches that passed by amdgcn and ve plugins.

Reviewed By: tianshilei1992

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

3 years ago[libc++] Formalize what configurations are covered by the ABI lists
Louis Dionne [Thu, 26 Nov 2020 20:00:42 +0000 (15:00 -0500)]
[libc++] Formalize what configurations are covered by the ABI lists

By encoding ABI-affecting properties in the name of the ABI list, it
makes it clear when an ABI list test should or should not be available,
and what results we should expect.

Note that we clearly don't encode all ABI-affecting parameters in the
name right now -- I just ported over what we supported in the code that
was there previously. As we encounter configurations that we wish to
support but produce different ABI lists, we can add those to the ABI
identifier and start supporting them.

This commit also starts checking the ABI list in the CI jobs that run
a supported configuration. Eventually, all configurations should have
a generated ABI list and the test should even run implicitly as part of
the Lit test suite.

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

3 years ago[libc++] Replace several uses of 0 by nullptr
Bruce Mitchener [Tue, 24 Nov 2020 17:53:53 +0000 (12:53 -0500)]
[libc++] Replace several uses of 0 by nullptr

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

3 years ago[TableGen][SchedModels] Get rid of hasVariant. NFC
Evgeny Leviant [Fri, 27 Nov 2020 15:00:02 +0000 (18:00 +0300)]
[TableGen][SchedModels] Get rid of hasVariant. NFC

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

3 years ago[AIX] Enabling vector type arguments and return for AIX
Zarko Todorovski [Fri, 27 Nov 2020 13:31:56 +0000 (08:31 -0500)]
[AIX] Enabling vector type arguments and return for AIX

This patch enables vector type arguments on AIX.  All non-aggregate Altivec vector types are 16bytes in size and are 16byte aligned.

Reviewed By: Xiangling_L

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

3 years agoDon't elide splat attributes during printing
Tamas Berghammer [Thu, 26 Nov 2020 11:03:12 +0000 (11:03 +0000)]
Don't elide splat attributes during printing

A splat attribute have a single element during printing so we should
treat it as such when we decide if we elide it or not based on the flag
intended to elide large attributes.

Reviewed By: rriddle, mehdi_amini

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

3 years agoRevert "[ASTMatchers] Matcher macros with params move params instead of copying"
Hans Wennborg [Fri, 27 Nov 2020 13:43:14 +0000 (14:43 +0100)]
Revert "[ASTMatchers] Matcher macros with params move params instead of copying"

This broke some clang matcher tests in 32-bit MSVC builds; see PR46781.

> Summary: Use move semantics instead of copying for AST Matchers with parameters
>
> Reviewers: aaron.ballman, gribozavr2
>
> Reviewed By: gribozavr2
>
> Subscribers: cfe-commits
>
> Tags: #clang
>
> Differential Revision: https://reviews.llvm.org/D75096

This reverts commit 3e9a7b2ba470bbe9cf3de3e4b15ba09dcfd206aa.

3 years ago[AArch64][SLP] Precommit tests which would be better not to SLP vectorize. NFC.
Sjoerd Meijer [Fri, 27 Nov 2020 13:41:35 +0000 (13:41 +0000)]
[AArch64][SLP] Precommit tests which would be better not to SLP vectorize. NFC.

3 years ago[OpenCL] Check for extension string extension lookup
Erik Tomusk [Fri, 27 Nov 2020 10:14:16 +0000 (10:14 +0000)]
[OpenCL] Check for extension string extension lookup

Calling any of the OpenCLOptions::is*() functions (except isKnown())
with an unknown extension string results in a seg fault. This patch
checks that the extension exists in the map before attempting to access
it.

Reviewed By: Anastasia

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

3 years ago[mlir] Fix typos and broken links in LangRef
Felipe de Azevedo Piovezan [Fri, 27 Nov 2020 13:07:01 +0000 (14:07 +0100)]
[mlir] Fix typos and broken links in LangRef

Many pages have had their titles renamed over time,
causing broken links to spread throughout the documentation.

Reviewed By: ftynse

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

3 years ago[obj2yaml] - Dump the `EShNum` key in some cases.
Georgii Rymar [Thu, 26 Nov 2020 13:05:38 +0000 (16:05 +0300)]
[obj2yaml] - Dump the `EShNum` key in some cases.

This patch starts emitting the `EShNum` key, when the `e_shnum = 0`
and the section header table exists.

`e_shnum` might be 0, when the the number of entries in the section header
table is larger than or equal to SHN_LORESERVE (0xff00).
In this case the real number of entries
in the section header table is held in the `sh_size`
member of the initial entry in section header table.

Currently, obj2yaml crashes when an object has `e_shoff != 0` and the `sh_size`
member of the initial entry in section header table is `0`.
This patch fixes it.

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

3 years ago[libc++] [docs] Exclude helper files from Sphinx configuration to avoid generating...
Marek Kurdej [Fri, 27 Nov 2020 12:47:20 +0000 (13:47 +0100)]
[libc++] [docs] Exclude helper files from Sphinx configuration to avoid generating empty pages.

3 years ago[obj2yaml] - Don't assert when trying to calculate the expected section offset.
Georgii Rymar [Thu, 26 Nov 2020 10:40:39 +0000 (13:40 +0300)]
[obj2yaml] - Don't assert when trying to calculate the expected section offset.

The following line asserts when `sh_addralign > MAX_UINT32 && (uint32_t)sh_addralign == 0`:

```
    ExpectedOffset = alignTo(ExpectedOffset,
                             SecHdr.sh_addralign ? SecHdr.sh_addralign : 1);
```

it happens because `sh_addralign` is truncated to 32-bit value, but `alignTo`
doesn't accept `Align == 0`. We should change `1` to `1uLL`.

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

3 years ago[ARM] MVE qabs vectorization test. NFC
David Green [Fri, 27 Nov 2020 12:21:11 +0000 (12:21 +0000)]
[ARM] MVE qabs vectorization test. NFC

3 years ago[SLP] Dump Tree costs. NFC.
Sjoerd Meijer [Fri, 27 Nov 2020 11:30:45 +0000 (11:30 +0000)]
[SLP] Dump Tree costs. NFC.

This adds LLVM_DEBUG messages to dump the (intermediate) tree cost
calculations, which is useful to trace and see how the final cost is
calculated.

3 years ago[DAG] Legalize umin(x,y) -> sub(x,usubsat(x,y)) and umax(x,y) -> add(x,usubsat(y...
Simon Pilgrim [Fri, 27 Nov 2020 11:00:34 +0000 (11:00 +0000)]
[DAG] Legalize umin(x,y) -> sub(x,usubsat(x,y)) and umax(x,y) -> add(x,usubsat(y,x)) iff usubsat is legal

If usubsat() is legal, this is likely to result in smaller codegen expansion than the default cmp+select codegen expansion.

Allows us to move the x86-specific lowering to the generic expansion code.

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

3 years ago[X86] Regenerate extract-store.ll tests
Simon Pilgrim [Thu, 26 Nov 2020 18:50:29 +0000 (18:50 +0000)]
[X86] Regenerate extract-store.ll tests

Rename prefix from X32 to X86 as we typically use X32 for gnux32 triples

3 years ago[libc] Fix typo in buildbot README.txt.
Cheng Wang [Thu, 29 Oct 2020 11:10:44 +0000 (19:10 +0800)]
[libc] Fix typo in buildbot README.txt.

Reviewed By: sivachandra

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

3 years ago[LegacyPM] Avoid a redundant map lookup in setLastUser. NFC.
Jay Foad [Thu, 26 Nov 2020 16:48:14 +0000 (16:48 +0000)]
[LegacyPM] Avoid a redundant map lookup in setLastUser. NFC.

As a bonus this makes it (IMO) obvious that the iterator is not
invalidated, so remove the comment explaining that.

3 years ago[LegacyPM] Remove unused undocumented parameter. NFC.
Jay Foad [Fri, 27 Nov 2020 10:03:05 +0000 (10:03 +0000)]
[LegacyPM] Remove unused undocumented parameter. NFC.

The Direction parameter to AnalysisResolver::getAnalysisIfAvailable has
never been documented or used for anything.

3 years ago[ASTImporter] Import the default argument of NonTypeTemplateParmDecl
Raphael Isemann [Thu, 26 Nov 2020 17:02:25 +0000 (18:02 +0100)]
[ASTImporter] Import the default argument of NonTypeTemplateParmDecl

The test case isn't using the AST matchers for all checks as there doesn't seem to be support for
matching NonTypeTemplateParmDecl default arguments. Otherwise this is simply importing the
default arguments.

Reviewed By: martong

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

3 years ago[SVE] Add a couple of extra sizeless type tests
Richard Sandiford [Thu, 5 Mar 2020 19:23:35 +0000 (19:23 +0000)]
[SVE] Add a couple of extra sizeless type tests

This patch adds tests for things that happened to be fixed by previous
patches, but that should continue working if we do decide to treat
sizeless types as incomplete types.

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

3 years ago[InstSimplify] Clarify use of FixedVectorType in SimplifySelectInst
Cullen Rhodes [Tue, 24 Nov 2020 18:07:13 +0000 (18:07 +0000)]
[InstSimplify] Clarify use of FixedVectorType in SimplifySelectInst

Folding a select of vector constants that include undef elements only
applies to fixed vectors, but there's no earlier check the type is not
scalable so it crashes for scalable vectors. This adds a check so this
optimization is only attempted for fixed vectors.

Reviewed By: sdesmalen

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

3 years agoReland [SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions
Roman Lebedev [Fri, 27 Nov 2020 07:21:33 +0000 (10:21 +0300)]
Reland [SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions

This was orginally committed in 2245fb8aaa1c1f85f53f7b19a1ee3ac69b1a1dfe.
but was immediately reverted in f3abd54958ab90ba7c100d3fa936a3ce0dd2ad04
because of a PHI handling issue.

Original commit message:

1. It doesn't make sense to enforce that the bonus instruction
   is only used once in it's basic block. What matters is
   whether those user instructions fit within our budget, sure,
   but that is another question.
2. It doesn't make sense to enforce that said bonus instructions
   are only used within their basic block. Perhaps the branch
   condition isn't using the value computed by said bonus instruction,
   and said bonus instruction is simply being calculated
   to be used in successors?

So iff we can clone bonus instructions, to lift these restrictions,
we just need to carefully update their external uses
to use the new cloned instructions.

Notably, this transform (even without this change) appears to be
poison-unsafe as per alive2, but is otherwise (including the patch) legal.

We don't introduce any new PHI nodes, but only "move" the instructions
around, i'm not really seeing much potential for extra cost modelling
for the transform, especially since now we allow at most one such
bonus instruction by default.

This causes the fold to fire +11.4% more (13216 -> 14725)
as of vanilla llvm test-suite + RawSpeed.

The motivational pattern is IEEE-754-2008 Binary16->Binary32
extension code:
https://github.com/darktable-org/rawspeed/blob/ca57d77fb2ba81f21fc712cfac26e54f46406473/src/librawspeed/common/FloatingPoint.h#L115-L120
^ that should be a switch, but it is not now: https://godbolt.org/z/bvja5v
That being said, even thought this seemed like this would fix it: https://godbolt.org/z/xGq3TM
apparently that fold is happening somewhere else afterall,
so something else also has a similar 'artificial' restriction.

3 years ago[NFC][SimplifyCFG] FoldBranchToCommonDest: add one more test with PHI
Roman Lebedev [Fri, 27 Nov 2020 08:47:41 +0000 (11:47 +0300)]
[NFC][SimplifyCFG] FoldBranchToCommonDest: add one more test with PHI

This is the problematic pattern i didn't think of,
that lead to revert of 2245fb8aaa1c1f85f53f7b19a1ee3ac69b1a1dfe
in f3abd54958ab90ba7c100d3fa936a3ce0dd2ad04.

3 years ago[MLIR][SCF] Find all innermost loops for parallel loop tiling
Frederik Gossen [Fri, 27 Nov 2020 09:06:29 +0000 (10:06 +0100)]
[MLIR][SCF] Find all innermost loops for parallel loop tiling

Overcome the assumption that parallel loops are only nested in other parallel
loops.

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

3 years ago[mlir] Add gpu.allocate, gpu.deallocate ops with LLVM lowering to runtime function...
Christian Sigg [Tue, 24 Nov 2020 21:07:34 +0000 (22:07 +0100)]
[mlir] Add gpu.allocate, gpu.deallocate ops with LLVM lowering to runtime function calls.

The ops are very similar to the std variants, but support async GPU execution.

gpu.alloc does not currently support an alignment attribute, and the new ops do not have
canonicalizers/folders like their std siblings do.

Reviewed By: herhut

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

3 years ago[msan] Fix bugs when instrument x86.avx512*_cvt* intrinsics.
Wang, Pengfei [Fri, 27 Nov 2020 08:02:09 +0000 (16:02 +0800)]
[msan] Fix bugs when instrument x86.avx512*_cvt* intrinsics.

Scalar intrinsics x86.avx512*_cvt* have an extra rounding mode operand.
We can directly ignore it to reuse the SSE/AVX math.
This fix the bug https://bugs.llvm.org/show_bug.cgi?id=48298.

Reviewed By: craig.topper

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

3 years ago[mlir] Let ModuleTranslate propagate LLVM triple
Nicolas Vasilache [Thu, 26 Nov 2020 15:58:34 +0000 (15:58 +0000)]
[mlir] Let ModuleTranslate propagate LLVM triple

This adds LLVM triple propagation and updates the test that did not check it properly.

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

3 years ago[libc][Obvious] Fix typo in strnlen_test.cpp.
Cheng Wang [Fri, 27 Nov 2020 07:38:16 +0000 (15:38 +0800)]
[libc][Obvious] Fix typo in strnlen_test.cpp.

3 years agoRevert "[DebugInfo] Improve dbg preservation in LSR."
Markus Lavin [Fri, 27 Nov 2020 07:49:20 +0000 (08:49 +0100)]
Revert "[DebugInfo] Improve dbg preservation in LSR."

This reverts commit 06758c6a6135f59deec8e73d4fcb69946ab47f54.

Bug: https://bugs.llvm.org/show_bug.cgi?id=48166
Additional discussion in: https://reviews.llvm.org/D91711

3 years ago[llvm-readelf/obj] - Stop calling `reportError` in `printArchSpecificInfo()`.
Georgii Rymar [Wed, 25 Nov 2020 11:54:35 +0000 (14:54 +0300)]
[llvm-readelf/obj] - Stop calling `reportError` in `printArchSpecificInfo()`.

This is related to MIPS. Currently we might report an error and exit,
though there is no problem to report a warning and try to continue dumping
an object. The code uses `MipsGOTParser<ELFT> Parser`, which is isolated
in this method.

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

3 years ago[RISCV] Don't remove (and X, 0xffffffff) from inputs when matching RISCVISD::DIVUW...
Craig Topper [Fri, 27 Nov 2020 06:31:13 +0000 (22:31 -0800)]
[RISCV] Don't remove (and X, 0xffffffff) from inputs when matching RISCVISD::DIVUW/REMUW to 64-bit DIVU/REMU.

These patterns are using zexti32 which matches either assertzexti32
or (and X, 0xffffffff). But if we match (and X, 0xffffffff) it will
remove the AND and the inputs may no longer have the zero bits
needed to guarantee the result has enough zeros.

This commit changes the patterns to only match assertzexti32.
I'm not sure how to test the broken case since the DIVUW/REMUW nodes
are created during type legalization, but type legalization won't
create an (and X, 0xfffffffff) directly on the inputs.

I've also changed the zexti32 on the root of the pattern to just
checking for AND. We were previously also matching assertzexti32,
but I doubt that pattern would ever occur.

3 years ago[Test] Add some more tests showing how we fail to widen IV
Max Kazantsev [Fri, 27 Nov 2020 07:03:05 +0000 (14:03 +0700)]
[Test] Add some more tests showing how we fail to widen IV

3 years ago[IR] Use llvm::is_contained and pred_size (NFC)
Kazu Hirata [Fri, 27 Nov 2020 06:02:04 +0000 (22:02 -0800)]
[IR] Use llvm::is_contained and pred_size (NFC)

3 years ago[IndVars] LCSSA Phi users should not prevent widening
Max Kazantsev [Fri, 27 Nov 2020 04:19:54 +0000 (11:19 +0700)]
[IndVars] LCSSA Phi users should not prevent widening

When widening an IndVar that has LCSSA Phi users outside
the loop, we can safely widen it as usual and then truncate
the result outside the loop without hurting the performance.

Differential Revision: https://reviews.llvm.org/D91593
Reviewed By: skatkov

3 years ago[clangd] Add support for within-file rename of complicated fields
Kirill Bobyrev [Fri, 27 Nov 2020 02:59:24 +0000 (03:59 +0100)]
[clangd] Add support for within-file rename of complicated fields

This was originally a part of D71880 but is separated for simplicity and ease
of reviewing.

Fixes: https://github.com/clangd/clangd/issues/582

Reviewed By: hokein

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

3 years ago[DAGCombine] Adding a hook to improve the precision of fsqrt if the input is denormal
QingShan Zhang [Fri, 27 Nov 2020 02:10:55 +0000 (02:10 +0000)]
[DAGCombine] Adding a hook to improve the precision of fsqrt if the input is denormal

For now, we will hardcode the result as 0.0 if the input is denormal or 0. That will
have the impact the precision. As the fsqrt added belong to the cold path of the
cmp+branch, it won't impact the performance for normal inputs for PowerPC, but improve
the precision if the input is denormal.

Reviewed By: Spatel

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

3 years ago[InlineCost] Fix indentation (NFC)
Kazu Hirata [Fri, 27 Nov 2020 02:00:54 +0000 (18:00 -0800)]
[InlineCost] Fix indentation (NFC)

3 years ago[LangRef] Add poison constant
Juneyoung Lee [Thu, 26 Nov 2020 10:33:42 +0000 (19:33 +0900)]
[LangRef] Add poison constant

This patch adds a description about the newly added poison constant to LangRef.

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

3 years ago[RISCV] Add isel patterns to use SBSET for (1 << X) by using X0 as the input.
Craig Topper [Thu, 26 Nov 2020 23:08:54 +0000 (15:08 -0800)]
[RISCV] Add isel patterns to use SBSET for (1 << X) by using X0 as the input.

3 years ago[clangd] Fix use of system-installed GRPC after f726101b6240a6740b3c0926af759da5e7336f8a
Sam McCall [Wed, 25 Nov 2020 16:18:00 +0000 (17:18 +0100)]
[clangd] Fix use of system-installed GRPC after f726101b6240a6740b3c0926af759da5e7336f8a

We need a real target now, and it was only being created if grpc was
built from source or imported from homebrew.

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

3 years ago[BasicAA] Fix BatchAA results for phi-phi assumptions
Nikita Popov [Sun, 22 Nov 2020 17:23:53 +0000 (18:23 +0100)]
[BasicAA] Fix BatchAA results for phi-phi assumptions

Add a flag that disables caching when computing aliasing results
potentially based on a phi-phi NoAlias assumption. We'll still
insert cache entries temporarily to catch infinite recursion,
but will drop them afterwards, so they won't persist in BatchAA.

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

3 years ago[test] Fix runtime-pointer-checking-insert-typesize.ll under NPM
Arthur Eubanks [Thu, 26 Nov 2020 20:33:24 +0000 (12:33 -0800)]
[test] Fix runtime-pointer-checking-insert-typesize.ll under NPM

Also clean it up a bit.

3 years ago[libc++] Install missing package in the Dockerfile
Louis Dionne [Thu, 26 Nov 2020 20:14:02 +0000 (15:14 -0500)]
[libc++] Install missing package in the Dockerfile

python3-distutils is required to use `import distutils.spawn`, which is
required by the ABI list targets.

3 years agoRevert "[SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions"
Roman Lebedev [Thu, 26 Nov 2020 20:11:26 +0000 (23:11 +0300)]
Revert "[SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions"

Many bots are unhappy, at the very least missed a few codegen tests,
and possibly this has a logic hole inducing a miscompile
(will be really awesome to have ready reproducer..)

Need to investigate.

This reverts commit 2245fb8aaa1c1f85f53f7b19a1ee3ac69b1a1dfe.

3 years ago[llvmbuildectomy] Also include component groups in llvm-config --components list
Mariusz Ceier [Thu, 26 Nov 2020 20:03:22 +0000 (21:03 +0100)]
[llvmbuildectomy] Also include component groups in llvm-config --components list

Without this change mesa fails while looking for llvm components like amdgpu, engine or native:

    Run-time dependency LLVM (modules: amdgpu(missing), bitreader, bitwriter, core, engine(missing), executionengine, instcombine, ipo, mcdisassembler, mcjit, native(missing), scalaropts, transformutils, coroutines)
    Looking for a fallback subproject for the dependency llvm (modules: bitwriter, engine, mcdisassembler, mcjit, core, executionengine, scalaropts, transformutils, instcombine, amdgpu, native, bitreader, ipo)

This change adds component groups (like all-targets, engine, native, amdgpu) to the "all" component.

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

3 years ago[SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions
Roman Lebedev [Thu, 26 Nov 2020 16:41:31 +0000 (19:41 +0300)]
[SimplifyCFG] FoldBranchToCommonDest: lift use-restriction on bonus instructions

1. It doesn't make sense to enforce that the bonus instruction
   is only used once in it's basic block. What matters is
   whether those user instructions fit within our budget, sure,
   but that is another question.
2. It doesn't make sense to enforce that said bonus instructions
   are only used within their basic block. Perhaps the branch
   condition isn't using the value computed by said bonus instruction,
   and said bonus instruction is simply being calculated
   to be used in successors?

So iff we can clone bonus instructions, to lift these restrictions,
we just need to carefully update their external uses
to use the new cloned instructions.

Notably, this transform (even without this change) appears to be
poison-unsafe as per alive2, but is otherwise (including the patch) legal.

We don't introduce any new PHI nodes, but only "move" the instructions
around, i'm not really seeing much potential for extra cost modelling
for the transform, especially since now we allow at most one such
bonus instruction by default.

This causes the fold to fire +11.4% more (13216 -> 14725)
as of vanilla llvm test-suite + RawSpeed.

The motivational pattern is IEEE-754-2008 Binary16->Binary32
extension code:
https://github.com/darktable-org/rawspeed/blob/ca57d77fb2ba81f21fc712cfac26e54f46406473/src/librawspeed/common/FloatingPoint.h#L115-L120
^ that should be a switch, but it is not now: https://godbolt.org/z/bvja5v
That being said, even thought this seemed like this would fix it: https://godbolt.org/z/xGq3TM
apparently that fold is happening somewhere else afterall,
so something else also has a similar 'artificial' restriction.

3 years ago[NFC][SimplifyCFG] Add test coverage for FoldBranchToCommonDest xform with live-out...
Roman Lebedev [Thu, 26 Nov 2020 12:21:56 +0000 (15:21 +0300)]
[NFC][SimplifyCFG] Add test coverage for FoldBranchToCommonDest xform with live-out bonus instuctions

The uses of the bonus instructions should not be preventing the transformation.

3 years ago[NFC][SimplifyCFG] Add statistic to `FoldBranchToCommonDest()` fold
Roman Lebedev [Thu, 26 Nov 2020 11:58:28 +0000 (14:58 +0300)]
[NFC][SimplifyCFG] Add statistic to `FoldBranchToCommonDest()` fold

3 years ago[libc++] Remove ABI lists for previous releases
Louis Dionne [Thu, 26 Nov 2020 19:45:07 +0000 (14:45 -0500)]
[libc++] Remove ABI lists for previous releases

We don't actually update the ABI lists at every release -- it's too much
work, since we'd technically have to do it even for minor releases.
Furthermore, I don't think anybody uses those (I certainly don't rely
on them for anything).

Instead, it is better to rely on the ABI list changelog and the canonical
ABI list that we always keep up to date. If one wants to know what symbols
were shipped in a specific release, that can be discovered easily using
Git, which is a superior tool than keeping textual copies of old versions.

3 years ago[libc++] Fix the Homebrew tap to install Buildkite on macOS hosts
Louis Dionne [Thu, 26 Nov 2020 19:40:38 +0000 (14:40 -0500)]
[libc++] Fix the Homebrew tap to install Buildkite on macOS hosts

3 years ago[clangd] AddUsing: do not crash on non-namespace using decls.
Adam Czachorowski [Thu, 26 Nov 2020 16:51:04 +0000 (17:51 +0100)]
[clangd] AddUsing: do not crash on non-namespace using decls.

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

3 years ago[X86] Regenerate i64-to-float.ll tests with avx512 coverage
Simon Pilgrim [Thu, 26 Nov 2020 18:29:37 +0000 (18:29 +0000)]
[X86] Regenerate i64-to-float.ll tests with avx512 coverage

Rename prefix from X32 to X86 as we typically use X32 for gnux32 triples

3 years ago[BPF][NewPM] Port bpf-adjust-opt to NPM and add it to pipeline
Arthur Eubanks [Thu, 19 Nov 2020 17:37:40 +0000 (09:37 -0800)]
[BPF][NewPM] Port bpf-adjust-opt to NPM and add it to pipeline

Reviewed By: yonghong-song

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

3 years ago[AA] Split up LocationSize::unknown()
Nikita Popov [Tue, 17 Nov 2020 19:11:09 +0000 (20:11 +0100)]
[AA] Split up LocationSize::unknown()

Currently, we have some confusion in the codebase regarding the
meaning of LocationSize::unknown(): Some parts (including most of
BasicAA) assume that LocationSize::unknown() only allows accesses
after the base pointer. Some parts (various callers of AA) assume
that LocationSize::unknown() allows accesses both before and after
the base pointer (but within the underlying object).

This patch splits up LocationSize::unknown() into
LocationSize::afterPointer() and LocationSize::beforeOrAfterPointer()
to make this completely unambiguous. I tried my best to determine
which one is appropriate for all the existing uses.

The test changes in cs-cs.ll in particular illustrate a previously
clearly incorrect AA result: We were effectively assuming that
argmemonly functions were only allowed to access their arguments
after the passed pointer, but not before it. I'm pretty sure that
this was not intentional, and it's certainly not specified by
LangRef that way.

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

3 years ago[MC] Set the unique id of .stack_sizes to the associated .text section's
Fangrui Song [Thu, 26 Nov 2020 17:13:08 +0000 (09:13 -0800)]
[MC] Set the unique id of .stack_sizes to the associated .text section's

Similar to D92113. Currently `clang -fstack-size-section -fno-unique-section-names`
sets the linked-to symbol to the first `.text`, which is:

* incorrect for COMDAT sections
* inferior for non-COMDAT sections in -ffunction-sections mode (poor --gc-sections: .stack_sizes cannot be separately discarded)

Note, if the section symbol can be referenced in more places (if the
function begin symbol does not apply), we probably should consider
defining a different BeginSymbol for sections with ",unique" linkage.

Reviewed By: grimar, jhenderson

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

3 years ago[AIX] Add support for non var_arg extended vector ABI calling convention on AIX
Zarko Todorovski [Thu, 26 Nov 2020 16:15:00 +0000 (11:15 -0500)]
[AIX] Add support for non var_arg extended vector ABI calling convention on AIX

This patch enables passing non variadic vector type parameters on the caller and callee side and vector return on AIX that are passed in vector registers only.

So far, support is enabled for only the AIX extended Altivec ABI Calling convention.

Reviewed By: sfertile, DiggerLin

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

3 years ago[ASTImporter] Import the default argument of TemplateTypeParmDecl
Raphael Isemann [Thu, 26 Nov 2020 16:02:31 +0000 (17:02 +0100)]
[ASTImporter] Import the default argument of TemplateTypeParmDecl

The test case isn't using the AST matchers for all checks as there doesn't seem to be support for
matching TemplateTypeParmDecl default arguments. Otherwise this is simply importing the
default arguments.

Also updates several LLDB tests that now as intended omit the default template
arguments of several std templates.

Reviewed By: martong

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

3 years ago[libc++] Remove sysctl-based implementation of thread::hardware_concurrency()
Louis Dionne [Wed, 25 Nov 2020 21:42:42 +0000 (16:42 -0500)]
[libc++] Remove sysctl-based implementation of thread::hardware_concurrency()

Using sysctl requires including headers that are considered internal on
Linux, like <sys/sysctl.h> & friends. Instead, sysconf is defined by POSIX
(and we have a fallback for Windows), so all the systems we support should
be happy with just sysconf.

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