SuccessChanges

Summary

  1. ARCMigrate: Use hash_combine in the DenseMapInfo for EditEntry (details)
  2. [AArch64][GlobalISel] Check if G_SELECT has been optimized when folding binops (details)
  3. Pin -loop-reduce to legacy PM (details)
  4. [DFSan] Add pthread and other functions to ABI list. (details)
  5. [libc++] ADL-proof __libcpp_is_nothrow_constructible. (details)
  6. [libc++] Add _VSTD:: qualifications to ADL-proof <algorithm>. (details)
  7. [ScalarizeMaskedMemIntrin] Add new PM support (details)
  8. [AArch64][GlobalISel] Swap select operands when inverting condition code (details)
Commit b85c6e5bcd1a9de941c318f9a5dc742818752a56 by Duncan P. N. Exon Smith
ARCMigrate: Use hash_combine in the DenseMapInfo for EditEntry

Simplify the DenseMapInfo for `EditEntry` by migrating from
`FoldingSetNodeID` to `llvm::hash_combine`. Besides the cleanup, this
reduces the diff for a future patch which changes the type of one of the
fields.

There should be no real functionality change here, although I imagine
the hash value will churn since its a different hashing infrastructure.

Differential Revision: https://reviews.llvm.org/D92630
The file was modifiedclang/lib/ARCMigrate/ObjCMT.cpp
Commit 21308c2b4c9dda8d44d2792f1359fc6b54984b87 by Jessica Paquette
[AArch64][GlobalISel] Check if G_SELECT has been optimized when folding binops

`TryFoldBinOpIntoSelect` didn't have a check for `Optimized`, meaning you could
end up folding twice. (e.g. a select with a G_ADD on the true side, and a G_SUB
on the false side)

Add in the missing `if` and a test.
The file was modifiedllvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
The file was modifiedllvm/test/CodeGen/AArch64/GlobalISel/select-select.mir
Commit 3900f3f18c610092bb05292fcce76af2e9ae6c53 by aeubanks
Pin -loop-reduce to legacy PM

LSR currently only runs in the codegen pass manager.
There are a couple issues with LSR and the NPM.
1) Lots of tests assume that LCSSA isn't run before LSR. This breaks a
bunch of tests' expected output. This is fixable with some time put in.
2) LSR doesn't preserve LCSSA. See
llvm/test/Analysis/MemorySSA/update-remove-deadblocks.ll. LSR's use of
SCEVExpander is the only use of SCEVExpander where the PreserveLCSSA option is
off. Turning it on causes some code sinking out of loops to fail due to
SCEVExpander's inability to handle the newly created trivial PHI nodes in the
broken critical edge (I was looking at
llvm/test/Transforms/LoopStrengthReduce/X86/2011-11-29-postincphi.ll).
I also tried simply just calling formLCSSA() at the end of LSR, but the extra
PHI nodes cause regressions in codegen tests.

We'll delay figuring these issues out until later.

This causes the number of check-llvm failures with -enable-new-pm true
by default to go from 60 to 29.

Reviewed By: asbirlea

Differential Revision: https://reviews.llvm.org/D92796
The file was modifiedllvm/tools/opt/opt.cpp
Commit 483fb333605fc3a392ba140d33e8d9187cf02b70 by mascasa
[DFSan] Add pthread and other functions to ABI list.

The non-pthread functions are all clear discard functions.

Some of the pthread ones could clear shadow, but aren't worth writing
custom wrappers for.  I can't think of any reasonable scenario where we
would pass tainted memory to these pthread functions.

Reviewed By: stephan.yichao.zhao

Differential Revision: https://reviews.llvm.org/D92877
The file was modifiedcompiler-rt/lib/dfsan/done_abilist.txt
Commit 35c3b539438be2d587cbe8f2b9604a68bbe7792b by arthur.j.odwyer
[libc++] ADL-proof __libcpp_is_nothrow_constructible.

The GCC C++20 buildbot hit this ADL call; Clang doesn't,
presumably because it uses a compiler builtin instead of
this codepath in <type_traits>.
https://buildkite.com/llvm-project/libcxx-ci/builds/674
The file was modifiedlibcxx/include/type_traits
Commit 1968804ac726e7674d5de22bc2204b45857da344 by arthur.j.odwyer
[libc++] Add _VSTD:: qualifications to ADL-proof <algorithm>.

Relevant blog post: https://quuxplusone.github.io/blog/2019/09/26/uglification-doesnt-stop-adl/

Differential Revision: https://reviews.llvm.org/D92776
The file was addedlibcxx/test/std/algorithms/robust_against_adl.pass.cpp
The file was modifiedlibcxx/include/locale
The file was modifiedlibcxx/include/algorithm
The file was modifiedlibcxx/include/__string
Commit 29356e3279b24fec6c6cc731969b8599818e4426 by anna
[ScalarizeMaskedMemIntrin] Add new PM support

This patch adds new PM support for the pass and the pass can be now used
during middle-end transforms. The old pass is remamed to
ScalarizeMaskedMemIntrinLegacyPass.

Reviewed-By: skatkov, aeubanks
Differential Revision: https://reviews.llvm.org/D92743
The file was modifiedllvm/tools/llc/llc.cpp
The file was modifiedllvm/test/CodeGen/X86/masked_gather_scatter.ll
The file was modifiedllvm/tools/opt/opt.cpp
The file was modifiedllvm/include/llvm/Transforms/Scalar.h
The file was addedllvm/include/llvm/Transforms/Scalar/ScalarizeMaskedMemIntrin.h
The file was modifiedllvm/lib/Transforms/Scalar/ScalarizeMaskedMemIntrin.cpp
The file was modifiedllvm/lib/Transforms/Scalar/Scalar.cpp
The file was modifiedllvm/lib/Passes/PassRegistry.def
The file was modifiedllvm/lib/CodeGen/TargetPassConfig.cpp
The file was modifiedllvm/include/llvm/InitializePasses.h
The file was modifiedllvm/lib/Passes/PassBuilder.cpp
The file was modifiedllvm/include/llvm/LinkAllPasses.h
Commit 40d1fb22293ba6409e802489ff106bbc95918565 by Jessica Paquette
[AArch64][GlobalISel] Swap select operands when inverting condition code

This was not obvious when reading the imported tablegen patterns in
AArch64GenDAGISel.

Update select-select.mir.
The file was modifiedllvm/test/CodeGen/AArch64/GlobalISel/select-select.mir
The file was modifiedllvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp