platform/upstream/llvm.git
17 months ago[scudo] Mitigate page releasing thrashing
Chia-hung Duan [Fri, 3 Mar 2023 19:21:11 +0000 (19:21 +0000)]
[scudo] Mitigate page releasing thrashing

We have the heuristic to determine the threshold of doing page
releasing for smaller size classes. However, in a case that the
memory usage is bouncing between that threshold may result in
frequent try of page releasing but not returning much memory.

This CL add another heuristic to mitigate this problem by increasing
the minimum pages that potentially can be released. Note that this
heuristic is only applied on SizeClassAllocator64. SizeClassAllocator32
has a smaller group size so the overhead is smaller than 64-bit
platform.

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

17 months agoReland D144920 "[scudo] Only prepare PageMap entry for partial region
Chia-hung Duan [Fri, 3 Mar 2023 01:45:34 +0000 (01:45 +0000)]
Reland D144920 "[scudo] Only prepare PageMap entry for partial region

This reverts commit daaef4c49954cb04ea1831615e0876865a29a08a.

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

17 months ago[SelectionDAG] Optimize copyExtraInfo deep copy
Marco Elver [Mon, 6 Mar 2023 16:15:53 +0000 (17:15 +0100)]
[SelectionDAG] Optimize copyExtraInfo deep copy

It turns out that there are relatively trivial, albeit rare, cases that
require a MaxDepth of more than 16 (see added test). However, we want to
avoid having to rely on a large fixed MaxDepth.

Since these cases are relatively rare, apply the following strategy:

  1. Start with a low MaxDepth of 16 - if the entry node was not
     reached, we can return (the common case).

  2. If the entry node was reached, exponentially increase MaxDepth up
     to some large limit that should cover all cases and guard against
     stack exhaustion.

This retains the better performance with a low MaxDepth in the common
case, and in complex cases backs off and retries. On a whole, this is
preferable vs. starting with a large MaxDepth which would unnecessarily
penalize the common case where a low MaxDepth is sufficient.

Reviewed By: dvyukov

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

17 months ago[ADT] Clean up zip iterators. NFC.
Jakub Kuderski [Mon, 6 Mar 2023 16:10:59 +0000 (11:10 -0500)]
[ADT] Clean up zip iterators. NFC.

*  Use inheriting constructors declarations to avoid introducing the
   `Base` typedef and duplicate constructor definitions. This should make
   things cleaner, especially since `zip_common` also exposes a `Base`
   typedef.
*  Drop unnecessary template parameters.
*  Avoid double negation in `zip_shortest`'s `operator==` and rename the
   comparison function for better readability.

Reviewed By: zero9178

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

17 months ago[X86] combineBitcastvxi1/checkBitcastSrcVectorSize - sign-extend vXi1 allones vselect...
Simon Pilgrim [Mon, 6 Mar 2023 16:13:58 +0000 (16:13 +0000)]
[X86] combineBitcastvxi1/checkBitcastSrcVectorSize - sign-extend vXi1 allones vselect operands

Minor fix to Issue #61104

17 months ago[X86] Add Issue #61104 test case
Simon Pilgrim [Mon, 6 Mar 2023 16:09:05 +0000 (16:09 +0000)]
[X86] Add Issue #61104 test case

Shows the failure of combineBitcastvxi1 to sign-extend a vXi1 allones vselect operand

There's a number of other problems in Issue #61104 still to address, but this one has an easy quick fix

17 months ago[libc] Add arm 32 FEnvImpl.
Siva Chandra Reddy [Mon, 6 Mar 2023 08:48:57 +0000 (08:48 +0000)]
[libc] Add arm 32 FEnvImpl.

Reviewed By: lntue

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

17 months agoFix SafeIntIterator reference type
Guillaume Chatelet [Mon, 6 Mar 2023 14:13:07 +0000 (14:13 +0000)]
Fix SafeIntIterator reference type

We explicitly state that the `reference` type for Sequence iterator is a `value_type`.
Since the iterator is a lazy generator, it cannot point to any memory and so it cannot have a reference type.
Fixes https://github.com/llvm/llvm-project/issues/61122

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

17 months ago[LLDB][NativePDB] Check string table in PDB files.
Zequan Wu [Wed, 1 Mar 2023 21:28:35 +0000 (16:28 -0500)]
[LLDB][NativePDB] Check string table in PDB files.

Usually PDB files have a string table (aka: Named Stream "/names" ). PDB for
some windows system libraries might not have that. This adds the check for it to
avoid crash in the absence of string table.

Reviewed By: labath

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

17 months agoRename DebugAction to tracing::Action and move related code from lib/Support to lib...
Mehdi Amini [Mon, 23 Jan 2023 00:32:07 +0000 (00:32 +0000)]
Rename DebugAction to tracing::Action and move related code from lib/Support to lib/IR and lib/Debug

This is a preparation for adding support for more infrastructure around the concept
of Action and make tracing Action more of a first class concept.
The doc will be updated later in a subsequent revision after the changes are
completed.

Action belongs to IR because of circular dependency: Actions are dispatched through
the MLIRContext but Action will learn to encapsulate IR construct.

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

17 months ago[Flang] [PowerPC} Implement the floating-point conversion PowerPC intrinsics
Paul Scoropan [Wed, 1 Mar 2023 17:50:45 +0000 (12:50 -0500)]
[Flang] [PowerPC} Implement the floating-point conversion PowerPC intrinsics

All the fc* floating point conversion PowerPC intrinsics are simply lowered to their LLVM IR intrinsic counterparts and do not require any additional error checking.

Reviewed By: klausler, jeanPerier

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

17 months agoChange the DebugAction paradigm to delegate the control to the handler
Mehdi Amini [Tue, 18 Oct 2022 23:03:48 +0000 (23:03 +0000)]
Change the DebugAction paradigm to delegate the control to the handler

At the moment, we invoke `shouldExecute()` that way:

```
if (manager.shouldExecute<DebugAction>(currentOp) {
  // apply a transformation
  …
}
```

In this sequence, the manager isn’t involved in the actual execution
of the action and can’t develop rich instrumentations. Instead the API
could let the control to the handler itself:

```
// Execute the action under the control of the manager
manager.execute<DebugAction>(currentOp, [&]() {
  // apply the transformation in this callback
  …
});
```

This inversion of control (by injecting a callback) allows handlers to
implement potentially new interesting features: for example, snapshot
the IR before and after the action, or record an action execution time.
More importantly, it will allow to capture the nesting execution of
actions.

On the other side: handlers receives now a DebugAction object that wraps
generic information (tag and description especially) as well as
action-specific data.

Finally, the DebugActionManager is now enabled in release builds as
well.

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

17 months ago[X86] vector-shuffle-avx512.ll - update to use attributes instead of hard coded cpu...
Simon Pilgrim [Mon, 6 Mar 2023 14:45:49 +0000 (14:45 +0000)]
[X86] vector-shuffle-avx512.ll - update to use attributes instead of hard coded cpu targets

Similar to most of the other vector-shuffle-* test files

Avoids some codegen deltas due to upcoming changes for no-costs domain switching between shuffle types

17 months ago[libc++] Add support for .compile.pass.mm and .link.pass.mm tests
Louis Dionne [Thu, 2 Mar 2023 22:28:13 +0000 (17:28 -0500)]
[libc++] Add support for .compile.pass.mm and .link.pass.mm tests

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

17 months ago[flang] Implement ieee_is_normal
David Truby [Mon, 27 Feb 2023 15:37:08 +0000 (15:37 +0000)]
[flang] Implement ieee_is_normal

This patch adds an implementation of ieee_is_normal using a call
to llvm.is.fpclass.

Depends on D144649

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

17 months ago[flang] Fix lowering of optional char proc args
Leandro Lupori [Fri, 24 Feb 2023 11:57:50 +0000 (11:57 +0000)]
[flang] Fix lowering of optional char proc args

Optional character function arguments were not being lowered
properly. As they are passed as a tuple, containing the (boxed)
function address and the character length, it is not possible for
fir.absent to handle it directly. Instead, a tuple needs to be
created and filled with an absent function address and a dummy
character length.

Fixes #60225

Reviewed By: jeanPerier

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

17 months ago[NFC] Disable test temporarily to investigate why it's failing on AIX
Jake Egan [Mon, 6 Mar 2023 14:22:05 +0000 (09:22 -0500)]
[NFC] Disable test temporarily to investigate why it's failing on AIX

Test failing due to D145098. Disabling the test to get the AIX bot
green while investigating.

17 months agoExpose a convenient registerCLOptions() for MlirOptMainConfig
Mehdi Amini [Sat, 25 Feb 2023 04:16:37 +0000 (21:16 -0700)]
Expose a convenient registerCLOptions() for MlirOptMainConfig

This allows for downstream *-opt tools to stay always aligned with the options
exposed by mlir-opt.
It aligns the "generic" options with the more "components" ones like the
pass manager options or the context options.

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

17 months ago[InstCombine] Implement "A & (~A | B) --> A & B" like transforms for boolean based...
Paul Walker [Thu, 2 Mar 2023 14:10:11 +0000 (14:10 +0000)]
[InstCombine] Implement "A & (~A | B) --> A & B" like transforms for boolean based selects.

Alive2 links for "A & (~A | B) --> A & B":
https://alive2.llvm.org/ce/z/oKiodu (scalar)
https://alive2.llvm.org/ce/z/8yn8GL (vector)

Alive2 links for "A | (~A & B) --> A | B"
https://alive2.llvm.org/ce/z/v5GEKu (scalar)
https://alive2.llvm.org/ce/z/wvtJsj (vector)

NOTE: The commutative variants of these transforms, for example:
  "(~A | B) & A --> A & B"
are already handled by simplifying the underlying selects to
normal logical operations due to that combination having simpler
poison semantics.

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

17 months ago[DebugInfo] Merge partially matching chains of inlined locations
David Stenberg [Mon, 6 Mar 2023 10:15:53 +0000 (11:15 +0100)]
[DebugInfo] Merge partially matching chains of inlined locations

For example, if you have a chain of inlined funtions like this:

   1 #include <stdlib.h>
   2 int g1 = 4, g2 = 6;
   3
   4 static inline void bar(int q) {
   5   if (q > 5)
   6     abort();
   7 }
   8
   9 static inline void foo(int q) {
  10   bar(q);
  11 }
  12
  13 int main() {
  14   foo(g1);
  15   foo(g2);
  16   return 0;
  17 }

with optimizations you could end up with a single abort call for the two
inlined instances of foo(). When merging the locations for those inlined
instances you would previously end up with a 0:0 location in main().
Leaving out that inlined chain from the location for the abort call
could make troubleshooting difficult in some cases.

This patch changes DILocation::getMergedLocation() to try to handle such
cases. The function is rewritten to first find a common starting point
for the two locations (same subprogram and inlined-at location), and
then in reverse traverses the inlined-at chain looking for matches in
each subprogram. For each subprogram, the merge function will find the
nearest common scope for the two locations, and matching line and
column (or set them to 0 if not matching).

In the example above, you will for the abort call get a location in
bar() at 6:5, inlined in foo() at 10:3, inlined in main() at 0:0 (since
the two inlined functions are on different lines, but in the same
scope).

I have not seen anything in the DWARF standard that would disallow
inlining a non-zero location at 0:0 in the inlined-at function, and both
LLDB and GDB seem to accept these locations (with D142552 needed for
LLDB to handle cases where the file, line and column number are all 0).
One incompatibility with GDB is that it seems to ignore 0-line locations
in some cases, but I am not aware of any specific issue that this patch
produces related to that.

With x86-64 LLDB (trunk) you previously got:

  frame #0: 0x00007ffff7a44930 libc.so.6`abort
  frame #1: 0x00005555555546ec a.out`main at merge.c:0

and will now get:

  frame #0: 0x[...] libc.so.6`abort
  frame #1: 0x[...] a.out`main [inlined] bar(q=<unavailable>) at merge.c:6:5
  frame #2: 0x[...] a.out`main [inlined] foo(q=<unavailable>) at merge.c:10:3
  frame #3: 0x[...] a.out`main at merge.c:0

and with x86-64 GDB (11.1) you will get:

  (gdb) bt
  #0  0x00007ffff7a44930 in abort () from /lib64/libc.so.6
  #1  0x00005555555546ec in bar (q=<optimized out>) at merge.c:6
  #2  foo (q=<optimized out>) at merge.c:10
  #3  0x00005555555546ec in main ()

Reviewed By: aprantl, dblaikie

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

17 months ago[lldb] Make GetDIENamesAndRanges() allow 0-valued decl and call lines
David Stenberg [Mon, 6 Mar 2023 10:18:24 +0000 (11:18 +0100)]
[lldb] Make GetDIENamesAndRanges() allow 0-valued decl and call lines

In an upcoming patch, D142556, Clang is proposed to be changed to emit
line locations that are inlined at line 0. This clashed with the behavior of
GetDIENamesAndRanges() which used 0 as a default value to determine if
file, line or column numbers had been set. Users of that function then
checked for any non-0 values when setting up the call site:

  if (call_file != 0 || call_line != 0 || call_column != 0)
    [...]

which did not work with the Clang change since all three values then
could be 0.

This changes the function to use std::optional to catch non-set values
instead.

Reviewed By: clayborg

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

17 months ago[flang] Handle parent component in select type
Valentin Clement [Mon, 6 Mar 2023 13:09:38 +0000 (14:09 +0100)]
[flang] Handle parent component in select type

In select type construct the associating entity in a TYPE IS
type guard statement is obtained with a fir.convert. Update the code
for the parent component to support fir.convert defining op
as well.

Reviewed By: jeanPerier

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

17 months ago[Tooling/Inclusion] Add missing index_sequence symbols.
Haojian Wu [Mon, 6 Mar 2023 11:06:44 +0000 (12:06 +0100)]
[Tooling/Inclusion] Add missing index_sequence symbols.

Fixes https://github.com/llvm/llvm-project/issues/61026

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

17 months ago[flang][hlfir] Lower intrinsic module procedures to HLFIR
Jean Perier [Mon, 6 Mar 2023 13:00:26 +0000 (14:00 +0100)]
[flang][hlfir] Lower intrinsic module procedures to HLFIR

Intrinsic module procedures are a bit different from intrinsic
procedures: they are defined in intrinsic module files, but their
signature and representation in semantics is the same as user
procedures.
The code to lower them in lowering (when they are not implemented in
Fortran) is the same as for intrinsic procedures
(Optimizer/Builder/IntrinsicCall.cpp).

The dispatching in in HLFIR procedure reference lowering must be
slightly modified so that these evaluate::ProcRef that have a
semantics::Symbol instead of an evaluate::SpecificIntrinsic can
be dispatched as evaluate::SpecificIntrinsic:
 - move isIntrinsicModuleProcedure to detect them
 - in the helpers dealing with intrinsics, make evaluate::SpecificIntrinsic
   a pointer argument that can be null for intrinsic module procedures.
 - add getProcedureName() to call context to avoid relying on the
   evaluate::SpecificIntrinsic when it is not know to be null.

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

17 months ago[flang][hlfir] use new runtime for whole allocatable assignment
Jean Perier [Mon, 6 Mar 2023 12:59:15 +0000 (13:59 +0100)]
[flang][hlfir] use new runtime for whole allocatable assignment

- use AssignExplicitLengthCharacter for assignment to whole allocatable
  character with assumed or explicit length.
- use AssignPolymorphic for assignment to whole allocatable
  polymorphic.

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

17 months ago[mlir][IR] Clean up mergeBlockBefore and mergeBlocks
Matthias Springer [Mon, 6 Mar 2023 11:38:18 +0000 (12:38 +0100)]
[mlir][IR] Clean up mergeBlockBefore and mergeBlocks

* `RewriterBase::mergeBlocks` is simplified: it is implemented in terms of `mergeBlockBefore`.
* The signature of `mergeBlockBefore` is consistent with other API (such as `inlineRegionBefore`): an overload for a `Block::iterator` is added.
* Additional safety checks are added to `mergeBlockBefore`: detect cases where the resulting IR could be invalid (no more `dropAllUses`) or partly unreachable (likely a case of incorrect API usage).
* Rename `mergeBlockBefore` to `inlineBlockBefore`.

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

17 months ago[AMDGPU] Use UniformityAnalysis in LateCodeGenPrepare
pvanhout [Mon, 6 Mar 2023 11:28:14 +0000 (12:28 +0100)]
[AMDGPU] Use UniformityAnalysis in LateCodeGenPrepare

Reviewed By: foad

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

17 months ago[NFC][AArch64] Use 'i' to encode the offset form of load/store.
Hsiangkai Wang [Mon, 16 Jan 2023 04:21:51 +0000 (04:21 +0000)]
[NFC][AArch64] Use 'i' to encode the offset form of load/store.

STG, STZG, ST2G, STZ2G are the exceptions to append 'Offset' to name the
offset format of load/store instructions. All other load/store
instructions use 'i' as the appendix. If there is no special reason to
do so, we should make the naming consistent.

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

17 months ago[AMDGPU] Use UniformityAnalysis in CodeGenPrepare
pvanhout [Mon, 6 Mar 2023 08:19:57 +0000 (09:19 +0100)]
[AMDGPU] Use UniformityAnalysis in CodeGenPrepare

A little extra change was needed in UA because it didn't consider
InvokeInst and it made call-constexpr.ll assert.

Reviewed By: sameerds, arsenm

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

17 months ago[include-cleaner] Fix a crash on non-identifier-name symbols.
Haojian Wu [Mon, 6 Mar 2023 10:45:44 +0000 (11:45 +0100)]
[include-cleaner] Fix a crash on non-identifier-name symbols.

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

