SuccessChanges

Summary

  1. Revert "[clang] Add missing .def files to Clang's modulemap" (details)
  2. Perform an extra consistency check when searching ModuleManager's (details)
  3. [scudo][standalone] Enable secondary cache release on Fuchsia (details)
  4. run in terminal (details)
  5. [ThinLTO] Fix a metadata lost issue with DICompileUnit import. (details)
  6. [mlir][Affine] Support affine vector loads/stores in LICM (details)
  7. Use an Identifier instead of an OperationName internally for OpPassManager identification (NFC) (details)
  8. Improve error handling for SmallVector programming errors (details)
  9. [VectorCombine][SVE] Do not fold bitcast shuffle for scalable type. (details)
  10. Fix de6caf871be79dc7549aebe4e4fb57d52f6ed202 (details)
  11. [PowerPC] Fix broken kill flag after MI peephole (details)
  12. [libc++] Avoid including <sys/cdefs.h> on non-Apple platforms in <ctime> (details)
  13. [MLIR][Affine][VectorOps] Vectorize uniform values in SuperVectorizer (details)
Commit 3b12e12d4b9efbdd28113da6db0f74b660257c83 by Adrian Prantl
Revert "[clang] Add missing .def files to Clang's modulemap"

This reverts commit e0e7eb2e2648aee83caf2ecfe2972ce2f653d306.

[the commit this fixes up was reverted]
The file was modifiedclang/include/clang/module.modulemap (diff)
Commit 272742a92d2443893eb98a7b3460e243e34278f9 by Adrian Prantl
Perform an extra consistency check when searching ModuleManager's
cache for implicit modules.

The ModuleManager's use of FileEntry nodes as the keys for its map of
loaded modules is less than ideal. Uniqueness for FileEntry nodes is
maintained by FileManager, which in turn uses inode numbers on hosts
that support that. When coupled with the module cache's proclivity for
turning over and deleting stale PCMs, this means entries for different
module files can wind up reusing the same underlying inode. When this
happens, subsequent accesses to the Modules map will disagree on the
ModuleFile associated with a given file.

In general, it is not sufficient to resolve this conundrum with a type
like FileEntryRef that stores the name of the FileEntry node on first
access because of path canonicalization issues. However, the paths
constructed for implicit module builds are fully under Clang's
control. We *can*, therefore, rely on their structure being consistent
across operating systems and across subsequent accesses to the Modules
map.

To mitigate the effects of inode reuse, perform an extra name check when
implicit modules are returned from the cache. This has the effect of
forcing reused FileEntry nodes to stomp over existing-but-stale entries
in the cache, which simulates a miss - exactly the desired behavior.

rdar://48443680

Patch by Robert Widmann!

Differential Revision: https://reviews.llvm.org/D86823
The file was modifiedclang/lib/Serialization/ModuleManager.cpp (diff)
Commit 00d9907a7ac86c3aa49c8cbb21a97094b5887ea9 by kostyak
[scudo][standalone] Enable secondary cache release on Fuchsia

I had left this as a TODO, but it turns out it wasn't complicated.
By specifying `MAP_RESIZABLE`, it allows us to keep the VMO which we
can then use for release purposes.
`releasePagesToOS` also had to be called the "proper" way, as Fuchsia
requires the `Offset` field to be correct. This has no impact on
non-Fuchsia platforms.

