Changes

Summary

  1. [RISCV] Add isel patterns to match vmacc/vmadd/vnmsub/vnmsac from add/sub and mul. (details)
  2. [Clang][Codegen] rename no_profile fn attr no_profile_instrument_function (details)
  3. [SystemZ]  Fix some typos in comments. (details)
  4. [llvm-profdata] Allow omission of -o for --text output (details)
  5. [InstCombine] Extract bitcast -> gep transform (details)
  6. [InstCombine] Don't try converting opaque pointer bitcast to GEP (details)
  7. [SLP]Improve vectorization of PHI instructions. (details)
  8. [LoopUnroll] Don't modify TripCount/TripMultiple in computeUnrollCount() (NFCI) (details)
  9. Revert "[InstCombine] Extract bitcast -> gep transform" (details)
  10. [libcxx][ranges] Add `indirectly_movable` and `indirectly_movable_storable`. (details)
  11. [llvm-reduce] Don't delete arguments of intrinsics (details)
  12. [SYCL][NFC] Ensure SYCL kernel for unique-stable-name is unqualified. (details)
  13. [RISCV] Remove extra character from a comment. NFC (details)
  14. [mlir][vector] Support distributing transfer op with permutation map (details)
  15. Add polynomial approximation for trigonometric sine and cosine functions (details)
  16. [InstCombine] Add test for bitcast of unsized pointer (NFC) (details)
  17. Reapply [InstCombine] Extract bitcast -> gep transform (details)
  18. Create install targets for scan-build-py. (details)
  19. Reapply [InstCombine] Don't try converting opaque pointer bitcast to GEP (details)
  20. [libc++] NFC: Fix outdated comment about secrets.env (details)
  21. Revert "[SYCL][NFC] Ensure SYCL kernel for unique-stable-name is unqualified." (details)
  22. [SLP][NFC]Rename functions in the tests, NFC. (details)
  23. [NFC][SimplifyCFG] Fix tests to use FileCheck instead of grep (details)
  24. [NFC][SimplifyCFG] Add basic test for debuginfo preservation of `ret` tail merging (details)
Commit 9080659ac730735c6233153fa2f666015a47b07e by craig.topper
[RISCV] Add isel patterns to match vmacc/vmadd/vnmsub/vnmsac from add/sub and mul.

Reviewed By: frasercrmck

Differential Revision: https://reviews.llvm.org/D104163
The file was addedllvm/test/CodeGen/RISCV/rvv/vnmsub-sdnode.ll
The file was modifiedllvm/test/CodeGen/RISCV/rvv/vremu-sdnode-rv64.ll
The file was addedllvm/test/CodeGen/RISCV/rvv/vmadd-sdnode.ll
The file was modifiedllvm/test/CodeGen/RISCV/rvv/fixed-vectors-int.ll
The file was modifiedllvm/test/CodeGen/RISCV/rvv/vremu-sdnode-rv32.ll
The file was modifiedllvm/lib/Target/RISCV/RISCVInstrInfoVSDPatterns.td
The file was modifiedllvm/lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td
The file was modifiedllvm/test/CodeGen/RISCV/rvv/vrem-sdnode-rv64.ll
The file was modifiedllvm/lib/Target/RISCV/RISCVInstrInfo.cpp
The file was modifiedllvm/lib/Target/RISCV/RISCVInstrInfoVPseudos.td
The file was modifiedllvm/test/CodeGen/RISCV/rvv/vrem-sdnode-rv32.ll
The file was modifiedllvm/test/CodeGen/RISCV/rvv/vmulh-sdnode-rv32.ll
Commit a63d4f6cbab133b0f1ce9afb562546fcc5bb2680 by ndesaulniers
[Clang][Codegen] rename no_profile fn attr no_profile_instrument_function

GCC has had this function attribute since GCC 7.1 for this purpose. I
added "no_profile" last week in D104475; rename this to
"no_profile_instrument_function" to improve compatibility with GCC.

Link: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80223#c11

Reviewed By: MaskRay, aaron.ballman

