Changes

Summary

  1. [mlir][linalg][bufferize] Eliminate InitTensorOps of InsertSliceOp sources (details)
  2. [mlir][linalg][bufferize] Avoid creating copies that are never read (details)
  3. [mlir][linalg][bufferize] Fix bug in getInplaceableOpResult (details)
  4. [mlir][linalg][bufferize] Fix bufferizesToMemoryWrite for TiledLoopOp (details)
  5. [SLP]Unify vectorization of PHI and store nodes with improved tiny tree vectorization. (details)
  6. [SystemZ][z/OS] Additional test coverage for validating dialect instructions for SystemZ (details)
  7. [DAGCombiner] fold bit-hack form of usubsat (details)
  8. [SystemZ][z/OS] Initial implementation for lowerCall on z/OS (details)
  9. [runtimes] Properly handle the sysroot/triple/gcc-toolchain (details)
  10. Do not downcast uint64_t to unsigned in UniqueID hash computation (details)
  11. [InstCombine] add tests for DeMorgan with reassociation; NFC (details)
  12. [InstCombine] generalize reassociated Demorgan folds (details)
  13. [libomptarget][DeviceRTL] Generalise and simplify cmakelists (details)
  14. [mlir][Linalg] Improve conv vectorization for the stride==1 case. (details)
  15. [ORC-RT] Remove stray printf debugging output. (details)
  16. [lld-macho] Simplify lc-linker-option.ll and re-enable it on Windows (details)
  17. [libc++] Use addressof in vector. (details)
  18. [Clang] Support typedef with btf_decl_tag attributes (details)
  19. [DebugInfo] Support typedef with btf_decl_tag attributes (details)
  20. [clang] Use StringRef::contains (NFC) (details)
  21. Reapply [ORC-RT] Configure the ORC runtime for more architectures and platforms (details)
  22. [clang] Don't clear AST if we have consumers running after the main action (details)
  23. Update the C++ and C status pages now that Clang 13 has been released (details)
  24. Update the title and encoding for the C++ status page (details)
  25. [IPT] Restructure cache to allow lazy update following invalidation [NFC] (details)
  26. [RISCV] Add a test showing incorrect VSETVLI insertion (details)
  27. Reland [clang] Pass -clear-ast-before-backend in Clang::ConstructJob() (details)
  28. [VectorCombine] fold shuffle-of-binops with common operand (details)
  29. [fir] Add Character helper (details)
Commit c5501a7a5c582168d1b12335c092bce53b32022d by springerm
[mlir][linalg][bufferize] Eliminate InitTensorOps of InsertSliceOp sources

An InitTensorOp is replaced with an ExtractSliceOp on the InsertSliceOp's destination. This optimization is applied after analysis and only to InsertSliceOps that were decided to bufferize inplace. Another analysis on the new ExtractSliceOp is needed after the rewrite.

Differential Revision: https://reviews.llvm.org/D111955
The file was modifiedmlir/test/Dialect/Linalg/comprehensive-module-bufferize-analysis.mlir
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp
The file was modifiedmlir/test/Dialect/Linalg/comprehensive-module-bufferize.mlir
Commit 7a7e93f1225c21b842171d3463bf2158c681dabf by springerm
[mlir][linalg][bufferize] Avoid creating copies that are never read

Differential Revision: https://reviews.llvm.org/D111956
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp
The file was modifiedmlir/test/Dialect/Linalg/comprehensive-module-bufferize.mlir
Commit 94213bc7decb1d4c131fb6feb5101e859640478f by springerm
[mlir][linalg][bufferize] Fix bug in getInplaceableOpResult

Differential Revision: https://reviews.llvm.org/D112123
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp
Commit 5f8228d310627889716b51e1acd5840ec653d899 by springerm
[mlir][linalg][bufferize] Fix bufferizesToMemoryWrite for TiledLoopOp

This is the same fix as for scf.for.

Differential Revision: https://reviews.llvm.org/D112218
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/ComprehensiveBufferize.cpp
Commit 3ea7877c8b62ba100e7b34dbf4afa0171d5b4705 by a.bataev
[SLP]Unify vectorization of PHI and store nodes with improved tiny tree vectorization.

Vectorization of PHIs and stores very similar, it might be beneficial to
try to revectorize stores (like PHIs) if the total number of stores with
the same/alternate opcode is less than the vector size but number of
stores with the same type is larger than the vector size.

