Changes

Summary

  1. [VPlan] Exit earlier when trying to widen with scalar VFs. (details)
  2. [pseudo] Add missing dependency, fix shared library build. (details)
  3. [LoopVectorize] Fix assertion failure in fixReduction when tail-folding (details)
  4. [Clang] Added options for integrated backend. (details)
  5. [ARM] Fix vcvtb/t.f16 input liveness (details)
  6. [gn build] (manually) port some of cd2292ef8245 (details)
  7. [mlir][openmp] Add check for types of operands in omp.atomic.write (details)
  8. [MLIR][Linalg] Adjust documentation (NFC) (details)
  9. [clang-tidy] Extend SimplifyBooleanExpr demorgan support. (details)
  10. [clang-tidy] Update docs for SimplifyDeMorganRelaxed (details)
  11. Test C DR conformance (part three of many) (details)
  12. [x86] add test with volatile load; NFC (details)
  13. [lld-macho] Support  -non_global_symbols_strip_list, -non_global_symbols_no_strip_list, -x (details)
  14. [tests] precommit tests for D126040 (details)
  15. [MLIR][NFC] Fix the Conversion/MemRefToSPIRV/alloc.mlir test. (details)
  16. [pseudo-gen] Add -o flag, make --grammar required (details)
  17. [AST] Dont invalidate a ref-type var decl if it has no initializer. (details)
  18. Fix unused-variable warning, NFC. (details)
  19. [libc++] Use Python subprocess instead of libc++'s own utilities (details)
  20. [PS5] Default to -fno-rtti (details)
  21. [VP][fix] Don't discard masks in reductions (details)
  22. [libc++] Remove conditional include (details)
  23. [MLIR][Presburger] Add getDomainSet, getRangeSet to IntegerRelation (details)
  24. [PhaseOrdering] Add test for unprofitable loop load PRE backedge splitting (NFC) (details)
  25. [MLIR][Presburger] Add inverse to IntegerRelation (details)
  26. [llvm-rc] Avoid which(1) dependency in windres-prefix.test (details)
  27. [TableGen] Undeprecate 'field' when used with the CodeEmitterGen backend. (details)
  28. [riscv] Add coverage for fixed length vector loops using LMUL (details)
  29. [libc++][test] Verify std::ranges::rbegin, crbegin, rend, crend are CPOs (details)
  30. [mlir][scf] Retain existing attributes in scf.for transforms (details)
  31. [mlir][spirv] Fix capability check for 64-bit element types (details)
  32. [RISCV] Restructure comment and add clarifying assert to getFrameIndexReference [NFC] (details)
Commit c6e45ea0743b763e8e997f8a9a9236986bea6a5f by flo
[VPlan] Exit earlier when trying to widen with scalar VFs.

This simplifies the code a bit, suggested in D124718.

Reviewed By: Ayal

Differential Revision: https://reviews.llvm.org/D125029
The file was modifiedllvm/lib/Transforms/Vectorize/LoopVectorize.cpp
Commit f1df6515e3fe54f688739927c57cb6adec01c307 by hokein.wu
[pseudo] Add missing dependency, fix shared library build.
The file was modifiedclang-tools-extra/pseudo/benchmarks/CMakeLists.txt
The file was modifiedclang-tools-extra/pseudo/unittests/CMakeLists.txt
The file was modifiedclang-tools-extra/pseudo/fuzzer/CMakeLists.txt
The file was modifiedclang-tools-extra/pseudo/tool/CMakeLists.txt
Commit 87936c7b131ee141a1309d5535f149ac48ff694e by david.sherwood
[LoopVectorize] Fix assertion failure in fixReduction when tail-folding

