Changes

Summary

  1. [modules] Fix tracking ObjCInterfaceType decl when there are multiple definitions. (details)
  2. BPF: emit BTF_KIND_DECL_TAG for typedef types (details)
  3. Modify "statistics dump" to dump JSON. (details)
  4. [gn build] Port d7b338537cf3 (details)
  5. Add test to check we can instcombine after reassociate. NFC. (details)
  6. Follow-up fixes for aee49255074fd4ef38d97e6e70cbfbf2f9fd0fa7 (details)
  7. [libcxx] [test] Add an XFAIL for the timespec test for MinGW targets (details)
  8. [libcxx] [test] Add a specific XFAIL for a MinGW env failure that is fixed in Clang 14 (details)
  9. [fir] Remove createConcatenate test temporarily (details)
  10. [AArch64][GlobalISel] Fold 64-bit cmps with 64-bit adds (details)
  11. [mlir][vector] Add patterns to convert multidimreduce to vector.contract (details)
  12. [mlir][linalg] Remove special case for contraction vectorization (details)
  13. Fix buildbots after https://reviews.llvm.org/D111686 (details)
  14. Fix escaping in RewriterGen.cpp. (details)
  15. [TargetLowering][RISCV] Prevent scalarization of fixed vector bswap. (details)
  16. Remove unused parallel-libs project (details)
  17. Make genAttributeVerifier escape the summary. (details)
  18. [MLIR] Fix FloorDivSIOpConverter that was failing for index type after the arithmetic op refactor (details)
  19. PR18733: Remove -Wweak-template-vtables (details)
  20. [libcxx] [test] Convert an XFAIL: LIBCXX-WINDOWS-FIXME into XFAIL: msvc with explanation (details)
  21. [modules] Update visibility for merged ObjCInterfaceDecl definitions. (details)
  22. [InstCombine] Precommit new and-xor-or.ll tests. NFC. (details)
  23. [LegalizeVectorOps][X86] Don't defer BITREVERSE expansion to LegalizeDAG. (details)
  24. [fir] Remove unused function in CharacterTest (details)
  25. [TargetLowering] Simplify the interface for expandCTPOP/expandCTLZ/expandCTTZ. (details)
  26. [docs] Remove Makefile.sphinx files (details)
  27. [RISCV] Remove Zvamo C intrinsics and builtins. (details)
  28. compiler-rt: Fix arch detection for ppc64le (details)
Commit d9eca3320a4d8db11ad65229ef6f564d134fc894 by vsapsai
[modules] Fix tracking ObjCInterfaceType decl when there are multiple definitions.

With the old approach we were updating `ObjCInterfaceType.Decl` to the
last encountered definition. But during loading modules
`ASTDeclReader::VisitObjCInterfaceDecl` keeps the *first* encountered
definition. So with multiple definitions imported there would be a
disagreement between expected definition in `ObjCInterfaceType.Decl` and
actual definition `ObjCInterfaceDecl::getDefinition` which can lead to
incorrect diagnostic.

Fix by not tracking definition in `ObjCInterfaceType` explicitly but by
getting it from redeclaration chain.

Partially reverted 919fc50034b44c48aae8b80283f253ec2ee17f45 keeping the
modified test case as the correct behavior is achieved in a different
way.

Differential Revision: https://reviews.llvm.org/D110452
The file was modifiedclang/lib/Sema/SemaLookup.cpp
The file was modifiedclang/lib/AST/DeclObjC.cpp
The file was modifiedclang/lib/AST/Type.cpp
The file was modifiedclang/include/clang/AST/Type.h
The file was modifiedclang/test/Modules/interface-diagnose-missing-import.m
The file was modifiedclang/test/Modules/decldef.mm
Commit 0472e83ffcc6c0506b0cd67844b97cb34eaa302e by yhs
BPF: emit BTF_KIND_DECL_TAG for typedef types

If a typedef type has __attribute__((btf_decl_tag("str"))) with
bpf target, emit BTF_KIND_DECL_TAG for that type in the BTF.

Differential Revision: https://reviews.llvm.org/D112259
The file was modifiedllvm/lib/Target/BPF/BTFDebug.cpp
The file was addedllvm/test/CodeGen/BPF/BTF/tag-typedef.ll
Commit d7b338537cf360568474d31c2be86110ac22dc32 by gclayton
Modify "statistics dump" to dump JSON.

