SuccessChanges

Summary

  1. [clang-format] Adds a formatter for aligning arrays of structs (details)
  2. [fuzzer] Fix build on musl (details)
  3. [ELF] Add OVERWRITE_SECTIONS command (details)
  4. Introduce tensor.insert op to Tensor dialect. (details)
  5. [DSE] Extra multiblock loop tests, NFC. (details)
  6. unwind: allow building with GCC (details)
  7. Fix misspelled instruction in X86 assembly parser (details)
  8. [ms] [llvm-ml] Fix capitalization of the ignored CPU directives (details)
  9. [ms] [llvm-ml] When parsing MASM, "jmp short" instructions are case insensitive (details)
Commit 673c5ba58497298a684f8b8dfddbfb11cd89950e by bjoern
[clang-format] Adds a formatter for aligning arrays of structs

This adds a new formatter to arrange array of struct initializers into
neat columns.

Differential Revision: https://reviews.llvm.org/D101868
The file was modifiedclang/lib/Format/FormatToken.h
The file was modifiedclang/lib/Format/WhitespaceManager.h
The file was modifiedclang/docs/ReleaseNotes.rst
The file was modifiedclang/lib/Format/Format.cpp
The file was modifiedclang/lib/Format/TokenAnnotator.cpp
The file was modifiedclang/lib/Format/WhitespaceManager.cpp
The file was modifiedclang/unittests/Format/FormatTest.cpp
The file was modifiedclang/include/clang/Format/Format.h
The file was modifiedclang/lib/Format/TokenAnnotator.h
The file was addedclang/test/Format/struct-array-initializer.cpp
The file was modifiedclang/docs/ClangFormatStyleOptions.rst
Commit 60e32a1f34e9ea60155a98bbe6ee5ec2a383efa3 by i
[fuzzer] Fix build on musl

cstddef is needed for size_t definition.
(Multiple headers can provide size_t but none of them exists.)

Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D96213
The file was modifiedcompiler-rt/lib/fuzzer/FuzzerInterceptors.cpp
Commit 899fdf548eee427fe08e462955e6f817ca949730 by i
[ELF] Add OVERWRITE_SECTIONS command

This implements https://sourceware.org/bugzilla/show_bug.cgi?id=26404

An `OVERWRITE_SECTIONS` command is a `SECTIONS` variant which contains several
output section descriptions. The output sections do not have specify an order.
Similar to `INSERT [BEFORE|AFTER]`, `LinkerScript::hasSectionsCommand` is not
set, so the built-in rules (see `docs/ELF/linker_script.rst`) still apply.
`OVERWRITE_SECTIONS` can be more convenient than `INSERT` because it does not
need an anchor section.

The initial syntax is intentionally narrow to facilitate backward compatible
extensions in the future. Symbol assignments cannot be used.

This feature is versatile. To list a few usage:

* Use `section : { KEEP(...) }` to retain input sections under GC
* Define encapsulation symbols (start/end) for an output section
* Use `section : ALIGN(...) : { ... }` to overalign an output section (similar to ld64 `-sectalign`)

When an output section is specified by both `OVERWRITE_SECTIONS` and
`INSERT`, `INSERT` is processed after overwrite sections. To make this work,
this patch changes `InsertCommand` to use name based matching instead of pointer
based matching. (This may cause a difference when `INSERT` moves one output
section more than once. Such duplicate commands should not be used in practice
(seems that in GNU ld the output sections may just disappear).)

A linker script can be used without -T/--script. The traditional `SECTIONS`
commands are concatenated, so a wrong rule can be more noticeable from the
section order. This feature if misused can be less noticeable, just like
`INSERT`.

Differential Revision: https://reviews.llvm.org/D103303
The file was modifiedlld/ELF/ScriptParser.cpp
The file was modifiedlld/docs/ELF/linker_script.rst
The file was modifiedlld/docs/ReleaseNotes.rst
The file was addedlld/test/ELF/linkerscript/overwrite-sections.test
The file was modifiedlld/ELF/LinkerScript.h
The file was modifiedlld/ELF/LinkerScript.cpp
The file was addedlld/test/ELF/linkerscript/overwrite-sections-discard.test
The file was modifiedlld/test/ELF/linkerscript/insert-duplicate.test
Commit b4baccc2a760ea13901f201e6ca326284254d205 by hanchung
Introduce tensor.insert op to Tensor dialect.

Add `tensor.insert` op to make `tensor.extract`/`tensor.insert` work in pairs
for `scalar` domain. Like `subtensor`/`subtensor_insert` work in pairs in
`tensor` domain, and `vector.transfer_read`/`vector.transfer_write` work in
pairs in `vector` domain.

Reviewed By: silvas

Differential Revision: https://reviews.llvm.org/D104139
The file was modifiedmlir/test/Dialect/Tensor/ops.mlir
The file was modifiedmlir/test/Dialect/Tensor/canonicalize.mlir
The file was modifiedmlir/include/mlir/Dialect/Tensor/IR/TensorOps.td
The file was modifiedmlir/lib/Dialect/Tensor/IR/TensorOps.cpp
The file was modifiedmlir/test/Dialect/Tensor/invalid.mlir
Commit 562593ff82f89961c2fb9cf89eb9524ec51425e9 by david.green
[DSE] Extra multiblock loop tests, NFC.

Some of these can be DSE'd, some of which cannot. Useful in D100464.
The file was modifiedllvm/test/Transforms/DeadStoreElimination/multiblock-loops.ll
Commit e03be2efe564026ad3b04d459794c89c674e1ed9 by Saleem Abdulrasool
unwind: allow building with GCC

This was regressed in adf1561d6ce8.  Since gcc does not support
`__has_feature`, this adjusts the build to use the
`__SANITIZE_ADDRESS__` macro which GCC defines to identify if ASAN is
enabled (similar to `__has_feature`).  This allows building libunwind
with gcc again.

Patch by Daniel Levin!

Reviewed By: compnerd

Differential Revision: https://reviews.llvm.org/D104176
The file was modifiedlibunwind/src/libunwind.cpp
Commit 56edcbc2ad8c15b01fd8b47c1f2665d274d0e896 by epastor
Fix misspelled instruction in X86 assembly parser

Did not correctly handle "jecxz short <address>".

Discovered while working on LLVM-ML; shows up in z_Windows_NT-586_asm.asm from the OpenMP runtime

Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D104194
The file was modifiedllvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
The file was modifiedllvm/test/MC/X86/intel-syntax.s
Commit d81c059c3ed22e7f52eb995599e576abd30eb895 by epastor
[ms] [llvm-ml] Fix capitalization of the ignored CPU directives

These directives are matched in lowercase, so make sure to use lowercase for their P suffix.

Differential Revision: https://reviews.llvm.org/D104206
The file was modifiedllvm/lib/MC/MCParser/COFFMasmParser.cpp
The file was addedllvm/test/tools/llvm-ml/ml32-context.asm
Commit f09e200b31f443d972f6723fb9d78638bb38b45c by epastor
[ms] [llvm-ml] When parsing MASM, "jmp short" instructions are case insensitive

Handle "short" in a case-insensitive fashion in MASM.

Required to correctly parse z_Windows_NT-586_asm.asm from the OpenMP runtime.

Reviewed By: thakis

Differential Revision: https://reviews.llvm.org/D104195
The file was modifiedllvm/lib/Target/X86/AsmParser/X86AsmParser.cpp
The file was addedllvm/test/tools/llvm-ml/jmp_short.asm