When compiling the attached new test in scalable-reductions-tf.ll we
were hitting this assertion in fixReduction:

  Assertion `isa<PHINode>(U) && "Reduction exit must feed Phi's or select"

The loop contains a reduction and an intermediate store of the reduction
value. When vectorising with tail-folding the contains of 'U' in the
assertion above happened to be a scatter_store. It turns out that we
were still creating a widen recipe for the invariant store, despite
knowing that we can actually sink it. The simplest fix is to change
buildVPlanWithVPRecipes so that we look for invariant stores before
attempting to widen it.

Differential Revision: https://reviews.llvm.org/D126295
The file was modifiedllvm/lib/Transforms/Vectorize/LoopVectorize.cpp
The file was modifiedllvm/test/Transforms/LoopVectorize/AArch64/scalable-reductions.ll
The file was addedllvm/test/Transforms/LoopVectorize/AArch64/scalable-reductions-tf.ll
Commit 730dc4e9bce8189c037a32e520d18b141250d265 by anastasia.stulova
[Clang] Added options for integrated backend.

Following the new flow for external object code emission,
provide flags to switch between integrated and external
backend similar to the integrated assembler options.

SPIR-V target is the only user of this functionality at
this point.

This patch also updated SPIR-V documentation to clarify
that integrated object code emission for SPIR-V is an
experimental feature.

Differential Revision: https://reviews.llvm.org/D125679
The file was modifiedclang/test/Driver/clang_f_opts.c
The file was modifiedclang/lib/Driver/ToolChain.cpp
The file was modifiedclang/include/clang/Driver/Options.td
The file was modifiedclang/docs/UsersManual.rst
The file was modifiedclang/lib/Driver/ToolChains/SPIRV.h
The file was modifiedclang/test/Driver/spirv-toolchain.cl
The file was modifiedclang/include/clang/Driver/ToolChain.h
Commit 18cb3b35066e5f385fa08d373c60447a3aa88ce3 by david.green
[ARM] Fix vcvtb/t.f16 input liveness

The `vcvtb.f16.f32 Sd, Sn` (and vcvtt.f16.f32) instruction convert a f32
into a f16, writing either the top or bottom halves of the register.
That means that half of the input register Sd is used in the output.
This wasn't being modelled in the instructions, leading later analyses
to believe that the registers were dead where they were not, generating
invalid scheduling

Fix that be specifying the input Sda register for the instructions too,
allowing them to be set for cases like vector inserts. Most of the
changes are plumbing through the constraint string, cstr.

Differential Revision: https://reviews.llvm.org/D126118
The file was modifiedllvm/test/CodeGen/Thumb2/mve-fmath.ll
The file was modifiedllvm/test/CodeGen/Thumb2/mve-vcvt16.ll
The file was modifiedllvm/test/CodeGen/Thumb2/mve-vcvt.ll
The file was modifiedllvm/test/CodeGen/ARM/aes-erratum-fix.ll
The file was modifiedllvm/lib/Target/ARM/ARMInstrVFP.td
The file was modifiedllvm/lib/Target/ARM/ARMInstrFormats.td
The file was modifiedllvm/test/CodeGen/Thumb2/mve-div-expand.ll
The file was modifiedllvm/test/CodeGen/Thumb2/mve-masked-store.ll
Commit c85688a22ba71afcf8105ac1c79865e6a347ddac by thakis
[gn build] (manually) port some of cd2292ef8245
The file was addedllvm/utils/gn/secondary/clang-tools-extra/pseudo/lib/grammar/BUILD.gn
The file was addedllvm/utils/gn/secondary/clang-tools-extra/pseudo/cxx/BUILD.gn
The file was addedllvm/utils/gn/secondary/clang-tools-extra/pseudo/gen/BUILD.gn
The file was modifiedllvm/utils/gn/secondary/clang-tools-extra/pseudo/lib/BUILD.gn
Commit 512d06b04513dc8c859567e215a13ba8d312095d by Shraiysh.Vaishay
[mlir][openmp] Add check for types of operands in omp.atomic.write

This patch makes sure that the address dereferences to value in
omp.atomic.write operation.

Reviewed By: kiranchandramohan, peixin

Differential Revision: https://reviews.llvm.org/D126272
The file was modifiedmlir/lib/Dialect/OpenMP/IR/OpenMPDialect.cpp
The file was modifiedmlir/test/Dialect/OpenMP/invalid.mlir
Commit 1ad9b2662273d8c4bed9377fb3f0cba05c81b296 by l.chelini
[MLIR][Linalg] Adjust documentation (NFC)

Adjust docs for tensor.pad, tensor.collapse_shape and tensor.expand_shape.

Reviewed By: ftynse

Differential Revision: https://reviews.llvm.org/D126370
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/Vectorization.cpp
The file was modifiedmlir/test/lib/Dialect/Linalg/TestLinalgTransforms.cpp
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/ElementwiseOpFusion.cpp
The file was modifiedmlir/include/mlir/Dialect/Linalg/Transforms/Transforms.h
Commit f3c1d281767a5849b9f3e712e3c3406bd9410c81 by n.james93
[clang-tidy] Extend SimplifyBooleanExpr demorgan support.

Adds an option SimplifyDemorganRelaxed which, when enabled, will transform negated conjunctions or disjunctions when neither operand is a negation.
Default value is `false`.

Reviewed By: LegalizeAdulthood

Differential Revision: https://reviews.llvm.org/D126162
The file was modifiedclang-tools-extra/test/clang-tidy/checkers/readability-simplify-bool-expr-demorgan.cpp
The file was modifiedclang-tools-extra/clang-tidy/readability/SimplifyBooleanExprCheck.cpp
The file was modifiedclang-tools-extra/clang-tidy/readability/SimplifyBooleanExprCheck.h
The file was modifiedclang-tools-extra/docs/clang-tidy/checks/readability-simplify-boolean-expr.rst
Commit 09ef6da8dcd848258c9f876ba9298c7db0d589a9 by n.james93
[clang-tidy] Update docs for SimplifyDeMorganRelaxed

Forgot to add this to f3c1d281767
The file was modifiedclang-tools-extra/docs/clang-tidy/checks/readability-simplify-boolean-expr.rst
Commit f96aa834d7d77bb875d5bb727b89ab4af7940a0c by aaron
Test C DR conformance (part three of many)

This adds more of the tests for the first 100 DRs in C and updates
their status on the status page.
The file was addedclang/test/C/drs/dr094.c
The file was modifiedclang/test/C/drs/dr0xx.c
The file was modifiedclang/www/c_dr_status.html
Commit d5ebba2aa68347eca8f3b920a61f4810d89c0f68 by spatel
[x86] add test with volatile load; NFC

Test for D126353
The file was modifiedllvm/test/CodeGen/X86/extractelement-load.ll
Commit fae6bd7563ca54139d6f7f66683c12b88783501f by vyng
[lld-macho] Support  -non_global_symbols_strip_list, -non_global_symbols_no_strip_list, -x

PR/55600

Differential Revision: https://reviews.llvm.org/D126046
The file was modifiedlld/MachO/Config.h
The file was modifiedlld/MachO/SyntheticSections.cpp
The file was modifiedlld/MachO/Driver.cpp
The file was modifiedlld/MachO/Options.td
The file was addedlld/test/MachO/local-symbol-output.s
Commit 58b76492c1fea6b6c7ce2b3e7b9fb0d5ee00fe9d by zhongyunde
[tests] precommit tests for D126040

Reviewed By: spatel

Differential Revision: https://reviews.llvm.org/D126356
The file was modifiedllvm/test/Transforms/InstCombine/mul-masked-bits.ll
Commit b3c856d10ceeb0b6c8f2a44838bbad187cbfaa65 by ivan.kosarev
[MLIR][NFC] Fix the Conversion/MemRefToSPIRV/alloc.mlir test.

Caught with D125604.

Reviewed By: antiagainst

Differential Revision: https://reviews.llvm.org/D126292
The file was modifiedmlir/test/Conversion/MemRefToSPIRV/alloc.mlir
Commit 788463e72af847d11476793fdd5d57a104b18b3d by thakis
[pseudo-gen] Add -o flag, make --grammar required

Virtually all LLVM tools accept a `-o` flag, so add one. This will make it
possible to possibly add a --write-if-changed flag later. It also makes it
so that the file isn't partially written if the tool oesn't run successfully.

Marking --grammar as `Required` allows removing some manual
verification code for it.

Differential Revision: https://reviews.llvm.org/D126373
The file was modifiedclang-tools-extra/pseudo/include/CMakeLists.txt
The file was modifiedclang-tools-extra/pseudo/gen/Main.cpp
Commit c673d67bc76bfa31b78e3eee23899b9f262158ea by hokein.wu
[AST] Dont invalidate a ref-type var decl if it has no initializer.

This would allow more AST nodes being preserved for broken code, and
have a more consistent valid bit for ref-type var decl (currently, a
ref-type var decl with a broken initializer is valid).

Per https://reviews.llvm.org/D76831#1973053, the initializer of a variable
should play no part in its "invalid" bit.

Reviewed By: sammccall

Differential Revision: https://reviews.llvm.org/D122935
The file was modifiedclang/lib/Sema/SemaDecl.cpp
The file was modifiedclang/test/AST/ast-dump-invalid-initialized.cpp
Commit a17fc7fd865096f4be6b8b4a7e6e0834aae6c048 by hokein.wu
Fix unused-variable warning, NFC.
The file was modifiedclang/tools/libclang/CIndex.cpp
Commit d8afac7a2b736b367cc817242b0c4a13a3ff0051 by Louis Dionne
[libc++] Use Python subprocess instead of libc++'s own utilities

Once we move off entirely from the legacy testing framework, this will
allow removing a bunch of code.

Differential Revision: https://reviews.llvm.org/D126303
The file was modifiedlibcxx/utils/libcxx/sym_check/util.py
The file was modifiedlibcxx/utils/libcxx/sym_check/extract.py
Commit d8dda57ae7798a052e52ef5979980e815d2e4bc5 by paul.robinson
[PS5] Default to -fno-rtti
The file was modifiedclang/lib/Driver/ToolChain.cpp
The file was modifiedclang/test/Driver/rtti-options.cpp
Commit 6e12711081d76fea8dc2f4d9579cfdf379497bbf by moll
[VP][fix] Don't discard masks in reductions

When expanding VP reductions to non VP-code, the reduction pass was
ignoring the mask before. Fix this by keeping the mask and selecting
neutral elements where the mask is zero.

Reviewed By: frasercrmck

Differential Revision: https://reviews.llvm.org/D126362
The file was modifiedllvm/test/CodeGen/Generic/expand-vp.ll
The file was modifiedllvm/lib/CodeGen/ExpandVectorPredication.cpp
Commit 8383351d45179ecb544f859919dbc798ac9a91ea by Louis Dionne
[libc++] Remove conditional include
The file was modifiedlibcxx/src/barrier.cpp
The file was modifiedlibcxx/include/barrier
Commit 3c057ac2c28446ded80c3e91794c15d0c40a2d78 by groverkss
[MLIR][Presburger] Add getDomainSet, getRangeSet to IntegerRelation

This patch adds support for obtaining a set corresponding to the domain/range
of the relation.

Reviewed By: ftynse

Differential Revision: https://reviews.llvm.org/D126326
The file was modifiedmlir/unittests/Analysis/Presburger/CMakeLists.txt
The file was addedmlir/unittests/Analysis/Presburger/IntegerRelationTest.cpp
The file was modifiedmlir/include/mlir/Analysis/Presburger/IntegerRelation.h
The file was modifiedmlir/lib/Analysis/Presburger/IntegerRelation.cpp
Commit 6346a026af7984f3b20d0c0e0e767ef83fc93027 by npopov
[PhaseOrdering] Add test for unprofitable loop load PRE backedge splitting (NFC)
The file was addedllvm/test/Transforms/PhaseOrdering/X86/vector-reduction-known-first-value.ll
Commit fb857ded70e108afec4f4f7e024b0315bbe00de4 by groverkss
[MLIR][Presburger] Add inverse to IntegerRelation

This patch adds support for obtaining inverse of a relation.

Reviewed By: ftynse

Differential Revision: https://reviews.llvm.org/D126327
The file was modifiedmlir/include/mlir/Analysis/Presburger/IntegerRelation.h
The file was modifiedmlir/unittests/Analysis/Presburger/IntegerRelationTest.cpp
The file was modifiedmlir/lib/Analysis/Presburger/IntegerRelation.cpp
Commit e40c4dd66218393214ed7a817ebb82979adad01a by mgorny
[llvm-rc] Avoid which(1) dependency in windres-prefix.test

Rely on lit substitution to provide the path to llvm-windres instead
of redundantly calling which(1) with the subtituted absolute path.
This fixes test failure on the happy systems without which(1) installed.

Differential Revision: https://reviews.llvm.org/D126366
The file was modifiedllvm/test/tools/llvm-rc/windres-prefix.test
Commit 046f90173567535397c97b2d00406c93ee4bc890 by ivan.kosarev
[TableGen] Undeprecate 'field' when used with the CodeEmitterGen backend.

Differential Revision: https://reviews.llvm.org/D126290
The file was modifiedllvm/docs/TableGen/ProgRef.rst
Commit a4a438f05a5cd583e6a0680a1dafcb35aa2d1b53 by listmail
[riscv] Add coverage for fixed length vector loops using LMUL
The file was modifiedllvm/test/CodeGen/RISCV/rvv/sink-splat-operands.ll
Commit 5a2dbe49bedc15769319a2754a9c109bf3f5c678 by joeloser93
[libc++][test] Verify std::ranges::rbegin, crbegin, rend, crend are CPOs

Uncomment the tests to ensure `std::ranges::rbegin` and friends are indeed
customization points objects.

Differential Revision: https://reviews.llvm.org/D126325
The file was modifiedlibcxx/test/std/library/description/conventions/customization.point.object/cpo.compile.pass.cpp
Commit 413fbb045d714bbb1f1f3887104ccbc4b7b395c2 by antiagainst
[mlir][scf] Retain existing attributes in scf.for transforms

These attributes can carry useful information, e.g., pipelines
might use them to organize and chain patterns.

Reviewed By: hanchung

Differential Revision: https://reviews.llvm.org/D126320
The file was modifiedmlir/lib/Dialect/SCF/SCF.cpp
The file was modifiedmlir/test/Dialect/SCF/canonicalize.mlir
The file was modifiedmlir/lib/Dialect/SCF/Transforms/BufferizableOpInterfaceImpl.cpp
The file was modifiedmlir/test/Dialect/SCF/bufferize.mlir
Commit e0ea1fc6f8aa5c51061dced0f86c4fd25e3e9333 by antiagainst
[mlir][spirv] Fix capability check for 64-bit element types

Using 64-bit integer/float type in interface storage classes would
require Int64/Float64 capability, per the Vulkan spec:

```
shaderInt64 specifies whether 64-bit integers (signed and unsigned) are
supported in shader code. If this feature is not enabled, 64-bit integer
types must not be used in shader code. This also specifies whether
shader modules can declare the Int64 capability. Declaring and using
64-bit integers is enabled for all storage classes that SPIR-V allows
with the Int64 capability.
```

This is different from, say, 16-bit element types, where:

```
shaderInt16 specifies whether 16-bit integers (signed and unsigned) are
supported in shader code. If this feature is not enabled, 16-bit integer
types must not be used in shader code. This also specifies whether
shader modules can declare the Int16 capability. However, this only
enables a subset of the storage classes that SPIR-V allows for the Int16
SPIR-V capability: Declaring and using 16-bit integers in the Private,
Workgroup (for non-Block variables), and Function storage classes is
enabled, while declaring them in the interface storage classes (e.g.,
UniformConstant, Uniform, StorageBuffer, Input, Output, and
PushConstant) is not enabled.
```

Reviewed By: hanchung

Differential Revision: https://reviews.llvm.org/D126256
The file was modifiedmlir/lib/Dialect/SPIRV/Transforms/SPIRVConversion.cpp
The file was modifiedmlir/test/Dialect/SPIRV/Transforms/vce-deduction.mlir
The file was modifiedmlir/lib/Dialect/SPIRV/IR/SPIRVTypes.cpp
The file was modifiedmlir/test/Conversion/MemRefToSPIRV/alloc.mlir
The file was modifiedmlir/test/Conversion/FuncToSPIRV/types-to-spirv.mlir
Commit dd336b6891f1e4be1aae2b7e30c1ba7318564812 by listmail
[RISCV] Restructure comment and add clarifying assert to getFrameIndexReference [NFC]

Differential Revision: https://reviews.llvm.org/D126088
The file was modifiedllvm/lib/Target/RISCV/RISCVFrameLowering.cpp