Differential Revision: https://reviews.llvm.org/D104658
The file was modifiedclang/test/CodeGen/no_profile.c
The file was removedclang/test/Sema/no_profile-attribute.c
The file was modifiedclang/include/clang/Basic/Attr.td
The file was modifiedclang/include/clang/Basic/AttrDocs.td
The file was addedclang/test/Sema/no_profile_instrument_function-attribute.c
Commit b2cd98d5fe7ab71415f2a87c741ebf62a7e3ba54 by paulsson
[SystemZ]  Fix some typos in comments.
The file was modifiedllvm/lib/Target/SystemZ/SystemZISelLowering.cpp
Commit ea23c38d0605514f68e33d319a6bdd858381257a by i
[llvm-profdata] Allow omission of -o for --text output

This makes it more convenient to get a text format profile.

Add an error for printing non-text format output to a terminal for instrumentation profile.
(It cannot be portably tested. For sample profile, raw_fd_ostream is hidden deeply so it's inconvenient to add a diagnostic.)

Reviewed By: davidxl

Differential Revision: https://reviews.llvm.org/D104600
The file was modifiedllvm/test/tools/llvm-profdata/text-dump.test
The file was modifiedllvm/tools/llvm-profdata/llvm-profdata.cpp
Commit d9f5d7b959de36085944d4a99a73f3053f953796 by nikita.ppv
[InstCombine] Extract bitcast -> gep transform

Move this into a separate function, to make sure that early
returns do not accidentally skip other transforms. There is
already one isSized() check that could run into this issue,
thus this change is not strictly NFC.
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineCasts.cpp
Commit 5780611d7e044ef56c4214df2c236ef5e15545ab by nikita.ppv
[InstCombine] Don't try converting opaque pointer bitcast to GEP

Bitcasts having opaque pointer source or result type cannot be
converted into a zero-index GEP, GEP source and result types
always have the same opaque-ness.
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineCasts.cpp
The file was addedllvm/test/Transforms/InstCombine/opaque-ptr.ll
Commit 908b7536615ee8694d949b60716833893c7f7049 by a.bataev
[SLP]Improve vectorization of PHI instructions.

Perform better analysis when trying to vectorize PHIs.
1. Do not try to vectorize vector PHIs.
2. Do deeper analysis for more profitable nodes for the vectorization.

Before we just tried to vectorize the PHIs of the same type. Patch
improves this and tries to vectorize PHIs with incoming values which
come from the same basic block, have the same and/or alternative
opcodes.

It allows to save the compile time and provides better vectorization
results in general.

Part of D57059.

Differential Revision: https://reviews.llvm.org/D103638
The file was modifiedllvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
The file was modifiedllvm/test/Transforms/SLPVectorizer/slp-max-phi-size.ll
Commit 862313cf59eef22023cc8c5d93bd368e661791d1 by nikita.ppv
[LoopUnroll] Don't modify TripCount/TripMultiple in computeUnrollCount() (NFCI)

As these are no longer passed to UnrollLoop(), there is no need to
modify them in computeUnrollCount(). Make them non-reference parameters.

Differential Revision: https://reviews.llvm.org/D104590
The file was modifiedllvm/include/llvm/Transforms/Utils/UnrollLoop.h
The file was modifiedllvm/lib/Transforms/Scalar/LoopUnrollPass.cpp
Commit 6922ab73a5a5b0d6a65f0b8796e5fae4345dbbd9 by nikita.ppv
Revert "[InstCombine] Extract bitcast -> gep transform"

This reverts commit d9f5d7b959de36085944d4a99a73f3053f953796.
This reverts commit 5780611d7e044ef56c4214df2c236ef5e15545ab.

This causes a failure in Coroutine tests.
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineCasts.cpp
The file was removedllvm/test/Transforms/InstCombine/opaque-ptr.ll
Commit 075f2370c7fa5495649d09be8b1a9802b17a7f2b by zoecarver
[libcxx][ranges] Add `indirectly_movable` and `indirectly_movable_storable`.

Differential Revision: https://reviews.llvm.org/D102639
The file was modifiedlibcxx/test/std/containers/associative/multimap/iterator_concept_conformance.compile.pass.cpp
The file was addedlibcxx/test/std/iterators/iterator.requirements/alg.req.ind.move/indirectly_movable.subsumption.compile.pass.cpp
The file was modifiedlibcxx/test/std/strings/basic.string/string.iterators/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/utilities/optional/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/sequences/list/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/unord/unord.multiset/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/views/span.iterators/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/sequences/vector/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/include/__iterator/concepts.h
The file was modifiedlibcxx/test/std/containers/sequences/deque/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/input.output/filesystems/class.directory_iterator/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/associative/set/iterator_concept_conformance.compile.pass.cpp
The file was addedlibcxx/test/std/iterators/iterator.requirements/alg.req.ind.move/indirectly_movable.compile.pass.cpp
The file was addedlibcxx/test/std/iterators/iterator.requirements/alg.req.ind.move/indirectly_movable_storable.subsumption.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/unord/unord.map/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/predef.iterators/insert.iterators/insert.iterator/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/associative/map/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/predef.iterators/insert.iterators/front.insert.iterator/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/stream.iterators/ostream.iterator/iterator_concept_conformance.compile.pass.cpp
The file was addedlibcxx/test/std/iterators/iterator.requirements/alg.req.ind.move/indirectly_movable_storable.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/predef.iterators/insert.iterators/back.insert.iterator/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/re/re.iter/re.regiter/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/sequences/vector.bool/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/sequences/array/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/utilities/memory/unique.ptr/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/predef.iterators/reverse.iterators/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/stream.iterators/istreambuf.iterator/iterator_concept_conformance.compile.pass.cpp
The file was addedlibcxx/test/std/iterators/iterator.requirements/alg.req.ind.move/{ind.move.subsumption.compile.pass.cpp}
The file was modifiedlibcxx/test/std/iterators/predef.iterators/move.iterators/move.iterator/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/stream.iterators/istream.iterator/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/iterators/stream.iterators/ostreambuf.iterator/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/sequences/forwardlist/forwardlist.iter/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/strings/string.view/string.view.iterators/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/unord/unord.multimap/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/containers/unord/unord.set/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/re/re.iter/re.tokiter/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/include/iterator
The file was modifiedlibcxx/test/std/containers/associative/multiset/iterator_concept_conformance.compile.pass.cpp
The file was modifiedlibcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/iterator_concept_conformance.compile.pass.cpp
Commit a24035883356de2bf201835e72a15f6a22e5032d by aeubanks
[llvm-reduce] Don't delete arguments of intrinsics

The argument reduction pass shouldn't remove arguments of
intrinsics, because the resulting module is ill-formed, and so
inherently uninteresting.

Reviewed By: aeubanks

Differential Revision: https://reviews.llvm.org/D103129
The file was modifiedllvm/tools/llvm-reduce/deltas/ReduceArguments.cpp
The file was addedllvm/test/tools/llvm-reduce/remove-args-dbg-intrinsics.ll
Commit 5013131875402539a249dca47c58cca7c359baf8 by erich.keane
[SYCL][NFC] Ensure SYCL kernel for unique-stable-name is unqualified.

Discovered in our downstream, this function that is used to get the type
of the kernel parameter type needs to be unqualified, otherwise when our
downstream uses this function in a slightly different way, the kernel
types no longer match.
The file was modifiedclang/lib/Sema/SemaSYCL.cpp
Commit c2e01ee4a5e97b686c49cfc2193e660f3e6dda9c by craig.topper
[RISCV] Remove extra character from a comment. NFC
The file was modifiedllvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp
Commit 1244bca53fb2ff2e6061ae43b830a645bf93cc6d by thomasraoux
[mlir][vector] Support distributing transfer op with permutation map

Differential Revision: https://reviews.llvm.org/D104263
The file was modifiedmlir/lib/Dialect/Vector/VectorTransforms.cpp
The file was modifiedmlir/test/Dialect/Vector/vector-distribution.mlir
Commit 7e2d672a672c0559f6e5c417c5ee2514402cf18e by ataei
Add polynomial approximation for trigonometric sine and cosine functions

The approximation relays on range reduced version y \in [0, pi/2]. An input x will have
the property that sin(x) = sin(y), -sin(y), cos(y), -cos(y) depends on which quadrable x
is in, where sin(y) and cos(y) are approximated with 5th degree polynomial (of x^2).
As a result a single pattern can be used to compute approximation for both sine and cosine.

Reviewed By: ezhulenev

Differential Revision: https://reviews.llvm.org/D104582
The file was modifiedmlir/lib/Dialect/Math/Transforms/PolynomialApproximation.cpp
The file was modifiedmlir/test/mlir-cpu-runner/math_polynomial_approx.mlir
Commit 403792f91e822e580dd5dc65ad80d0977d4fd9e3 by nikita.ppv
[InstCombine] Add test for bitcast of unsized pointer (NFC)

The bitcast should get folded into the select, but currently isn't
due to an incorrect early bailout.
The file was modifiedllvm/test/Transforms/InstCombine/bitcast.ll
Commit e2c2124a4b5bad9cf2a1e23a6aef1b2ad753f504 by nikita.ppv
Reapply [InstCombine] Extract bitcast -> gep transform

Relative to the original patch, an InstCombine test has been
added to show a previously missed pattern, and the Coroutine
test that resulted in the revert has been regenerated.

-----

Move this into a separate function, to make sure that early
returns do not accidentally skip other transforms. This previously
happened for the isSized() check, which skipped folds like
distributing a bitcast over a select.
The file was modifiedllvm/test/Transforms/InstCombine/bitcast.ll
The file was modifiedllvm/test/Transforms/Coroutines/coro-retcon-once-value.ll
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineCasts.cpp
Commit d9cf8291e7ef26317c13ed9a4e9bd88855166d5d by mvanotti
Create install targets for scan-build-py.

A new revision identical to https://reviews.llvm.org/D101139
The parent revision of aforementioned revision seems to cause pre-merge checks to fail opaquely. Seeing if creating a new revision will work.

Reviewed By: phosek

Differential Revision: https://reviews.llvm.org/D104138
The file was removedclang/tools/scan-build-py/libear/__init__.py
The file was addedclang/tools/scan-build-py/lib/libear/__init__.py
The file was removedclang/tools/scan-build-py/libscanbuild/clang.py
The file was addedclang/tools/scan-build-py/lib/libscanbuild/__init__.py
The file was modifiedclang/tools/scan-build-py/bin/analyze-build
The file was addedclang/tools/scan-build-py/lib/libscanbuild/intercept.py
The file was modifiedclang/tools/scan-build-py/tests/functional/cases/test_from_cmd.py
The file was removedclang/tools/scan-build-py/libear/config.h.in
The file was addedclang/tools/scan-build-py/libexec/analyze-c++
The file was removedclang/tools/scan-build-py/libscanbuild/resources/scanview.css
The file was addedclang/tools/scan-build-py/lib/libscanbuild/resources/scanview.css
The file was modifiedclang/tools/scan-build-py/bin/intercept-build
The file was removedclang/tools/scan-build-py/libscanbuild/resources/selectable.js
The file was modifiedclang/tools/CMakeLists.txt
The file was removedclang/tools/scan-build-py/bin/analyze-c++
The file was addedclang/tools/scan-build-py/libexec/analyze-cc
The file was removedclang/tools/scan-build-py/libscanbuild/__init__.py
The file was modifiedclang/tools/scan-build-py/tests/functional/cases/test_exec_anatomy.py
The file was removedclang/tools/scan-build-py/libscanbuild/compilation.py
The file was removedclang/tools/scan-build-py/libear/ear.c
The file was removedclang/tools/scan-build-py/libscanbuild/shell.py
The file was addedclang/tools/scan-build-py/lib/libscanbuild/clang.py
The file was removedclang/tools/scan-build-py/bin/intercept-c++
The file was addedclang/tools/scan-build-py/lib/libscanbuild/report.py
The file was addedclang/tools/scan-build-py/libexec/intercept-c++
The file was modifiedclang/tools/scan-build-py/bin/scan-build
The file was removedclang/tools/scan-build-py/bin/intercept-cc
The file was removedclang/tools/scan-build-py/libscanbuild/intercept.py
The file was addedclang/tools/scan-build-py/lib/libscanbuild/arguments.py
The file was addedclang/tools/scan-build-py/lib/libscanbuild/shell.py
The file was addedclang/tools/scan-build-py/lib/libscanbuild/compilation.py
The file was removedclang/tools/scan-build-py/libscanbuild/report.py
The file was modifiedclang/tools/scan-build-py/tests/functional/cases/test_from_cdb.py
The file was addedclang/tools/scan-build-py/lib/libscanbuild/analyze.py
The file was modifiedclang/tools/scan-build-py/tests/unit/test_analyze.py
The file was removedclang/tools/scan-build-py/libscanbuild/arguments.py
The file was modifiedclang/tools/scan-build-py/tests/__init__.py
The file was addedclang/tools/scan-build-py/lib/libear/ear.c
The file was addedclang/tools/scan-build-py/lib/libscanbuild/resources/sorttable.js
The file was removedclang/tools/scan-build-py/bin/analyze-cc
The file was modifiedclang/tools/scan-build-py/tests/functional/cases/__init__.py
The file was removedclang/tools/scan-build-py/libscanbuild/analyze.py
The file was modifiedclang/cmake/caches/Fuchsia-stage2.cmake
The file was addedclang/tools/scan-build-py/lib/libscanbuild/resources/selectable.js
The file was addedclang/tools/scan-build-py/CMakeLists.txt
The file was addedclang/tools/scan-build-py/lib/libear/config.h.in
The file was addedclang/tools/scan-build-py/libexec/intercept-cc
Commit 39796e1ad02a45b09ac3ef9e3dc1906f28804a91 by nikita.ppv
Reapply [InstCombine] Don't try converting opaque pointer bitcast to GEP

Reapplied without changes -- this was reverted together with an
underlying patch.

-----

Bitcasts having opaque pointer source or result type cannot be
converted into a zero-index GEP, GEP source and result types
always have the same opaque-ness.
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineCasts.cpp
The file was addedllvm/test/Transforms/InstCombine/opaque-ptr.ll
Commit 9b371f5da4e5df8d392390aec049528a6a08c3b1 by Louis Dionne
[libc++] NFC: Fix outdated comment about secrets.env

That file (secrets.env) has now been removed, so the comment was
referencing something that didn't exist anymore.
The file was modifiedlibcxx/utils/ci/Dockerfile
Commit b3634d3e88b7f26534a5057bff182b7dced584fc by erich.keane
Revert "[SYCL][NFC] Ensure SYCL kernel for unique-stable-name is unqualified."

This reverts commit 5013131875402539a249dca47c58cca7c359baf8.

This patch didn't end up being the solution to the problem.  It "fixed"
our issue but the actual correct solution is something else.  Reverting
as this ends up being unnecessary/extra noise.
The file was modifiedclang/lib/Sema/SemaSYCL.cpp
Commit c5bbc737e8c6a78867c8e0d0481e25824563bc3d by a.bataev
[SLP][NFC]Rename functions in the tests, NFC.
The file was modifiedllvm/test/Transforms/SLPVectorizer/X86/operandorder.ll
Commit 3e98b88797e52914ca67aa173aad97595fa61c73 by lebedev.ri
[NFC][SimplifyCFG] Fix tests to use FileCheck instead of grep
The file was modifiedllvm/test/Transforms/SimplifyCFG/hoist-common-code.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/branch-cond-prop.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/branch-cond-merge.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/2009-05-12-externweak.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/PhiEliminate.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/EqualPHIEdgeBlockMerge.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/duplicate-phis.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/UncondBranchToReturn.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/2008-05-16-PHIBlockMerge.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/BrUnwind.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/branch-fold-test.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/PhiNoEliminate.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/2008-12-16-DCECond.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/return-merge.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/iterative-simplify.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/PhiBlockMerge2.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/dbginfo.ll
The file was modifiedllvm/test/Transforms/SimplifyCFG/branch-phi-thread.ll
Commit 4cf74469a0f58c01a7fcf140a028b2a68f71df58 by lebedev.ri
[NFC][SimplifyCFG] Add basic test for debuginfo preservation of `ret` tail merging
The file was modifiedllvm/test/Transforms/SimplifyCFG/return-merge.ll