This patch is a smaller version of a previous patch https://reviews.llvm.org/D110804.

This patch modifies the output of "statistics dump" to be able to get stats from the current target. It adds 3 new stats as well. The output of "statistics dump" is now emitted as JSON so that it can be used to track performance and statistics and the output could be used to populate a database that tracks performance. Sample output looks like:

(lldb) statistics dump
{
  "expressionEvaluation": {
    "failures": 0,
    "successes": 0
  },
  "firstStopTime": 0.34164492800000001,
  "frameVariable": {
    "failures": 0,
    "successes": 0
  },
  "launchOrAttachTime": 0.31969605400000001,
  "targetCreateTime": 0.0040863039999999998
}

The top level keys are:

"expressionEvaluation" which replaces the previous stats that were emitted as plain text. This dictionary contains the success and fail counts.
"frameVariable" which replaces the previous stats for "frame variable" that were emitted as plain text. This dictionary contains the success and fail counts.
"targetCreateTime" contains the number of seconds it took to create the target and load dependent libraries (if they were enabled) and also will contain symbol preloading times if that setting is enabled.
"launchOrAttachTime" is the time it takes from when the launch/attach is initiated to when the first private stop occurs.
"firstStopTime" is the time in seconds that it takes to stop at the first stop that is presented to the user via the LLDB interface. This value will only have meaning if you set a known breakpoint or stop location in your code that you want to measure as a performance test.

This diff is also meant as a place to discuess what we want out of the "statistics dump" command before adding more funcionality. It is also meant to clean up the previous code that was storting statistics in a vector of numbers within the lldb_private::Target class.

Differential Revision: https://reviews.llvm.org/D111686
The file was modifiedlldb/source/Commands/Options.td
The file was modifiedlldb/source/Target/Process.cpp
The file was modifiedlldb/test/API/commands/statistics/basic/TestStats.py
The file was modifiedlldb/source/Commands/CommandObjectStats.cpp
The file was addedlldb/include/lldb/Target/Statistics.h
The file was modifiedlldb/include/lldb/Target/Process.h
The file was modifiedlldb/source/Target/Target.cpp
The file was modifiedlldb/source/API/SBTarget.cpp
The file was modifiedlldb/include/lldb/Target/Target.h
The file was addedlldb/source/Target/Statistics.cpp
The file was modifiedlldb/source/Commands/CommandObjectExpression.cpp
The file was modifiedlldb/test/API/functionalities/stats_api/TestStatisticsAPI.py
The file was modifiedlldb/packages/Python/lldbsuite/test/lldbtest.py
The file was modifiedlldb/source/Target/CMakeLists.txt
The file was modifiedlldb/source/Commands/CommandObjectFrame.cpp
Commit 439fc09fed3262f40aba6110282b8c023dc4cd89 by llvmgnsyncbot
[gn build] Port d7b338537cf3
The file was modifiedllvm/utils/gn/secondary/lldb/source/Target/BUILD.gn
Commit 969b72fb662b9dc2124c6eb7797feb7e3bdd38d5 by Stanislav.Mekhanoshin
Add test to check we can instcombine after reassociate. NFC.

The pattern became optimized after b92412fb286b.

Differential Revision: https://reviews.llvm.org/D112258
The file was addedllvm/test/Transforms/PhaseOrdering/reassociate-instcombine.ll
Commit 64f002c6d36d674a924c6116ec0b2d731cc3981c by dblaikie
Follow-up fixes for aee49255074fd4ef38d97e6e70cbfbf2f9fd0fa7
The file was modifiedlldb/test/Shell/SymbolFile/PDB/udt-layout.test
The file was modifiedlldb/test/Shell/SymbolFile/PDB/typedefs.test
Commit 3087a8488948f575a81158494fd0609198ef5e9e by martin
[libcxx] [test] Add an XFAIL for the timespec test for MinGW targets

MinGW headers/libs lack timespec_get.

Differential Revision: https://reviews.llvm.org/D112213
The file was modifiedlibcxx/test/std/language.support/support.runtime/ctime.timespec.compile.pass.cpp
Commit 6836629f889194202da28b745e82d0931d000a2b by martin
[libcxx] [test] Add a specific XFAIL for a MinGW env failure that is fixed in Clang 14

This issue only occurs when linked statically in MinGW configurations,
and has been fixed for Clang 14 by https://reviews.llvm.org/D109651.