17 months ago[IR] Remove ConstantExpr::getUMin() (NFC)
Nikita Popov [Mon, 6 Mar 2023 12:12:55 +0000 (13:12 +0100)]
[IR] Remove ConstantExpr::getUMin() (NFC)

This is part of select constant expression removal. As there is
only a single place where this is used, just expand it to explicit
constant folding calls.

(Normally we'd just use the IRBuilder here, but this isn't possible
due to mergeUndefsWith use).

17 months ago[CMake] Enforce LLVM_ENABLE_UNWIND_TABLES
Luís Marques [Mon, 6 Mar 2023 12:08:28 +0000 (13:08 +0100)]
[CMake] Enforce LLVM_ENABLE_UNWIND_TABLES

In D61448 the cmake option `LLVM_ENABLE_UNWIND_TABLES` was added.
Despite the name suggesting that the option enables unwind tables, that
patch only uses it to disable them. That makes a difference for
architectures where unwind tables aren't enabled by default. The lack of
unwind tables impacts backtraces and the current handling of the option
doesn't allow enabling them. This patch makes an ON value of
`LLVM_ENABLE_UNWIND_TABLES` actually enable unwind tables.

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

17 months ago[AMDGPU] Restore temporal divergence in test
Jay Foad [Mon, 6 Mar 2023 11:52:56 +0000 (11:52 +0000)]
[AMDGPU] Restore temporal divergence in test

The loop in this test was supposed to have temporal divergence but this
was broken by r367221. Fix it.

17 months ago[ARM] Fix Chain/Glue Bug in PerformVMOVhrCombine
Archibald Elliott [Thu, 2 Mar 2023 14:46:40 +0000 (14:46 +0000)]
[ARM] Fix Chain/Glue Bug in PerformVMOVhrCombine

In this optimisation, the Chain and Glue from the original CopyFromReg
was being lost by this optimisation, which resulted in miscompiles.

This fix just ensures that the input chains are correctly updated, and
that any any users are also updated with the new chain from the new
CopyFromReg.

Fixes #60510.

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

17 months ago[ARM] Pre-Commit Tests for PR60510
Archibald Elliott [Thu, 2 Mar 2023 14:39:41 +0000 (14:39 +0000)]
[ARM] Pre-Commit Tests for PR60510

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

17 months ago[ARM] Fix Crash in 't'/'w' handling without fp16/bf16
Archibald Elliott [Thu, 2 Mar 2023 13:44:23 +0000 (13:44 +0000)]
[ARM] Fix Crash in 't'/'w' handling without fp16/bf16

After https://reviews.llvm.org/rGff4027d152d0 and
https://reviews.llvm.org/rG7d15212b8c0c we saw crashes in SelectionDAG
when trying to use these constraints when you don't have the fp16 or
bf16 extensions.

However, it is still possible to move 16-bit floating point values into
the right place in S registers with a normal `vmov`, even if we don't
have fp16 instructions we can use within the inline assembly string.
This patch therefore fixes the crash.

I think the reason we weren't getting this crash before is because I
think the __fp16 and __bf16 types got an error diagnostic in the Clang
frontend when you didn't have the right architectural extensions to use
them. This restriction was recently relaxed.

The approach for bf16 needs a bit more explanation. Exactly how BF16 is
legalized was changed in rGb769eb02b526e3966847351e15d283514c2ec767 -
effectively, whether you have the right instructions to get a bf16 value
into/out of a S register with MoveTo/FromHPR depends on hasFullFP16, but
whether you use a HPR for a value of type MVT::bf16 depends on hasBF16.
This is why the tests are not changed by `+bf16` vs `-bf16`, but I've
left both sets of RUN lines in case this changes in the future.

Test Changes:
- Added more testing for testing inline asm (the core part)
- fp16-promote.ll and pr47454.ll show improvements where unnecessary
  fp16-fp32 up/down-casts are no longer emitted. This results in fewer
  libcalls where those casts would be done with a libcall.
- aes-erratum-fix.ll is fairly noisy, and I need to revisit this test so
  that the IR is more minimal than it is right now, because most of the
  changes in this commit do not relate to what AES is actually trying to
  verify.

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

17 months ago[mlir] Apply ClangTidy readability finding (NFC)
Adrian Kuegel [Mon, 6 Mar 2023 11:42:03 +0000 (12:42 +0100)]
[mlir] Apply ClangTidy readability finding (NFC)

17 months ago[AMDGPU] Use UniformityAnalysis in RewriteUndefsForPHI
pvanhout [Mon, 6 Mar 2023 08:26:35 +0000 (09:26 +0100)]
[AMDGPU] Use UniformityAnalysis in RewriteUndefsForPHI

Reviewed By: foad

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

17 months ago[Sanitizers] Error out for -static-libsan on darwin
usama hameed [Mon, 6 Mar 2023 11:08:26 +0000 (16:08 +0500)]
[Sanitizers] Error out for -static-libsan on darwin

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

17 months ago[GlobalOpt] Add SRA test with constant expr GEPs without inbounds.
Florian Hahn [Mon, 6 Mar 2023 11:03:27 +0000 (12:03 +0100)]
[GlobalOpt] Add SRA test with constant expr GEPs without inbounds.

Another test for D144476.

17 months agoExternalFunctions.cpp - fix "unknown pragma 'clang'" MSVC warning. NFCI.
Simon Pilgrim [Mon, 6 Mar 2023 11:01:45 +0000 (11:01 +0000)]
ExternalFunctions.cpp - fix "unknown pragma 'clang'" MSVC warning. NFCI.

17 months agoclang-tidy: Count template constructors in modernize-use-default-member-init
MarcoFalke [Sun, 5 Feb 2023 16:14:22 +0000 (17:14 +0100)]
clang-tidy: Count template constructors in modernize-use-default-member-init

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

17 months agoAMDGPU: Combine down fcopysign f64 magnitude
Matt Arsenault [Thu, 26 Jan 2023 17:20:12 +0000 (13:20 -0400)]
AMDGPU: Combine down fcopysign f64 magnitude

Copy through the low bits and only apply an f32
copysign to the high half. This is effectively
what we do for codegen anyway, but this provides
some combine benefits. The cases involving constants
show some small improvements.

https://reviews.llvm.org/D142682

17 months agoRevert "[Docs] Add my Office Hours"
Paulo Matos [Mon, 6 Mar 2023 09:51:14 +0000 (10:51 +0100)]
Revert "[Docs] Add my Office Hours"

This reverts commit b293de988059cac25c4ad84371be09107de7bbc4.

17 months ago[GlobalOpt] Add tests that only stores initializer, split test file.
Florian Hahn [Mon, 6 Mar 2023 09:50:34 +0000 (10:50 +0100)]
[GlobalOpt] Add tests that only stores initializer, split test file.

Add an additional tests that stores the initializer, but the global
doesn't have a zeroinitializer. Also separate out the tests for storing
initializers.

Add extra tests for D144476.

17 months ago[include-fixer] Add the missing optional header to the STL header list.
Haojian Wu [Mon, 6 Mar 2023 09:33:54 +0000 (10:33 +0100)]
[include-fixer] Add the missing optional header to the STL header list.

17 months ago[mlir][IR] Trigger notifyOperationModified for replacements
Matthias Springer [Mon, 6 Mar 2023 08:24:39 +0000 (09:24 +0100)]
[mlir][IR] Trigger notifyOperationModified for replacements

Each user of the original value is modified in-place. Therefore, the corresponding notification should be triggered.

Also fixes a bug where `RewriterBase::mergeBlocks` did not notify the GreedyPatternRewriteDriver when replacing uses of block arguments. This function does not trigger "operation replaced" notifications, so the GreedyPatternRewriteDriver was not made aware of such IR changes.

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

17 months ago[LowerTypeTests] Avoid creation of select constant expression
Nikita Popov [Fri, 3 Mar 2023 15:22:41 +0000 (16:22 +0100)]
[LowerTypeTests] Avoid creation of select constant expression

LowerTypeTests replaces weak declarations with an icmp+select
constant expressions. As this is not a relocatable expression,
it additionally promotes initializers using it to global ctors.

As part of https://discourse.llvm.org/t/rfc-remove-most-constant-expressions/63179,
I would like to remove the select constant expression, of which LTT
is now the last user. This is a bit tricky, because we now need to
replace a constant with an instruction, which might require
converting intermediate constant expression users to instructions as
well.

We do this using the convertUsersOfConstantsToInstructions() helper.
However, it needs to be slightly extended to also support expansion
of ConstantAggregates. These are important in this context, because
the promotion of initializers to global ctors will produce stores
of such aggregates.

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

17 months ago[SimpleLoopUnswtich] Support zext when injecting invariant conditions
Max Kazantsev [Mon, 6 Mar 2023 08:13:55 +0000 (15:13 +0700)]
[SimpleLoopUnswtich] Support zext when injecting invariant conditions

This patch handles the following case: turn
```
if (x <u Invariant1) {
  if (zext(x) <u Invariant2) {
    ...
  }
}
```
into
```
if (x <u Invariant1) {
  if (zext(Invariant1) <=u Invariant2) { // Unswitch here
    // No check needed
  } else {
    if (zext(x) <u Invariant2) {
      ...
    }
  }
}
```

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

17 months ago[clang] Fix aggregate initialization inside lambda constexpr
Mariya Podchishchaeva [Mon, 6 Mar 2023 08:25:57 +0000 (03:25 -0500)]
[clang] Fix aggregate initialization inside lambda constexpr

Constant evaluator only considered access to `this` pointer to be
possible if `this` poitners was captured. However `this` can also appear if
there was a default member initializer.

Fixes https://github.com/llvm/llvm-project/issues/60936

Reviewed By: shafik

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

17 months ago[flang] Use AssignPolymorphic when LHS is polymorphic
Valentin Clement [Mon, 6 Mar 2023 08:35:36 +0000 (09:35 +0100)]
[flang] Use AssignPolymorphic when LHS is polymorphic

Make use of the new runtime entry point for assignment to
LHS allocatable polymorphic.

Reviewed By: jeanPerier

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

17 months agoReland [AIX][BigArchive] Treat the archive is empty if the first child member offset...
Kai Luo [Mon, 6 Mar 2023 08:01:24 +0000 (16:01 +0800)]
Reland [AIX][BigArchive] Treat the archive is empty if the first child member offset is zero

If the archive contains free list and contains no member file, the buffer length doesn't equal to length of the header.

Reviewed By: Esme, DiggerLin, #powerpc

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

17 months ago[clang][ASTImporter] Add VaList declaration to lookup table.
Balázs Kéri [Mon, 6 Mar 2023 07:55:19 +0000 (08:55 +0100)]
[clang][ASTImporter] Add VaList declaration to lookup table.

The declaration of __builtin_va_list seems to be handled specially
by ASTContext and/or Sema. The normal AST traversal probably can
not find it, therefore it is not added to ASTImporterLookupTable.
If it is not added, errors can occur because a duplicated
VaList declaration is created at import. To fix the problem the
VaList declaration is added manually to ASTImporterLookupTable
at construction.
In special cases this declaration is inside a "invisible" 'std'
namespace that behaves the same way. This namespace must be added
to the table too.

Reviewed By: vabridgers, donat.nagy

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

17 months ago[libc][Obvious] Add back CMake logic which was mistakenly deleted earlier.
Siva Chandra [Mon, 6 Mar 2023 08:24:16 +0000 (00:24 -0800)]
[libc][Obvious] Add back CMake logic which was mistakenly deleted earlier.

17 months ago[mlir][IR][NFC] Move `walk` definitions to header file
Matthias Springer [Mon, 6 Mar 2023 08:11:42 +0000 (09:11 +0100)]
[mlir][IR][NFC] Move `walk` definitions to header file

This allows users to provide custom `Iterator` templates. A new iterator will be added in a subsequent change.