Differential Revision: https://reviews.llvm.org/D109831
The file was modifiedllvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
The file was modifiedllvm/test/Transforms/SLPVectorizer/X86/tiny-tree.ll
Commit fa111d30855ee4d74a4b87672ea50d03a74ad85f by anirudh_prasad
[SystemZ][z/OS] Additional test coverage for validating dialect instructions for SystemZ

- There are certain instructions most notably those with extended mnemonics that restricted to only the gnu/att variant
- There are also certain instruction aliases/mnemonic aliases that are restricted only to the HLASM variant (see https://reviews.llvm.org/D97581, https://reviews.llvm.org/D94250 and https://reviews.llvm.org/D92185 for reference)
- This patch adds a few tests to check for the behaviour introduced in the above patches. The testing coverage could not be added in at the same time, due to parallel work being done introducing the HLASM syntax

Reviewed By: uweigand, abhina.sreeskantharajan

Differential Revision: https://reviews.llvm.org/D112172
The file was addedllvm/test/MC/SystemZ/insn-bad-zos.s
The file was addedllvm/test/MC/SystemZ/insn-bad-zos-z196.s
The file was addedllvm/test/MC/SystemZ/insn-bad-zos-z13.s
The file was addedllvm/test/MC/SystemZ/insn-good-zos-pcrel.s
The file was addedllvm/test/MC/SystemZ/insn-bad-zos-z15.s
The file was addedllvm/test/MC/SystemZ/insn-bad-zos-z14.s
Commit d2198771e9ccbae27a487cdca67720eee71cea2a by spatel
[DAGCombiner] fold bit-hack form of usubsat

(i8 X ^ 128) & (i8 X s>> 7) --> usubsat X, 128

I haven't found a generalization of this identity:
https://alive2.llvm.org/ce/z/_sriEQ

Note: I was actually looking at the first form of the pattern in that link,
but that's part of a long chain of potential missed transforms in codegen
and IR....that I hope ends here!

The predicates for when this is profitable are a bit tricky. This version of
the patch excludes multi-use but includes custom lowering (as opposed to
legal only).

On x86 for example, we have custom lowering for some vector types, and that
uses umax and sub. So to enable that fold, we need add use checks to avoid
regressions. Even with legal-only lowering, we could see code with extra
reg move instructions for extra uses, so that constraint would have to be
eased very carefully to avoid penalties.

Differential Revision: https://reviews.llvm.org/D112085
The file was modifiedllvm/test/CodeGen/AMDGPU/usubsat.ll
The file was modifiedllvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
The file was modifiedllvm/test/CodeGen/X86/psubus.ll
Commit aa3519f178fc6ea563f950a4077b34d8dc6c4470 by anirudh_prasad
[SystemZ][z/OS] Initial implementation for lowerCall on z/OS

- This patch provides the initial implementation for lowering a call on z/OS according to the XPLINK64 calling convention
- A series of changes have been made to SystemZCallingConv.td to account for these additional XPLINK64 changes including adding a new helper function to shadow the stack along with allocation of a register wherever appropriate
- For the cases of copying a f64 to a gr64 and a f128 / 128-bit vector type to a gr64, a `CCBitConvertToType` has been added and has been bitcasted appropriately in the lowering phase
- Support for the ADA register (R5) will be provided in a later patch.

Reviewed By: uweigand

Differential Revision: https://reviews.llvm.org/D111662
The file was modifiedllvm/lib/Target/SystemZ/SystemZRegisterInfo.h
The file was modifiedllvm/lib/Target/SystemZ/SystemZISelLowering.cpp
The file was modifiedllvm/lib/Target/TargetMachine.cpp
The file was addedllvm/test/CodeGen/SystemZ/call-zos-01.ll
The file was addedllvm/test/CodeGen/SystemZ/call-zos-vec.ll
The file was addedllvm/test/CodeGen/SystemZ/call-zos-vararg.ll
The file was modifiedllvm/lib/Target/SystemZ/SystemZCallingConv.h
The file was modifiedllvm/lib/Target/SystemZ/SystemZCallingConv.cpp
The file was modifiedllvm/lib/Target/SystemZ/SystemZCallingConv.td
Commit 72117f2ffeb6a096a808c34ec7ebee122c2d2e21 by Louis Dionne
[runtimes] Properly handle the sysroot/triple/gcc-toolchain

In 395271a, I simplified how we handled the target triple for the
runtimes. However, in doing so, we stopped considering the default
in CMAKE_CXX_COMPILER_TARGET, so we'd use the LLVM_DEFAULT_TARGET_TRIPLE
(which is the host triple) even if CMAKE_CXX_COMPILER_TARGET was specified.
This commit fixes that problem and also refactors the code so that it's
easy to see what the default value is.

The fact that nobody seems to have been broken by this makes me think
that perhaps nobody is using CMAKE_CXX_COMPILER_TARGET to specify the
triple -- but it should still work.

Differential Revision: https://reviews.llvm.org/D111672
The file was modifiedlibcxx/CMakeLists.txt
The file was modifiedlibunwind/CMakeLists.txt
The file was modifiedlibcxxabi/CMakeLists.txt
Commit 88303693ce97cf842f0714068c2cae44cd6515e1 by kbobyrev
Do not downcast uint64_t to unsigned in UniqueID hash computation

Context: https://reviews.llvm.org/D110925#inline-1070046
The file was modifiedllvm/include/llvm/Support/FileSystem/UniqueID.h
Commit 6b560a8e235b4f610cce6a2db8188f42ce65c5fb by spatel
[InstCombine] add tests for DeMorgan with reassociation; NFC

These are direct mutations of the tests added for D112108 -
we should handle the sibling folds for 'or'.
The file was modifiedllvm/test/Transforms/InstCombine/and-xor-or.ll
Commit 3888de9507c78d3d77a4f565f30a3bf1b2fce690 by spatel
[InstCombine] generalize reassociated Demorgan folds

This updates the recent D112108 / b92412fb286be26d
to handle the flipped logic ('or') sibling:
https://alive2.llvm.org/ce/z/Y2L6Ch
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineAndOrXor.cpp
The file was modifiedllvm/test/Transforms/InstCombine/and-xor-or.ll
Commit a602c2b51dccc756c12e7585c34710aeaef54e0b by jonathanchesterfield
[libomptarget][DeviceRTL] Generalise and simplify cmakelists

Step towards building the DeviceRTL for amdgpu.

Mostly replaces cuda-specific toolchain finding logic with the
generic logic currently found in the amdgpu deviceRTL cmake. Also
deletes dead code and changes the default to build on systems
without cuda installed, as the library doesn't use cuda and the
amdgpu-only systems generally won't have cuda installed.

Reviewed By: Meinersbur

Differential Revision: https://reviews.llvm.org/D111983
The file was modifiedopenmp/libomptarget/DeviceRTL/CMakeLists.txt
Commit 203accf0bdde1d276646c79dfa605ee3426f1ca8 by nicolas.vasilache
[mlir][Linalg] Improve conv vectorization for the stride==1 case.

In the stride == 1 case, conv1d reads contiguous data along the input dimension. This can be advantageaously used to bulk memory transfers and compute while avoiding unrolling. Experimentally, this can yield speedups of up to 50%.

Reviewed By: antiagainst

Differential Revision: https://reviews.llvm.org/D112139
The file was modifiedmlir/lib/Dialect/Linalg/Transforms/Vectorization.cpp
The file was modifiedmlir/test/Dialect/Linalg/vectorize-convolution.mlir
Commit 5c72323141e4c2935492a9aca728d549c7e544ab by Lang Hames
[ORC-RT] Remove stray printf debugging output.

These were accidentally picked up in an earlier commit.
The file was modifiedcompiler-rt/lib/orc/macho_platform.cpp
Commit 77fdc0e56bf9463b432f1a2073ac506a8df9b652 by jezng
[lld-macho] Simplify lc-linker-option.ll and re-enable it on Windows

While attempting to simplify it, I discovered a concerning discrepancy
between our handling of LC_LINKER_OPTION vs ld64's. In particular, ld64
does not appear to check for `-all_load` nor `-ObjC` when processing
those options. Thus, if/when we fix this behavior, no duplicate symbol
error will be expected regardless of the use-after-free. As such, I've
removed the test logic that tries to induce the duplicate symbol error.
We can just rely on ASAN to do the verification.

In order to make the test run on Windows, I've removed the symlink
logic. Both ld64 and LLD handle this un-symlinked framework just fine.

I also capitalized the framework name, since that's the typical
convention.

Reviewed By: #lld-macho, oontvoo

Differential Revision: https://reviews.llvm.org/D112195
The file was modifiedlld/test/MachO/lc-linker-option.ll
Commit 56df1d80e2911a8cd23b70e9b7e76fcb386c7956 by koraq
[libc++] Use addressof in vector.

This addresses the usage of `operator&` in `<vector>`.

I now added tests for the current offending cases. I wonder whether it
would be better to add one addressof test per directory and test all
possible violations. Also to guard against possible future errors?

(Note there are still more headers with the same issue.)

Reviewed By: #libc, ldionne

Differential Revision: https://reviews.llvm.org/D111961
The file was addedlibcxx/test/std/containers/sequences/vector/vector.special/swap.addressof.compile.pass.cpp
The file was modifiedlibcxx/include/__iterator/wrap_iter.h
The file was addedlibcxx/test/std/containers/sequences/vector/vector.modifiers/insert_iter_size_value.addressof.compile.pass.cpp
The file was addedlibcxx/test/std/containers/sequences/vector/vector.cons/move.addressof.compile.pass.cpp
The file was addedlibcxx/test/std/containers/sequences/vector/vector.modifiers/erase_iter_iter.addressof.compile.pass.cpp
The file was addedlibcxx/test/std/containers/sequences/vector/vector.modifiers/emplace.addressof.compile.pass.cpp
The file was addedlibcxx/test/std/containers/sequences/vector/vector.modifiers/insert_iter_rvalue.addressof.compile.pass.cpp
The file was addedlibcxx/test/std/containers/sequences/vector/vector.cons/assign_move.addressof.compile.pass.cpp
The file was addedlibcxx/test/std/containers/sequences/vector/vector.modifiers/erase_iter.addressof.compile.pass.cpp
The file was modifiedlibcxx/include/vector
The file was addedlibcxx/test/std/containers/sequences/vector/vector.modifiers/insert_iter_value.addressof.compile.pass.cpp
The file was addedlibcxx/test/std/containers/sequences/vector/vector.modifiers/insert_iter_iter_iter.addressof.compile.pass.cpp
Commit b396010240cda92f5fcfa30cba1b9ad905561eae by yhs
[Clang] Support typedef with btf_decl_tag attributes

Previously, btf_del_tag attribute supports record, field, global variable,
function and function parameter ([1], [2]). This patch added support for typedef.
The main reason is for typedef of an anonymous struct/union, we can only apply
btf_decl_tag attribute to the anonymous struct/union like below:
  typedef struct { ... } __btf_decl_tag target_type
In this case, the __btf_decl_tag attribute applies to anonymous struct,
which increases downstream implementation complexity. But if
typedef with btf_decl_tag attribute is supported, we can have
  typedef struct { ... } target_type __btf_decl_tag
which applies __btf_decl_tag to typedef "target_type" which make it
easier to directly associate btf_decl_tag with a named type.
This patch permitted btf_decl_tag with typedef types with this reason.

[1] https://reviews.llvm.org/D106614
[2] https://reviews.llvm.org/D111588

Differential Revision: https://reviews.llvm.org/D110127
The file was modifiedclang/test/Misc/pragma-attribute-supported-attributes-list.test
The file was modifiedclang/include/clang/Basic/AttrDocs.td
The file was modifiedclang/test/Sema/attr-btf_tag.c
The file was modifiedclang/include/clang/Basic/Attr.td
Commit f6811cec84218912d1c7c9b0b8d308834e6e24e3 by yhs
[DebugInfo] Support typedef with btf_decl_tag attributes

Clang patch ([1]) added support for btf_decl_tag attributes with typedef
types. This patch added llvm support including dwarf generation.
For example, for typedef
   typedef unsigned * __u __attribute__((btf_decl_tag("tag1")));
   __u u;
the following shows llvm-dwarfdump result:
   0x00000033:   DW_TAG_typedef
                   DW_AT_type      (0x00000048 "unsigned int *")
                   DW_AT_name      ("__u")
                   DW_AT_decl_file ("/home/yhs/work/tests/llvm/btf_tag/t.c")
                   DW_AT_decl_line (1)

   0x0000003e:     DW_TAG_LLVM_annotation
                     DW_AT_name    ("btf_decl_tag")
                     DW_AT_const_value     ("tag1")

   0x00000047:     NULL

  [1] https://reviews.llvm.org/D110127

Differential Revision: https://reviews.llvm.org/D110129
The file was addedclang/test/CodeGen/attr-btf_tag-typedef.c
The file was modifiedllvm/include/llvm/IR/DIBuilder.h
The file was modifiedllvm/lib/CodeGen/AsmPrinter/DwarfUnit.cpp
The file was modifiedclang/lib/CodeGen/CGDebugInfo.cpp
The file was addedllvm/test/Bitcode/attr-btf_tag-typedef.ll
The file was modifiedllvm/lib/IR/DIBuilder.cpp
The file was addedllvm/test/DebugInfo/X86/attr-btf_tag-typedef.ll
Commit dccfaddc6bcc711bd972b43bff5ce6d71c1b39dc by kazu
[clang] Use StringRef::contains (NFC)
The file was modifiedclang/lib/ARCMigrate/Transforms.cpp
The file was modifiedclang/lib/CodeGen/CodeGenFunction.cpp
The file was modifiedclang/lib/ARCMigrate/ObjCMT.cpp
The file was modifiedclang/lib/ARCMigrate/TransUnbridgedCasts.cpp
The file was modifiedclang/lib/Rewrite/Rewriter.cpp
The file was modifiedclang/utils/TableGen/ClangASTPropertiesEmitter.cpp
The file was modifiedclang/lib/AST/Expr.cpp
The file was modifiedclang/lib/CodeGen/TargetInfo.cpp
The file was modifiedclang/lib/Analysis/RetainSummaryManager.cpp
The file was modifiedclang/lib/ASTMatchers/ASTMatchersInternal.cpp
The file was modifiedclang/utils/TableGen/RISCVVEmitter.cpp
The file was modifiedclang/lib/Lex/HeaderSearch.cpp
The file was modifiedclang/lib/Lex/LiteralSupport.cpp
The file was modifiedclang/utils/TableGen/NeonEmitter.cpp
Commit b8da594750762f811283820c19b02cedfb6632d4 by blangmuir
Reapply [ORC-RT] Configure the ORC runtime for more architectures and platforms

Reapply 5692ed0cce8c95, but with the ORC runtime disabled explicitly on
CrossWinToARMLinux to match the other compiler-rt runtime libraries.

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

---

Enable building the ORC runtime for 64-bit and 32-bit ARM architectures,
and for all Darwin embedded platforms (iOS, tvOS, and watchOS). This
covers building the cross-platform code, but does not add TLV runtime
support for the new architectures, which can be added independently.

Incidentally, stop building the Mach-O TLS support file unnecessarily on
other platforms.

Differential Revision: https://reviews.llvm.org/D112111
The file was modifiedcompiler-rt/cmake/config-ix.cmake
The file was modifiedcompiler-rt/lib/orc/simple_packed_serialization.h
The file was modifiedcompiler-rt/lib/orc/elfnix_tls.x86-64.S
The file was modifiedclang/cmake/caches/CrossWinToARMLinux.cmake
The file was modifiedcompiler-rt/lib/orc/CMakeLists.txt
The file was modifiedcompiler-rt/cmake/Modules/AllSupportedArchDefs.cmake
The file was modifiedcompiler-rt/lib/orc/macho_tlv.x86-64.S
Commit 2dcad7754a204d5dbb78fef8f6b13cd005456e33 by aeubanks
[clang] Don't clear AST if we have consumers running after the main action

Downstream users may have Clang plugins. By default these plugins run
after the main action if they are specified on the command line.

Since these plugins are ASTConsumers, presumably they inspect the AST.
So we shouldn't clear it if any plugins run after the main action.

Reviewed By: dblaikie, hans

Differential Revision: https://reviews.llvm.org/D112190
The file was addedclang/test/Misc/clear-ast-before-backend-plugins.c
The file was modifiedclang/lib/Frontend/FrontendAction.cpp
Commit cfca2ae1f5babaf0877bbd3ce8665b9db3344411 by aaron
Update the C++ and C status pages now that Clang 13 has been released
The file was modifiedclang/www/c_status.html
The file was modifiedclang/www/cxx_status.html
Commit acfe7d895d2f0897fe8f79151a491e75a7a99a25 by aaron
Update the title and encoding for the C++ status page
The file was modifiedclang/www/cxx_status.html
Commit baea663a6e9bc52f80995d02bb8149934c825612 by listmail
[IPT] Restructure cache to allow lazy update following invalidation [NFC]

This change restructures the cache used in IPT to point not to the first special instruction, but to the first instruction which *could* be special. That is, the cached reference is always equal to the first special, or comes before it in the block.

This avoids expensive block scans when we are removing special instructions from the beginning of the block. At the moment, this case is not heavily used, though it does trigger in GVN when doing CSE of calls. The main motivation was a change I'm no longer planning to move forward with, but the cache optimization seemed worthwhile as a minor perf win at low cost.

Differential Revision: https://reviews.llvm.org/D111768
The file was modifiedllvm/lib/Analysis/InstructionPrecedenceTracking.cpp
The file was modifiedllvm/include/llvm/Analysis/InstructionPrecedenceTracking.h
Commit 92673fad66f449f63acc76dfbb5e0bf05978663b by fraser
[RISCV] Add a test showing incorrect VSETVLI insertion

This test case, reduced from an internal test failure, shows how we may
incorrectly skip the insertion of VSETVLI instructions when doing
cross-basic-block analysis.

The entry block ends in a `e32,mf2`. Its single successor, %bb.1, ends with a
`e8,mf8`, but for a mask-type instruction, so is considered compatible.
This means that the info %bb.1 is merged into its predecessor so
produces a `e32,mf2`. When it comes to the last block, which requires a
`e32,mf2`, we skip the insertion of a vsetvli because all predecessors
were determined to preserve the right vtype.

However, when %bb.1 is actually laid out it does actually need a
`e8,mf8` vsetvli, since the previous instruction has a different tail
policy. This means that when execution flows from %bb.1 to %bb.3, the
`vadd.vx` is misconfigured.

Reviewed By: craig.topper

Differential Revision: https://reviews.llvm.org/D112223
The file was modifiedllvm/test/CodeGen/RISCV/rvv/vsetvli-insert-crossbb.mir
Commit 19b07ec00062daffcb2fb132f4ac0f2484ff44fa by aeubanks
Reland [clang] Pass -clear-ast-before-backend in Clang::ConstructJob()

This clears the memory used for the Clang AST before we run LLVM passes.

https://llvm-compile-time-tracker.com/compare.php?from=d0a5f61c4f6fccec87fd5207e3fcd9502dd59854&to=b7437fee79e04464dd968e1a29185495f3590481&stat=max-rss
shows significant memory savings with no slowdown (in fact -O0 slightly speeds up).

For more background, see
https://lists.llvm.org/pipermail/cfe-dev/2021-September/068930.html.

Turn this off for the interpreter since it does codegen multiple times.

Relanding with fix for -print-stats: D111973

Relanding with fix for plugins: D112190

If you'd like to use this even with plugins, consider using the features
introduced in D112096.

This can be turned off with -Xclang -no-clear-ast-before-backend.

Differential Revision: https://reviews.llvm.org/D111270
The file was modifiedclang/lib/Driver/ToolChains/Clang.cpp
The file was modifiedclang/lib/Interpreter/Interpreter.cpp
Commit 66d22b4da4afe00c695d9714687aac8b9e4b7396 by spatel
[VectorCombine] fold shuffle-of-binops with common operand

shuf (bo X, Y), (bo X, W) --> bo (shuf X), (shuf Y, W)

This is motivated by an example in D111800
(although that patch avoids the problem for that particular example).

The pattern is shown in reduced form with:
https://llvm.org/PR52178
https://alive2.llvm.org/ce/z/d8zB4D

There is no difference on the PhaseOrdering test from D111800
because the aarch64 cost model says that the shuffle cost is 3 while
the fadd cost is 2.

Differential Revision: https://reviews.llvm.org/D111901
The file was modifiedllvm/test/Transforms/VectorCombine/X86/shuffle.ll
The file was modifiedllvm/lib/Transforms/Vectorize/VectorCombine.cpp
Commit 13c31539f7da403fee11fe2163249837460c3bf2 by clementval
[fir] Add Character helper

This patch is extracted from D111337. It introduce the
CharacterExprHelper that helps dealing with character in FIR.

Reviewed By: schweitz, awarzynski

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

Co-authored-by: Jean Perier <jperier@nvidia.com>
Co-authored-by: Eric Schweitz <eschweitz@nvidia.com>
Co-authored-by: V Donaldson <vdonaldson@nvidia.com>
The file was modifiedflang/lib/Optimizer/Builder/CMakeLists.txt
The file was addedflang/lib/Optimizer/Builder/Character.cpp
The file was addedflang/unittests/Optimizer/Builder/CharacterTest.cpp
The file was modifiedflang/unittests/Optimizer/CMakeLists.txt
The file was modifiedflang/include/flang/Optimizer/Builder/FIRBuilder.h
The file was modifiedflang/include/flang/Optimizer/Dialect/FIROpsSupport.h
The file was modifiedflang/unittests/Optimizer/Builder/FIRBuilderTest.cpp
The file was modifiedflang/lib/Optimizer/Builder/FIRBuilder.cpp
The file was addedflang/include/flang/Optimizer/Builder/Character.h
The file was modifiedflang/include/flang/Optimizer/Dialect/FIRType.h