Differential Revision: https://reviews.llvm.org/D86800
The file was modifiedcompiler-rt/lib/scudo/standalone/secondary.h (diff)
The file was modifiedcompiler-rt/lib/scudo/standalone/tests/secondary_test.cpp (diff)
The file was modifiedcompiler-rt/lib/scudo/standalone/combined.h (diff)
The file was modifiedcompiler-rt/lib/scudo/standalone/tests/combined_test.cpp (diff)
The file was modifiedlldb/tools/lldb-vscode/JSONUtils.cpp (diff)
The file was modifiedlldb/packages/Python/lldbsuite/test/tools/lldb-vscode/vscode.py (diff)
The file was modifiedlldb/tools/lldb-vscode/VSCode.h (diff)
The file was modifiedlldb/tools/lldb-vscode/VSCode.cpp (diff)
The file was addedlldb/test/API/tools/lldb-vscode/runInTerminal/Makefile
The file was modifiedlldb/tools/lldb-vscode/package.json (diff)
The file was modifiedlldb/packages/Python/lldbsuite/test/tools/lldb-vscode/lldbvscode_testcase.py (diff)
The file was modifiedlldb/tools/lldb-vscode/JSONUtils.h (diff)
The file was addedlldb/test/API/tools/lldb-vscode/runInTerminal/TestVSCode_runInTerminal.py
The file was addedlldb/test/API/tools/lldb-vscode/runInTerminal/main.c
The file was modifiedlldb/tools/lldb-vscode/lldb-vscode.cpp (diff)
Commit f09ccf89fbee976bcca77b374f69987c2e96e1ce by hoy
[ThinLTO] Fix a metadata lost issue with DICompileUnit import.

For ThinLTO importing we don't need to import all the fields of the DICompileUnit, such as enums, macros, retained types lists. The importation of those fields were previously disabled by setting their value map entries to nullptr. Unfortunately a metadata node can be shared by multiple metadata operands. Setting the map entry to nullptr might result in not importing other metadata unexpectedly.  The issue is fixed by explicitly setting the original DICompileUnit fields (still a copy of the source module metadata) to null.

Reviewed By: wenlei, dblaikie

Differential Revision: https://reviews.llvm.org/D86675
The file was addedllvm/test/ThinLTO/X86/import-metadata.ll
The file was modifiedllvm/lib/Linker/IRMover.cpp (diff)
The file was addedllvm/test/ThinLTO/X86/Inputs/import-metadata.ll
Commit 553bfc8fa17f8c8a2bc414af1a403ea4abc65fde by diego.caballero
[mlir][Affine] Support affine vector loads/stores in LICM

Make use of affine memory op interfaces in AffineLoopInvariantCodeMotion so
that it can also work on affine.vector_load and affine.vector_store ops.

Reviewed By: bondhugula

Differential Revision: https://reviews.llvm.org/D86986
The file was modifiedmlir/lib/Dialect/Affine/Transforms/AffineLoopInvariantCodeMotion.cpp (diff)
The file was modifiedmlir/test/Dialect/Affine/affine-loop-invariant-code-motion.mlir (diff)
Commit 1284dc34abd11ce4275ad21c0470ad8c679b59b7 by joker.eph
Use an Identifier instead of an OperationName internally for OpPassManager identification (NFC)

This allows to defers the check for traits to the execution instead of forcing it on the pipeline creation.
In particular, this is making our pipeline creation tolerant to dialects not being loaded in the context yet.

Reviewed By: rriddle, GMNGeoffrey

Differential Revision: https://reviews.llvm.org/D86915
The file was modifiedmlir/lib/Pass/PassStatistics.cpp (diff)
The file was modifiedmlir/unittests/Pass/PassManagerTest.cpp (diff)
The file was modifiedmlir/lib/Pass/PassTiming.cpp (diff)
The file was modifiedmlir/include/mlir/Pass/PassManager.h (diff)
The file was modifiedmlir/include/mlir/Pass/PassInstrumentation.h (diff)
The file was modifiedmlir/lib/Pass/Pass.cpp (diff)
Commit 848b0e244c9ff5413c2eee6357d5faab1402d619 by maskray
Improve error handling for SmallVector programming errors

This patch changes errors in `SmallVector::grow` that are independent of
memory capacity to be reported using report_fatal_error or
std::length_error instead of report_bad_alloc_error, which falsely signals
an OOM.

It also cleans up a few related things:
- makes report_bad_alloc_error to print the failure reason passed
  to it.
- fixes the documentation to indicate that report_bad_alloc_error
  calls `abort()` not "an assertion"
- uses a consistent name for the size/capacity argument to `grow`
  and `grow_pod`

Reviewed By: mehdi_amini, MaskRay

Differential Revision: https://reviews.llvm.org/D86892
The file was modifiedllvm/include/llvm/ADT/SmallVector.h (diff)
The file was modifiedllvm/include/llvm/Support/ErrorHandling.h (diff)
The file was modifiedllvm/lib/Support/ErrorHandling.cpp (diff)
The file was modifiedllvm/lib/Support/SmallVector.cpp (diff)
Commit b4f04d7135078dd22abbcedbabd3bd67ccb037d7 by huihuiz
[VectorCombine][SVE] Do not fold bitcast shuffle for scalable type.

First, shuffle cost for scalable type is not known for scalable type;
Second, we cannot reason if the narrowed shuffle mask for scalable type
is a splat or not.

E.g., Bitcast splat vector from type <vscale x 4 x i32> to <vscale x 8 x i16>
will involve narrowing shuffle mask <vscale x 4 x i32> zeroinitializer to
<vscale x 8 x i32> with element sequence of <0, 1, 0, 1, ...>, which cannot be
reasoned if it's a valid splat or not.

Reviewed By: spatel

Differential Revision: https://reviews.llvm.org/D86995
The file was modifiedllvm/lib/Transforms/Vectorize/VectorCombine.cpp (diff)
The file was addedllvm/test/Transforms/VectorCombine/AArch64/vscale-bitcast-shuffle.ll
The file was addedllvm/test/Transforms/VectorCombine/AArch64/lit.local.cfg
Commit 51128b670d4f757132e927c4f3dd78d257d37f70 by waltermelon
Fix de6caf871be79dc7549aebe4e4fb57d52f6ed202

Failure found in
http://lab.llvm.org:8011/builders/lldb-x86_64-debian/builds/16855

The issue is a header not being included
The file was modifiedlldb/tools/lldb-vscode/VSCode.h (diff)
Commit 69289cc10ffd1de4d3bf05d33948e6b21b6e68db by nemanja.i.ibm
[PowerPC] Fix broken kill flag after MI peephole

The test case in https://bugs.llvm.org/show_bug.cgi?id=47373 exposed
two bugs in the PPC back end. The first one was fixed in commit
27714075848e7f05a297317ad28ad2570d8e5a43 but the test case had to
be added without -verify-machineinstrs due to the second bug.
This commit fixes the use-after-kill that is left behind by the
PPC MI peephole optimization.
The file was modifiedllvm/test/CodeGen/PowerPC/mi-peephole.mir (diff)
The file was modifiedllvm/lib/Target/PowerPC/PPCMIPeephole.cpp (diff)
The file was modifiedllvm/test/CodeGen/PowerPC/jump-tables-collapse-rotate-remove-SrcMI.mir (diff)
The file was modifiedllvm/test/CodeGen/PowerPC/pr47373.ll (diff)
Commit 55714678796c8fc456866add2841f3dd282e5392 by Louis Dionne
[libc++] Avoid including <sys/cdefs.h> on non-Apple platforms in <ctime>
The file was modifiedlibcxx/include/ctime (diff)
Commit 46781630a34ea2157bf59f9de5dc545dcd61a146 by diego.caballero
[MLIR][Affine][VectorOps] Vectorize uniform values in SuperVectorizer

This patch adds basic support for vectorization of uniform values to SuperVectorizer.
For now, only invariant values to the target vector loops are considered uniform. This
enables the vectorization of loops that use function arguments and external definitions
to the vector loops. We could extend uniform support in the future if we implement some
kind of divergence analysis algorithm.

Reviewed By: nicolasvasilache, aartbik

Differential Revision: https://reviews.llvm.org/D86756
The file was modifiedmlir/test/Dialect/Affine/SuperVectorize/vectorize_1d.mlir (diff)
The file was modifiedmlir/include/mlir/IR/Builders.h (diff)
The file was addedmlir/test/Dialect/Affine/SuperVectorize/uniform_divergent.mlir
The file was modifiedmlir/lib/Dialect/Affine/Transforms/SuperVectorize.cpp (diff)