Also rename `makeRange` to `makeIterable` and add a test case for the reverse iterator.

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

17 months ago[NFC] Fix typo in comment
Max Kazantsev [Mon, 6 Mar 2023 08:11:56 +0000 (15:11 +0700)]
[NFC] Fix typo in comment

17 months ago[mlir][Interfaces] ReifyRankedShapedTypeOpInterface returns OpFoldResults
Matthias Springer [Fri, 3 Mar 2023 16:56:39 +0000 (17:56 +0100)]
[mlir][Interfaces] ReifyRankedShapedTypeOpInterface returns OpFoldResults

`reifyResultShapes` now returns `OpFoldResult`s instead of `Value`s. This is often more efficient because many transformations immediately attempt to extract a constant from the reified values.

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

17 months ago[libc] Simplify integration tests by eliminating the artificial sysroot.
Siva Chandra Reddy [Sat, 4 Mar 2023 05:35:45 +0000 (05:35 +0000)]
[libc] Simplify integration tests by eliminating the artificial sysroot.

The test binaries are built like any other executable but with two
additional linker options -static and -nostdlib.

Reviewed By: jhuber6

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

17 months ago[LLVM] Remove XFAIL from merge-equivalent-ranges.ll
Muhammad Omair Javaid [Mon, 6 Mar 2023 07:25:52 +0000 (11:25 +0400)]
[LLVM] Remove XFAIL from merge-equivalent-ranges.ll

This patch removes XFAIL decorator from merge-equivalent-ranges.ll
test.

Merge equilant ranges is passing on aarch64-windows-msvc buildbot
since: https://lab.llvm.org/buildbot/#/builders/120/builds/4291

17 months ago[APInt] Deprecate several functions
Kazu Hirata [Mon, 6 Mar 2023 06:48:28 +0000 (22:48 -0800)]
[APInt] Deprecate several functions

This patch deprecates:

- those functions that have been soft-deprecated
- countPopulation

Note that I've already migrated away from all known uses of these
functions.

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

17 months ago[NFC] Add an invalid test case for C++20 Modules
Chuanqi Xu [Mon, 6 Mar 2023 06:39:27 +0000 (14:39 +0800)]
[NFC] Add an invalid test case for C++20 Modules

Address https://github.com/llvm/llvm-project/issues/61150.

The test is intended to show the polluted operator&& will affect the ODR
checking and the ODR checking here is correct.

17 months ago[ValueMapper] Preserve poison types during value mapping
Carl Ritson [Mon, 6 Mar 2023 02:36:01 +0000 (11:36 +0900)]
[ValueMapper] Preserve poison types during value mapping

Poison needs to be treated directly during type remap otherwise
it will be considered an instance of undef.

Reviewed By: dexonsmith

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

17 months ago[llvm] [NFC] fix comments describing GenericSSAContext
Sameer Sahasrabuddhe [Mon, 6 Mar 2023 04:56:01 +0000 (10:26 +0530)]
[llvm] [NFC] fix comments describing GenericSSAContext

17 months ago[libc][Obvious] Add errno entrypoint for macOS ARM64.
Tue Ly [Mon, 6 Mar 2023 05:06:03 +0000 (00:06 -0500)]
[libc][Obvious] Add errno entrypoint for macOS ARM64.

17 months ago[CostModel][RISCV] Model code size cost for reduction
ShihPo Hung [Thu, 19 Jan 2023 02:02:27 +0000 (18:02 -0800)]
[CostModel][RISCV] Model code size cost for reduction

Since code-size cost doesn't scale linearly with LMUL,
this change is to separate it from throughput.

Reviewed By: reames

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