Differential Revision: https://reviews.llvm.org/D112214
The file was modifiedlibcxx/test/std/thread/thread.threads/thread.thread.class/thread.thread.constr/F.pass.cpp
Commit 2ba572a82a35051cdee91f6bb00d3db322ae13a3 by clementval
[fir] Remove createConcatenate test temporarily

This test is makeing one buildbot fail for unknown reason. Remove
it until we can investifate further.
The file was modifiedflang/unittests/Optimizer/Builder/CharacterTest.cpp
Commit 5dc339d9825f1dbe788cfb69c88210a59bbf8e3a by Jessica Paquette
[AArch64][GlobalISel] Fold 64-bit cmps with 64-bit adds

G_ICMP is selected to an arithmetic overflow op (ADDS/SUBS/etc) with a dead
destination + a CSINC instruction.

We have a fold which allows us to combine 32-bit adds with G_ICMP.

The problem with G_ICMP is that we model it as always having a 32-bit
destination even though it can be a 64-bit operation. So, we were missing some
opportunities for 64-bit folds.

This patch teaches the fold to recognize 64-bit G_ICMPs + refactors some of
the code surrounding CSINC accordingly.

(Later down the line, I think we should probably change the way we handle G_ICMP
in general.)

Differential Revision: https://reviews.llvm.org/D111088
The file was modifiedllvm/test/CodeGen/AArch64/GlobalISel/select-cmp.mir
The file was modifiedllvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
Commit 1d8cc45b0e4e316dbc4d4724964f1115fdb3f909 by thomasraoux
[mlir][vector] Add patterns to convert multidimreduce to vector.contract

add several patterns that will simplify contraction vectorization in the
future. With those canonicalizationns we will be able to remove the special
case for contration during vectorization and rely on those transformations to
avoid materizalizing broadcast ops.

Differential Revision: https://reviews.llvm.org/D112121
The file was addedmlir/test/Dialect/Vector/vector-reduce-to-contract.mlir
The file was modifiedmlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
The file was modifiedmlir/include/mlir/Dialect/Vector/VectorOps.h
The file was modifiedmlir/lib/Dialect/Vector/VectorTransforms.cpp
Commit 93d0ade17c2da810ee6e0d747c3a594b8bfd0c12 by thomasraoux
[mlir][linalg] Remove special case for contraction vectorization

Handle contraction op like all the other generic op reductions. This
simpifies the code. We now rely on contractionOp canonicalization to
keep the same code quality.

Differential Revision: https://reviews.llvm.org/D112171
The file was modifiedmlir/test/Dialect/Linalg/vectorization.mlir
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/Vectorization.cpp
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/LinalgStrategyPasses.cpp
The file was modifiedmlir/test/lib/Dialect/Linalg/TestLinalgTransforms.cpp
The file was modifiedmlir/test/Dialect/Linalg/transform-patterns-matmul-to-vector.mlir
Commit 910838f07da7872d2b7cca5b07d64ea9915b6767 by gclayton
Fix buildbots after https://reviews.llvm.org/D111686
The file was modifiedlldb/packages/Python/lldbsuite/test/lldbtest.py
The file was modifiedlldb/test/API/commands/statistics/basic/TestStats.py
Commit 5c0369eceb2c64b80bf2db57ca6cac7db3e3957b by jeffniu22
Fix escaping in RewriterGen.cpp.

When we escape strings for C++, make sure we use C++ escape
sequences. (In particular, \x22 instead of \22)

Reviewed By: Mogball

Differential Revision: https://reviews.llvm.org/D112269
The file was modifiedmlir/tools/mlir-tblgen/RewriterGen.cpp
Commit 458ed5fcc3626d84fe13db1048dc6742a60f7624 by craig.topper
[TargetLowering][RISCV] Prevent scalarization of fixed vector bswap.

It's better to do the ands, shifts, ors in the vector domain than
to scalarize it and do those operations on each element.

Reviewed By: RKSimon

Differential Revision: https://reviews.llvm.org/D112248
The file was modifiedllvm/test/CodeGen/RISCV/rvv/fixed-vectors-bswap.ll
The file was modifiedllvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
Commit db0486c46fe187475e4b01a401e14b2def593733 by dblaikie
Remove unused parallel-libs project