17 months ago[libc++][spaceship][NFC] Marked `operator<=>` for `move_iterator` and `counted_iterat...
Hristo Hristov [Mon, 6 Mar 2023 00:04:52 +0000 (01:04 +0100)]
[libc++][spaceship][NFC] Marked `operator<=>` for `move_iterator` and `counted_iterator` as implemented

Apprarently implemented as part of:

- `move_iterator` - https://reviews.llvm.org/D117656
- `counted_iterator` - https://reviews.llvm.org/D106205

Reviewed By: #libc, philnik

Spies: libcxx-commits, yaxunl

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

17 months agoAMDGPU: Force sign operand of f64 fcopysign to f32
Matt Arsenault [Thu, 26 Jan 2023 16:18:47 +0000 (12:18 -0400)]
AMDGPU: Force sign operand of f64 fcopysign to f32

The fcopysign DAG operation, unlike the IR one, allows
different types for the sign and magnitude. We can reduce
the bitwidth of the high operand since only the sign bit matters.

The default combine only introduces mixed fcopysign
operand types from fpext/fptrunc. We effectively do this
already during selection, but doing it earlier in the combiner
should expose new combine opportunities (e.g. the existing tests
now eliminate the load of the low half of the double). Unfortunately
this isn't enough to handle the case I'm interested in just yet.

17 months ago[CodeGen] guarantee variable templates are initialized in the reverse instantiation...
Yuanfang Chen [Sun, 5 Mar 2023 23:27:18 +0000 (15:27 -0800)]
[CodeGen] guarantee variable templates are initialized in the reverse instantiation order

Following up D127259.

Fixes https://github.com/llvm/llvm-project/issues/61028.

17 months agoAMDGPU: Try to push fneg as integer into select
Matt Arsenault [Mon, 23 Jan 2023 19:42:59 +0000 (15:42 -0400)]
AMDGPU: Try to push fneg as integer into select

I initially attempted to select the source modifier from xor of
a sign mask. This proved to be more difficult since
foldBinOpIntoSelect does not consider free fneg of integers
and undoes the combine.

17 months ago[libc++] Update supported system versions
Nikolas Klauser [Mon, 19 Dec 2022 20:54:05 +0000 (21:54 +0100)]
[libc++] Update supported system versions

Reviewed By: ldionne, #libc, emaste, daltenty

Spies: fsb4000, daltenty, alvinhochun, goncharov, phosek, MaskRay, dalias, q66, thesamesam, emaste, libcxx-commits, arphaman, mstorsjo, #libc_vendors

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

17 months agollvm-reduce: Use explicit output file in a test
Matt Arsenault [Sun, 5 Mar 2023 20:13:23 +0000 (16:13 -0400)]
llvm-reduce: Use explicit output file in a test

The default argument behavior test tries to make use
of the default reduced.ll, so other tests should not try to
write to the same file.

Maybe fixes issue #61132.

17 months ago[clang-tidy] altera-id-dependent-backward-branch: refactor test
Egor Suvorov [Sun, 5 Mar 2023 18:22:10 +0000 (18:22 +0000)]
[clang-tidy] altera-id-dependent-backward-branch: refactor test

This is a preparation for future fixes that need more tests.

* Put all "Inferred Assignments" testing at the end
* Group together ID-dependent variable/member testing
* Group together unused inferred assignments
* Use a literal instead of `get_local_size` which may have special meaning
* Create a new `struct` for each variable because analysis is done per field,
  not per field per instance.

Depends on D145303

Reviewed By: carlosgalvezp

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

17 months ago[sanitizer][NetBSD] Remove ioctl TIOCRCVFRAME and TIOCXMTFRAME
Fangrui Song [Sun, 5 Mar 2023 17:46:42 +0000 (17:46 +0000)]
[sanitizer][NetBSD] Remove ioctl TIOCRCVFRAME and TIOCXMTFRAME

The two macros were removed by
https://mail-index.netbsd.org/source-changes/2022/12/21/msg142441.html

Close #61151

17 months ago[clang-tidy] Extract string header from redundant-string-cstr checker
Mike Crowe [Sun, 5 Mar 2023 17:04:30 +0000 (17:04 +0000)]
[clang-tidy] Extract string header from redundant-string-cstr checker

In preparation for using the implementation of basic_string and
basic_string_view from redundant-string-cstr.cpp in other checks, let's
extract it to a header.

Using the existing <string.h> to provide size_t, using that to define
size_type and using it rather than the previous "size" type makes it
easier to provide the size() method later and makes the implementation
closer to the standard.

Reviewed By: carlosgalvezp

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

17 months ago[AArch64] Add missing bf16 SVE extract vector patterns
David Green [Sun, 5 Mar 2023 16:52:24 +0000 (16:52 +0000)]
[AArch64] Add missing bf16 SVE extract vector patterns

Similar to the inserts, these are the same fp16 inserts but were missing
patterns.

17 months ago[AArch64] Add missing bf16 SVE insert vector patterns.
David Green [Sun, 5 Mar 2023 16:24:43 +0000 (16:24 +0000)]
[AArch64] Add missing bf16 SVE insert vector patterns.

These should be identical to the fp16 SVE inserts but were missing from the
tests and tablegen patterns. They are always legal (not requiring +bf16),
although there are some other issues around bf16 legalization currently.

17 months agoclang-tidy altera-id-dependent-backward-branch: print notes after warning
Egor Suvorov [Sun, 5 Mar 2023 15:44:26 +0000 (15:44 +0000)]
clang-tidy altera-id-dependent-backward-branch: print notes after warning

In Clang notes are typically printed after a corresponding warning, not before.
For example, all notes issued before the first warning are ignored.

Running `clang-tidy --checks=-*,altera-id-dependent-backward-branch a.cpp` on the following code:
```
long get_local_id(int);
void error() {
  int ThreadID = get_local_id(0);
  for (int i = 0; i < ThreadID; i++) {
  }
  for (int i = 0; i < ThreadID; i++) {
  }
}
```
results in two warnings and a single note in between.

Reviewed By: carlosgalvezp

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

17 months ago[mlir][scf] Relax type requirement on for
Jacques Pienaar [Sun, 5 Mar 2023 15:37:58 +0000 (07:37 -0800)]
[mlir][scf] Relax type requirement on for

scf.for loop was restricted to only operate on Index type since
splitting out from affine.for. Relax requirement to allow for signless
integer types additionally. This allows specifying explicitly different
bitwidths for different loops as well as specialize from index to iN
while still using scf.for.

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

17 months ago[libc++][NFC] Add consteval to ranges::__get_wider_signed::__call
Nikolas Klauser [Sun, 5 Mar 2023 13:09:32 +0000 (14:09 +0100)]
[libc++][NFC] Add consteval to ranges::__get_wider_signed::__call

17 months ago[Support] Implement findModulesAndOffsets on Apple 64-bit platforms
Luís Marques [Sun, 5 Mar 2023 12:16:28 +0000 (12:16 +0000)]
[Support] Implement findModulesAndOffsets on Apple 64-bit platforms

To have line number information in stack traces (per stack frame) it's
necessary to implement findModulesAndOffsets.

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

17 months agoRevert "[clang][Interp] Support destructors"
Timm Bäder [Sun, 5 Mar 2023 12:18:13 +0000 (13:18 +0100)]
Revert "[clang][Interp] Support destructors"

This reverts commit 78e4237460bf58f3d6b75f275e0424f38e3b1d04.

This breaks the memory sanitizer builder:
https://lab.llvm.org/buildbot/#/builders/5/builds/31959

17 months ago[VPlan] VPWidenCallRecipe has side-effects if the call has.
Florian Hahn [Sun, 5 Mar 2023 11:08:54 +0000 (12:08 +0100)]
[VPlan] VPWidenCallRecipe has side-effects if the call has.

Handle VPWidenCallRecipe in VPRecipeBase::mayHaveSideEffects by
delegating to the underlying call.

17 months ago[clang][Interp] Support destructors
Timm Bäder [Thu, 5 Jan 2023 12:40:54 +0000 (13:40 +0100)]
[clang][Interp] Support destructors

Use the existing local variable cleanup infrastructure to implement
destruction.

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

17 months ago[clang][Interp][NFCI] Support more expression in initializers
Timm Bäder [Thu, 5 Jan 2023 12:38:57 +0000 (13:38 +0100)]
[clang][Interp][NFCI] Support more expression in initializers

17 months ago[X86] Precommit tests
Kazu Hirata [Sun, 5 Mar 2023 08:48:53 +0000 (00:48 -0800)]
[X86] Precommit tests

This patch precommits more tests for:

https://github.com/llvm/llvm-project/issues/60802

17 months ago[AMDGPU] More precise limit on SALU cycles in s_delay_alu instructions
Jay Foad [Sun, 5 Mar 2023 08:12:02 +0000 (08:12 +0000)]
[AMDGPU] More precise limit on SALU cycles in s_delay_alu instructions

This just tweaks the fix for D145232 to make the limit more precise, so
that we could actually emit a delay of 3 SALU cycles (the maximum) if we
had any SALU instructions that required it.

17 months ago[libc] Switch signal and termios to libc_errno.
Siva Chandra Reddy [Fri, 3 Mar 2023 21:24:09 +0000 (21:24 +0000)]
[libc] Switch signal and termios to libc_errno.

Reviewed By: michaelrj

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

17 months ago[lldb] Remove unused portion of GetFunctionMethodInfo signature (NFC)
Dave Lee [Sun, 5 Mar 2023 01:14:50 +0000 (17:14 -0800)]
[lldb] Remove unused portion of GetFunctionMethodInfo signature (NFC)

This applies to IsClassMethod as well.

17 months ago[libc][Obvious] Add the LIBC_INLINE tag to a function define in a.h file.
Siva Chandra Reddy [Sun, 5 Mar 2023 02:58:45 +0000 (02:58 +0000)]
[libc][Obvious] Add the LIBC_INLINE tag to a function define in a.h file.

17 months ago[libc][NFC] Remove allocator definition in the api-test.
Siva Chandra Reddy [Sun, 5 Mar 2023 00:23:48 +0000 (00:23 +0000)]
[libc][NFC] Remove allocator definition in the api-test.

The integration tests already have allocators so we will get all of them
from there.

17 months agoFix broken link on Clang documentation page
Tulio Leao [Sat, 4 Mar 2023 22:56:15 +0000 (00:56 +0200)]
Fix broken link on Clang documentation page

While browsing the latest [clang manual](https://clang.llvm.org/docs/ReleaseNotes.html), I came across this warning and clicked, but it leads to a broken page, apparently because it's missing the trailing `/`. Seems to be the only place where it's missing in the whole of LLVM monorepo.

{F26690053}
{F26690057}

Reviewed By: brenoguim, royjacobson

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

17 months ago[X86] Add non-BMI tests to bit_ceil.ll
Kazu Hirata [Sat, 4 Mar 2023 20:20:04 +0000 (12:20 -0800)]
[X86] Add non-BMI tests to bit_ceil.ll

17 months ago[OpenMP][CUDA] Get rid of redundant macro def
Shao-Ce SUN [Sat, 4 Mar 2023 17:55:55 +0000 (01:55 +0800)]
[OpenMP][CUDA] Get rid of redundant macro def

Resolve warning of `TARGET_NAME` macro redefinition.

Reviewed By: jhuber6

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

17 months agoRevert "[CMake] Bumps minimum version to 3.20.0."
Mark de Wever [Sat, 4 Mar 2023 17:28:13 +0000 (18:28 +0100)]
Revert "[CMake] Bumps minimum version to 3.20.0."

Some build bots have not been updated to the new minimal CMake version.
Reverting for now and ping the buildbot owners.

This reverts commit 44c6b905f8527635e49bb3ea97dea315f92d38ec.

17 months agoRe-land "[clang][Interp] Implement C++ Range-for loops"
Timm Bäder [Thu, 2 Mar 2023 10:05:45 +0000 (11:05 +0100)]
Re-land "[clang][Interp] Implement C++ Range-for loops"

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

17 months ago[libc++][format] Fixes formatting vector<bool>
Mark de Wever [Fri, 17 Feb 2023 17:55:48 +0000 (18:55 +0100)]
[libc++][format] Fixes formatting vector<bool>

Formatting a const qualified vector<bool> fails to work on libc++. This
is due to our non-conforming type for vector<bool>::const_reference. The
type is a __bit_const_reference<vector> instead of a bool. (This is
fixed in ABI v2.)

This fixes this formatter and enables the test written for it.

Reviewed By: #libc, ldionne

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

17 months ago[libc++][format] Addresses LWG3833.
Mark de Wever [Sun, 12 Feb 2023 18:46:13 +0000 (19:46 +0100)]
[libc++][format] Addresses LWG3833.

  LWG3833 Remove specialization template<size_t N> struct formatter<const charT[N], charT>

Depends on D143845

Reviewed By: #libc, ldionne

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

17 months ago[libc++] Addresses LWG3103.
Mark de Wever [Mon, 6 Feb 2023 20:43:35 +0000 (21:43 +0100)]
[libc++] Addresses LWG3103.

  LWG3103 Errors in taking subview of span should be ill-formed where possible

Note that the real work was already done before, including tests.

Reviewed By: #libc, ldionne

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

17 months ago[CMake] Bumps minimum version to 3.20.0.
Mark de Wever [Tue, 21 Feb 2023 19:09:21 +0000 (20:09 +0100)]
[CMake] Bumps minimum version to 3.20.0.

This partly undoes D137724.

This change has been discussed on discourse
https://discourse.llvm.org/t/rfc-upgrading-llvms-minimum-required-cmake-version/66193

Note this does not remove work-arounds for older CMake versions, that
will be done in followup patches.

Reviewed By: mehdi_amini, MaskRay, ChuanqiXu, to268, thieta, tschuett, phosek, #libunwind, #libc_vendors, #libc, #libc_abi, sivachandra, philnik, zibi

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

17 months ago[LoopInterchange] Remove unused RecurrenceDescriptor object. NFC
Craig Topper [Sat, 4 Mar 2023 06:15:32 +0000 (22:15 -0800)]
[LoopInterchange] Remove unused RecurrenceDescriptor object. NFC