Differential Revision: https://reviews.llvm.org/D112265
The file was modifiedREADME.md
The file was removedparallel-libs/acxxel/acxxel.h
The file was removedparallel-libs/acxxel/examples/opencl_example.cpp
The file was removedparallel-libs/acxxel/acxxel.cpp
The file was removedparallel-libs/acxxel/LICENSE.TXT
The file was removedparallel-libs/acxxel/opencl_acxxel.cpp
The file was removedparallel-libs/acxxel/Doxyfile.in
The file was removedparallel-libs/.clang-tidy
The file was removedparallel-libs/acxxel/tests/status_test.cpp
The file was removedparallel-libs/acxxel/tests/acxxel_test.cpp
The file was removedparallel-libs/acxxel/CMakeLists.txt
The file was removedparallel-libs/acxxel/tests/CMakeLists.txt
The file was removedparallel-libs/README.rst
The file was removedparallel-libs/.clang-format
The file was removedparallel-libs/acxxel/examples/CMakeLists.txt
The file was removedparallel-libs/CMakeLists.txt
The file was removedparallel-libs/acxxel/span.h
The file was removedparallel-libs/acxxel/.clang-tidy
The file was removedparallel-libs/acxxel/cuda_acxxel.cpp
The file was removedparallel-libs/acxxel/status.h
The file was removedparallel-libs/acxxel/tests/span_test.cpp
The file was modifiedllvm/CMakeLists.txt
The file was removedparallel-libs/acxxel/examples/simple_example.cu
The file was removedparallel-libs/acxxel/tests/opencl_test.cpp
The file was modifiedllvm/utils/docker/scripts/llvm_checksum/project_tree.py
The file was removedparallel-libs/acxxel/tests/multi_device_test.cpp
The file was removedparallel-libs/acxxel/customdoxygen.css
The file was removedparallel-libs/acxxel/.clang-format
The file was modifiedllvm/projects/CMakeLists.txt
The file was modifiedllvm/docs/CMake.rst
The file was removedparallel-libs/acxxel/config.h.in
Commit 95935e8285ad0e2872b83190669c9f70f2fd2112 by jeffniu22
Make genAttributeVerifier escape the summary.

The summary can contain references to e.g. attribute defaults, which
can contain special characters. So these strings need to be C++
escaped.

Reviewed By: Mogball

Differential Revision: https://reviews.llvm.org/D112249
The file was modifiedmlir/tools/mlir-tblgen/OpDefinitionsGen.cpp
Commit 516884f58b46a60d0aa499e19d792c39f2478aa4 by jeffniu22
[MLIR] Fix FloorDivSIOpConverter that was failing for index type after the arithmetic op refactor

ConstantOp should be used instead of ConstantIntOp to be able to support index type.

Reviewed By: Mogball

Differential Revision: https://reviews.llvm.org/D112191
The file was modifiedmlir/lib/Dialect/Arithmetic/Transforms/ExpandOps.cpp
The file was modifiedmlir/test/Dialect/Arithmetic/expand-ops.mlir
Commit 8c136805242014b6ad9ff1afcac9d7f4a18bec3f by dblaikie
PR18733: Remove -Wweak-template-vtables

It isn't really pulling its weight and I think splitting it out from
-Wweak-vtables was the wrong call: I think it was just a bug in the
original warning, which was trying to not diagnose template
instantiations, implicit or explicit.
The file was modifiedclang/lib/Sema/SemaDeclCXX.cpp
The file was modifiedclang/test/SemaCXX/warn-weak-vtables.cpp
The file was modifiedclang/include/clang/Basic/DiagnosticSemaKinds.td
Commit f5ee1acc62d5a5052fc2ca65cf2f2927a3c6e9c2 by martin
[libcxx] [test] Convert an XFAIL: LIBCXX-WINDOWS-FIXME into XFAIL: msvc with explanation

This test doesn't fail in mingw mode (which uses the same Itanium
name mangling and ABI as other platforms).

Differential Revision: https://reviews.llvm.org/D112210
The file was modifiedlibcxx/test/libcxx/language.support/support.rtti/type.info/type_info.comparison.merged.sh.cpp
Commit 048d2c76efcddf4265987914e30d3d4f49395496 by vsapsai
[modules] Update visibility for merged ObjCInterfaceDecl definitions.

We keep using the first encountered definition and need to take into
account visibility from subsequent definitions. For example, if the
first definition is hidden and the second is visible, we need to make
the first one visible too.

rdar://82263843

Differential Revision: https://reviews.llvm.org/D110453
The file was modifiedclang/lib/Serialization/ASTReaderDecl.cpp
The file was addedclang/test/Modules/merge-objc-interface-visibility.m
Commit c0d6e1b9e0b1c5426e77ef31f076850b87dee08b by Stanislav.Mekhanoshin
[InstCombine] Precommit new and-xor-or.ll tests. NFC.
The file was modifiedllvm/test/Transforms/InstCombine/and-xor-or.ll
Commit ff37b1105d6eb7b9a4e4515c2ced95e9837567aa by craig.topper
[LegalizeVectorOps][X86] Don't defer BITREVERSE expansion to LegalizeDAG.

By expanding early it allows the shifts to be custom lowered in
LegalizeVectorOps. Then a DAG combine is able to run on them before
LegalizeDAG handles the BUILD_VECTORS for the masks used.

v16Xi8 shift lowering on X86 requires a mask to be applied to a v8i16
shift. The BITREVERSE expansion applied an AND mask before SHL ops and
after SRL ops. This was done to share the same mask constant for both shifts.
It looks like this patch allows DAG combine to remove the AND mask added
after v16i8 SHL by X86 lowering. This maintains the mask sharing that
BITREVERSE was trying to achieve. Prior to this patch it looks like
we kept the mask after the SHL instead which required an extra constant
pool or a PANDN to invert it.

This is dependent on D112248 because RISCV will end up scalarizing the BSWAP
portion of the BITREVERSE expansion if we don't disable BSWAP scalarization in
LegalizeVectorOps first.

Reviewed By: RKSimon

Differential Revision: https://reviews.llvm.org/D112254
The file was modifiedllvm/test/CodeGen/X86/vector-bitreverse.ll
The file was modifiedllvm/test/CodeGen/X86/combine-bitreverse.ll
The file was modifiedllvm/test/CodeGen/X86/bitreverse.ll
The file was modifiedllvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
Commit 0bf230d4220660af8b2667506f8905df2f716bdf by clementval
[fir] Remove unused function in CharacterTest
The file was modifiedflang/unittests/Optimizer/Builder/CharacterTest.cpp
Commit 996123e5e8d9b2894c88e02e98ce09abdf33bb7e by craig.topper
[TargetLowering] Simplify the interface for expandCTPOP/expandCTLZ/expandCTTZ.

There is no need to return a bool and have an SDValue output
parameter. Just return the SDValue and let the caller check if it
is null.

I have another patch to add more callers of these so I thought
I'd clean up the interface first.

Reviewed By: RKSimon

Differential Revision: https://reviews.llvm.org/D112267
The file was modifiedllvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
The file was modifiedllvm/include/llvm/CodeGen/TargetLowering.h
The file was modifiedllvm/lib/CodeGen/SelectionDAG/LegalizeVectorOps.cpp
The file was modifiedllvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
Commit c16655f138b1c2b203f6cdac179baa5accf2a737 by tstellar
[docs] Remove Makefile.sphinx files

Does anyone still use these?  I want to make some changes to the sphinx
html generation and I don't want to have to implement the changes in
two places.

Reviewed By: sylvestre.ledru, #libc, ldionne

Differential Revision: https://reviews.llvm.org/D112030
The file was removedclang/docs/Makefile.sphinx
The file was removedlibcxx/docs/Makefile.sphinx
The file was removedllvm/docs/Makefile.sphinx
Commit 6c6abb1ded8d91760e8a3b500f959fee5b767406 by craig.topper
[RISCV] Remove Zvamo C intrinsics and builtins.

Zvamo is not part of the 1.0 V spec. Remove the intrinsics
for now. This helps reduce clang binary size and lit test time.

Reviewed By: HsiangKai

Differential Revision: https://reviews.llvm.org/D111692
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vamoand.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vamoswap.c
The file was modifiedclang/utils/TableGen/RISCVVEmitter.cpp
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics/vamoswap.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics/vamoxor.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics/vamoor.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vamomax.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vamoxor.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vamoadd.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vamomin.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics/vamoadd.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics/vamomin.c
The file was modifiedclang/include/clang/Basic/riscv_vector.td
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics-overloaded/vamoor.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics/vamoand.c
The file was removedclang/test/CodeGen/RISCV/rvv-intrinsics/vamomax.c
Commit 05c21f54a454ebfa44be7825707e6061dc32afab by tstellar
compiler-rt: Fix arch detection for ppc64le

Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D110377
The file was modifiedcompiler-rt/cmake/base-config-ix.cmake