LLVM/project 2dc53f7llvm/lib/Target/AArch64 AArch64TargetTransformInfo.cpp, llvm/test/Transforms/LoopUnroll/AArch64 unroll-max-upperbound-uncomputable-trip-count.ll

[AArch64] Cap upper-bound unrolling of loops with uncomputable trip counts (#205102)

SCEV can compute a small maximum trip count for a loop even when it
cannot compute the exact backedge-taken count. This is typical of
data-dependent exits, such as the varint-length loops in sqlite3:

  for (i = 1; (v >>= 7) != 0; i++)
    ;

Unrolling to the maximum trip count turns the loop into a chain of
copies containing an exit test for every possible iteration. This
increases code size and the number of static branches without knowing
whether enough iterations usually execute to make unrolling profitable.

These loops were not unrolled before #197292. That change improved
SCEV's maximum backedge-taken count for shift recurrences, reducing the
maximum trip count of these loops to 6. This made them eligible for
AArch64 upper-bound unrolling and caused an approximately 3% regression
in sqlite3 from SPEC CPU 2026.

    [6 lines not shown]
DeltaFile
+173-0llvm/test/Transforms/LoopUnroll/AArch64/unroll-max-upperbound-uncomputable-trip-count.ll
+16-0llvm/lib/Target/AArch64/AArch64TargetTransformInfo.cpp
+189-02 files

LLVM/project 658b3a9mlir/include/mlir/Dialect/Tosa/IR TosaOps.h TosaTypesBase.td, mlir/include/mlir/IR CommonTypeConstraints.td

[mlir][tosa] Add more informative error messages to block scaled types (#211569)

This commit improves block scaled tensor type verification to provide a
specific reason about why type verification failed. Previously the error
message was a very generic "must be tosa-conformant tensor of number
values".

This commit restores previous functionality that was reverted by
https://github.com/llvm/llvm-project/pull/207995, but uses the ODS
string interpolation mechanism instead to prevent incompatibility with
PDLL.
DeltaFile
+49-9mlir/lib/Dialect/Tosa/IR/TosaOps.cpp
+11-5mlir/include/mlir/Dialect/Tosa/IR/TosaTypesBase.td
+11-3mlir/include/mlir/Dialect/Tosa/IR/TosaOps.h
+5-5mlir/test/Dialect/Tosa/verifier.mlir
+3-2mlir/include/mlir/IR/CommonTypeConstraints.td
+79-245 files

LLVM/project d0fe5dbllvm/lib/Target/AArch64 AArch64ISelLowering.cpp, llvm/test/CodeGen/AArch64/Atomics generate-tests.py aarch64_be-atomicrmw-lsfe.ll

[AArch64] Enable FEAT_LSFE CodeGen only when exception can be ignored (#212799)

This patch restricts the generation of new atomic instructions added
under FEAT_LSFE to functions where no-trapping-math flag is set and
strictfp attribute is not set. This is done to preserve the exception
behaviour of the original codegen.
DeltaFile
+311-280llvm/test/CodeGen/AArch64/Atomics/aarch64_be-atomicrmw-lsfe.ll
+311-280llvm/test/CodeGen/AArch64/Atomics/aarch64-atomicrmw-lsfe.ll
+10-33llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
+23-2llvm/test/CodeGen/AArch64/Atomics/generate-tests.py
+655-5954 files

LLVM/project 990a3e3llvm/docs NVPTXUsage.md, llvm/include/llvm/IR IntrinsicsNVVM.td

[NVVM][NVPTX] Add im2col_w support for S2G and reduction intrinsics (#214436)

PTX ISA 9.4 adds the im2col_no_offs::w mode to shared-to-global tensor
copy and reduction instructions for Rubin family targets.

This change adds the corresponding NVVM intrinsics and NVPTX lowering.
DeltaFile
+303-0llvm/test/CodeGen/NVPTX/cp-async-bulk-tensor-reduce-im2colw.ll
+122-0llvm/test/CodeGen/NVPTX/cp-async-bulk-tensor-s2g-im2colw.ll
+51-3llvm/docs/NVPTXUsage.md
+19-6llvm/lib/Target/NVPTX/NVPTXIntrinsics.td
+4-0llvm/lib/Target/NVPTX/NVPTXSubtarget.h
+1-1llvm/include/llvm/IR/IntrinsicsNVVM.td
+500-106 files

LLVM/project 096481dlibc/src/pwd getpwent.h setpwent.cpp, libc/test/src/pwd getpwent_test.cpp

[libc] Add getpwent, setpwent, and endpwent entrypoints (#213076)

Added getpwent, setpwent, and endpwent functions using the internal
pwd_utils line parser.

* Implemented getpwent.cpp, setpwent.cpp, and endpwent.cpp entrypoints
* Added database iteration state and helpers (open, close, read_next)
under namespace passwd in pwd_utils
* Registered entrypoints in config/linux/*/entrypoints.txt
* Added CMake target guards for File and platform_file to support
overlay builds and cross-platform targets
* Added unit tests in libc/test/src/pwd/getpwent_test.cpp

Assisted-by: Automated tooling, human reviewed.
DeltaFile
+152-0libc/test/src/pwd/getpwent_test.cpp
+136-0libc/src/pwd/pwd_utils.cpp
+48-0libc/src/pwd/CMakeLists.txt
+30-0libc/src/pwd/getpwent.cpp
+27-0libc/src/pwd/getpwent.h
+27-0libc/src/pwd/setpwent.cpp
+420-011 files not shown
+564-117 files

LLVM/project 8969ae1libc/benchmarks CMakeLists.txt, libc/cmake/modules LLVMLibCTestRules.cmake

[libc][NFC] Format all CMake files under libc/ (#213132)

Use cmake_format.py from #213102 on all CMakeLists.txt files in libc/

Assisted-by: Automated tooling, human reviewed.
DeltaFile
+820-820libc/test/shared/CMakeLists.txt
+127-127libc/cmake/modules/LLVMLibCTestRules.cmake
+109-109libc/docs/CMakeLists.txt
+72-72libc/benchmarks/CMakeLists.txt
+33-33libc/test/src/stdio/CMakeLists.txt
+33-33libc/src/string/CMakeLists.txt
+1,194-1,194109 files not shown
+1,762-1,782115 files

LLVM/project 30b8621lldb/source/Plugins/Process/FreeBSD NativeRegisterContextFreeBSD_arm64.cpp, lldb/source/Plugins/Process/Linux NativeRegisterContextLinux_arm64.cpp

[lldb] Make RegisterFlagsDetector into RegisterTypesDetector

In future it may be generating things other than flags. Functionality
is the same, but the interface changes to use RegisterType.
DeltaFile
+348-0lldb/source/Plugins/Process/Utility/RegisterTypeDetector_arm64.cpp
+0-334lldb/source/Plugins/Process/Utility/RegisterFlagsDetector_arm64.cpp
+0-101lldb/source/Plugins/Process/Utility/RegisterFlagsDetector_arm64.h
+99-0lldb/source/Plugins/Process/Utility/RegisterTypeDetector_arm64.h
+9-9lldb/source/Plugins/Process/Linux/NativeRegisterContextLinux_arm64.cpp
+7-7lldb/source/Plugins/Process/FreeBSD/NativeRegisterContextFreeBSD_arm64.cpp
+463-4513 files not shown
+472-4609 files

LLVM/project b004aealldb/include/lldb/Target Target.h RegisterTypeBuilder.h, lldb/source/Core DumpRegisterValue.cpp

[lldb] Refactor RegisterTypeBuilder

This prepares it for emitting union types. Major changes:
* Entry function is now a dispatcher to builder functions for each type.
* Name mangling is standardised.
* The register name parameter is no longer needed and so was removed.
DeltaFile
+107-86lldb/source/Plugins/RegisterTypeBuilder/RegisterTypeBuilderClang.cpp
+12-3lldb/source/Plugins/RegisterTypeBuilder/RegisterTypeBuilderClang.h
+2-4lldb/source/Target/Target.cpp
+2-3lldb/include/lldb/Target/Target.h
+2-3lldb/include/lldb/Target/RegisterTypeBuilder.h
+2-2lldb/source/Core/DumpRegisterValue.cpp
+127-1016 files

LLVM/project 6278eballvm/lib/Analysis ScalarEvolution.cpp, llvm/unittests/Analysis ScalarEvolutionTest.cpp

Revert "[SCEV] Speed up forgetLoop by avoiding def-use walk for loop-header PHIs" (#212485)

Reverts https://github.com/llvm/llvm-project/pull/201572
Multiple miscompilations are reported, see
https://github.com/llvm/llvm-project/issues/207744,
https://github.com/llvm/llvm-project/issues/212027

That commit made forgetLoop() rely on LoopUsers[L] and stop walking the
def-use chain of the loop-header PHIs. This is insufficient, because
some cached data is derived from the underlying IR of SCEVUnknown, it is
not reachable from LoopUsers[L].
After that commit, forgetLoop() no longer invalidated them, so stale
UnsignedRanges / SignedRanges, ConstantMultipleCache, ValuesAtScopes
cause miscompilations.

(cherry picked from commit 1c0eda0d2371a6a755f90299892a7b89dc917442)
DeltaFile
+0-39llvm/unittests/Analysis/ScalarEvolutionTest.cpp
+16-6llvm/lib/Analysis/ScalarEvolution.cpp
+16-452 files

LLVM/project 95b1b6dllvm/lib/Transforms/InstCombine InstructionCombining.cpp, llvm/test/Transforms/InstCombine fold-zext-of-deinterleave.ll vector-concat-binop.ll

[InstCombine] Remove binop(concat(x,y),concat(a,b)) -> concat(binop(x,a),binop(y,b)) fold (#214285)

A similar fold is cost-driven in VectorCombine, but this InstCombine
fold was then undoing the decision

Seems to an old fold added by @rotateright (#32373) before we created
VectorCombine to do this properly

Fixes #205707
DeltaFile
+0-282llvm/test/Transforms/InstCombine/vector-concat-binop.ll
+0-282llvm/test/Transforms/InstCombine/vector-concat-binop-inseltpoison.ll
+1-24llvm/lib/Transforms/InstCombine/InstructionCombining.cpp
+9-6llvm/test/Transforms/PhaseOrdering/X86/addsub.ll
+9-6llvm/test/Transforms/PhaseOrdering/X86/addsub-inseltpoison.ll
+3-2llvm/test/Transforms/InstCombine/fold-zext-of-deinterleave.ll
+22-6026 files

LLVM/project bffe5e5lldb/source/Plugins/Process/gdb-remote ProcessGDBRemote.cpp, lldb/test/API/functionalities/gdb_remote_client TestXMLRegisterFlags.py

use first instance of duplicated ID
DeltaFile
+19-8lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
+3-4lldb/test/API/functionalities/gdb_remote_client/TestXMLRegisterFlags.py
+22-122 files

LLVM/project c592f4alldb/test/API/functionalities/gdb_remote_client TestXMLRegisterFlags.py

Add tests to demonstrate our parsing mistakes.
DeltaFile
+74-0lldb/test/API/functionalities/gdb_remote_client/TestXMLRegisterFlags.py
+74-01 files

LLVM/project a59bb7blldb/source/Plugins/Process/gdb-remote ProcessGDBRemote.cpp, lldb/test/API/functionalities/gdb_remote_client TestXMLRegisterFlags.py

Add test for ID overlap
DeltaFile
+44-0lldb/test/API/functionalities/gdb_remote_client/TestXMLRegisterFlags.py
+2-2lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
+46-22 files

LLVM/project ebb6170lldb/include/lldb/Utility RegisterType.h RegisterTypeFlags.h, lldb/source/Plugins/Process/gdb-remote ProcessGDBRemote.h ProcessGDBRemote.cpp

[lldb] Store all XML register types in a single string map

We are assuming that their ID's are unique, so there's no need to keep
separate maps. We can do basic type checking by checking the kind of
the type pointed to.

A few more methods were added to the base RegisterType. GetSize()
returns 0 for enums because enums don't have a size until they are
used by a register. This is not ideal but it works for now.
DeltaFile
+64-70lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
+7-8lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.h
+11-3lldb/include/lldb/Utility/RegisterTypeFlags.h
+6-0lldb/include/lldb/Utility/RegisterType.h
+2-2lldb/source/Utility/RegisterTypeFlags.cpp
+90-835 files

LLVM/project c7259fclibcxx/src new.cpp, libcxx/src/support new.ipp

[libc++][libc++abi] Merge the operator new implementations into a shared file (#213427)

Instead of copying the code around we can simply share a file that
actually implements operator new/delete and include that file in the two
places that need the definitions.
DeltaFile
+213-0libcxx/src/support/new.ipp
+1-202libcxx/src/new.cpp
+1-199libcxxabi/src/stdlib_new_delete.cpp
+215-4013 files

LLVM/project 39cf655mlir/lib/Dialect/Affine/IR ValueBoundsOpInterfaceImpl.cpp, mlir/test/Dialect/Affine value-bounds-op-interface-impl.mlir

[mlir][affine] Implement ValueBoundsOpInterface for affine.for (#214614)

`scf.for` has provided induction variable bounds through
`ValueBoundsOpInterface` for a long time, but `affine.for` has no model
at all. `ValueBoundsConstraintSet` therefore cannot derive any bound for
an affine induction variable, not even `iv >= lowerBound`. Queries just
return "unknown", which is easy to miss because it looks the same as a
bound that genuinely cannot be proven.

Add a model for the induction variable. The lower bound of an
`affine.for` is the maximum over the results of its lower bound map and
the upper bound is the minimum over the results of its upper bound map,
so the induction variable is constrained by every individual result.
This follows how `AffineMinOpInterface` and `AffineMaxOpInterface` in
the same file align their maps with the constraint set; the shared logic
is factored into `alignBoundExpr`.

When both maps have exactly one result the step is taken into account as
well, following `scf::ForOpInterface`: the induction variable is always

    [29 lines not shown]
DeltaFile
+91-0mlir/test/Dialect/Affine/value-bounds-op-interface-impl.mlir
+59-0mlir/lib/Dialect/Affine/IR/ValueBoundsOpInterfaceImpl.cpp
+150-02 files

LLVM/project fe1bfb3llvm/lib/Target/SPIRV SPIRVEmitIntrinsics.cpp, llvm/test/CodeGen/SPIRV/instructions insertvalue-nested-extractvalue.ll

[SPIR-V] Lower nested aggregate insertvalue operands (#204239)

Fix a crash in the SPIR-V backend when an aggregate `extractvalue`
result is used as the base of a later `insertvalue`.

The failing pattern is:

```llvm
%e = extractvalue [1 x [1 x i64]] %a, 0
%i = insertvalue [1 x i64] %e, i64 %x, 0
%r = insertvalue [1 x [1 x i64]] %a, [1 x i64] %i, 0
```

`SPIRVPrepareFunctions` rewrites aggregate function arguments and
returns to `i32` SPIR-V value IDs. The `llvm.spv.insertv` intrinsic also
models its composite operand as an `i32` value ID. However, an
intermediate aggregate `extractvalue` could still be rewritten to
`llvm.spv.extractv` with an LLVM aggregate result type. Passing that
aggregate-typed value to `llvm.spv.insertv` made

    [14 lines not shown]
DeltaFile
+25-0llvm/test/CodeGen/SPIRV/instructions/insertvalue-nested-extractvalue.ll
+11-0llvm/lib/Target/SPIRV/SPIRVEmitIntrinsics.cpp
+36-02 files

LLVM/project d923e46lldb/source/Plugins/Platform/Windows PlatformWindows.cpp

[lldb][Windows] Document thread timeout variable (#213655)

This is a follow up to https://github.com/llvm/llvm-project/pull/213010.
DeltaFile
+6-2lldb/source/Plugins/Platform/Windows/PlatformWindows.cpp
+6-21 files

LLVM/project 9b843a5llvm/lib/Target/RISCV RISCVInstrInfo.td, llvm/test/CodeGen/RISCV tlsdesc-call-fallthrough.mir machine-outliner-call-fallthrough.mir

[RISCV] Remove isBarrier from PseudoCALLReg/PseudoTLSDESCCall (#214155)

`PseudoCALLReg` models a returning call with an explicit link register.
The machine outliner uses it for normal outlined calls that return
through `x5`.

Marking this pseudo as a barrier is inconsistent with call sites at the
end of a block that falls through to a successor after the outlined
function returns. MachineVerifier correctly diagnoses those blocks as
malformed.

Remove the barrier flag and add a MIR regression test that outlines a
sequence at the end of a fall-through block. The test runs for RV32 and
RV64 with `-verify-machineinstrs`.

The attribute isBarrier from PseudoTLSDESCCall is removed as well for
the similar reason and a MachineVerifier regression test is added for
the TLSDESC call at the end of a fall-through block.
DeltaFile
+72-0llvm/test/CodeGen/RISCV/machine-outliner-call-fallthrough.mir
+23-0llvm/test/CodeGen/RISCV/tlsdesc-call-fallthrough.mir
+2-2llvm/lib/Target/RISCV/RISCVInstrInfo.td
+97-23 files

LLVM/project 22149f3flang/lib/Optimizer/Transforms MIFOpConversion.cpp, flang/test/Fir/MIF sync_team.mlir this_image.mlir

[flang][MIF] Fix team_type usage in all MIF operations #205953 (#214207)

This PR resolves the issue #205953. Its purpose is to correct the use of
`team_type` by lowering it to Addr rather than to Box.

(cherry picked from commit 0563f0d88d8314edcde7deab465759a84696e894)
DeltaFile
+65-72flang/test/Fir/MIF/change_team2.mlir
+39-40flang/test/Fir/MIF/get_team.mlir
+25-31flang/test/Fir/MIF/form_team.mlir
+19-32flang/test/Fir/MIF/this_image.mlir
+21-25flang/lib/Optimizer/Transforms/MIFOpConversion.cpp
+16-22flang/test/Fir/MIF/sync_team.mlir
+185-2225 files not shown
+225-26611 files

LLVM/project e134dc0lld/COFF Driver.cpp Writer.cpp, lld/test/COFF arm64x-tls.s

[LLD][COFF] Emit ARM64X relocations for TLS directory (#213529)

The current behavior of merging EC and native chunks to have a single
TLS directory for both views matches the MSVC linker, but it has its
shortcomings. In addition to merging, that solution requires all TLS
callbacks to use -arm64xsameaddress, leaving it to the CRT to handle. If
the appropriate EC object files are not pulled in by linked EC code and
thus never have a chance to mark the callback with -arm64xsameaddress,
this may lead to an invalid image that crashes at runtime.

This patch avoids the entire problem by using entirely separate TLS
directories for EC and native views along with the standard ARM64X
dynamic relocation mechanism. Since callback lists are now separate, a
missing -arm64xsameaddress is no longer a problem.

Also, mingw-w64-crt currently doesn't mark its TLS callbacks with
-arm64xsameaddress. That could be changed if needed, but with this
change, it is no longer necessary.

(cherry picked from commit 65e92e073539c3fe3523256c4fba35ac1dedcb92)
DeltaFile
+56-10lld/test/COFF/arm64x-tls.s
+22-4lld/COFF/Writer.cpp
+1-4lld/COFF/Driver.cpp
+79-183 files

LLVM/project b7cde8fcompiler-rt/lib/builtins/arm aeabi_uread4.S aeabi_uwrite8.S

[compiler-rt] Disable executable stack on `aeabi_u{read,write}*.S` (#214465)

These were missing `NO_EXEC_STACK_DIRECTIVE` to add `.note.GNU-stack`;
without it, a binary including any of these files will have the stack
marked executable. Add the directive here, matching other similar files.

Symtab diff before:

$ clang compiler-rt/lib/builtins/arm/aeabi_uread4.S
--target=arm-unknown-linux-gnueabi -c
    $ llvm-readelf aeabi_uread4.o -S
    There are 5 section headers, starting at offset 0xe4:

    Section Headers:
[Nr] Name Type Address Off Size ES Flg Lk Inf Al
[ 0] NULL 00000000 000000 000000 00 0 0 0
[ 1] .strtab STRTAB 00000000 0000a8 000039 00 0 0 1
[ 2] .text PROGBITS 00000000 000034 000020 00 AX 0 0 4
[ 3] .ARM.attributes ARM_ATTRIBUTES 00000000 000054 000022 00 0 0 1

    [21 lines not shown]
DeltaFile
+2-0compiler-rt/lib/builtins/arm/aeabi_uwrite8.S
+2-0compiler-rt/lib/builtins/arm/aeabi_uwrite4.S
+2-0compiler-rt/lib/builtins/arm/aeabi_uread8.S
+1-0compiler-rt/lib/builtins/arm/aeabi_uread4.S
+7-04 files

LLVM/project 9266471flang/lib/Optimizer/Transforms MIFOpConversion.cpp, flang/test/Lower/MIF coarray_dealloc_not_alloc.f90

[flang][MIF] Fix undef reference to a coarray_handle in mif.dealloc_coarray #193157 (#213890)

This PR fixes the behavior reported in issue #193157. The coarray_handle
was only defined if a call to mif.alloc_coarray was present.
If a call to mif.dealloc_coarray was encountered without a prior call to
mif.alloc_coarray, then the coarray_handle was missing, and therefore
llvm.address_of pointed to a non-existent address, which is not allowed.
We now define a coarray_handle that has not been allocated by PRIF for
each coarray variables.

(cherry picked from commit a9426776e78a89dec776c34efdb7725de591d878)
DeltaFile
+32-2flang/lib/Optimizer/Transforms/MIFOpConversion.cpp
+15-0flang/test/Lower/MIF/coarray_dealloc_not_alloc.f90
+47-22 files

LLVM/project 2655597.github/workflows llvm-abi-tests.yml

workflows/llvm-abi-tests: Cache the baseline abi (#211968)

This way we don't need to recompute it for every workflow.

(cherry picked from commit 09734937d37ca9c8e8c9cdaa55d00339068922c3)
DeltaFile
+23-0.github/workflows/llvm-abi-tests.yml
+23-01 files

LLVM/project ff99615llvm/lib/Transforms/Vectorize SLPVectorizer.cpp, llvm/lib/Transforms/Vectorize/SLPVectorizer SLPTypeUtils.h SLPTypeUtils.cpp

[SLP][modularisation][NFC] Move full-vector width helpers to SLPTypeUtils (2/2)

Move the following BoUpSLP-independent helpers out of SLPVectorizer.cpp
into SLPVectorizer/SLPTypeUtils.{h,cpp}:

  getFullVectorNumberOfElements
  getFloorFullVectorNumberOfElements
  getMaskedDivRemType
  hasFullVectorsOrPowerOf2

They build on the type helpers moved in (1/2). Behavior is unchanged.

Part of the SLPVectorizer.cpp modularization effort:
https://discourse.llvm.org/t/modularizing-slpvectorizer-cpp/90922
DeltaFile
+0-66llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+56-0llvm/lib/Transforms/Vectorize/SLPVectorizer/SLPTypeUtils.cpp
+28-0llvm/lib/Transforms/Vectorize/SLPVectorizer/SLPTypeUtils.h
+84-663 files

LLVM/project ff8e562llvm/lib/Transforms/Vectorize CMakeLists.txt SLPVectorizer.cpp, llvm/lib/Transforms/Vectorize/SLPVectorizer SLPTypeUtils.h SLPTypeUtils.cpp

[SLP][modularisation][NFC] Move type/width helpers to SLPTypeUtils (1/2)

Move the following BoUpSLP-independent type/width helpers out of
SLPVectorizer.cpp into a new SLPVectorizer/SLPTypeUtils.{h,cpp}:

  isValidElementType
  getValueType
  getWidenedType

SLPReVec is made non-static and extern-declared in SLPTypeUtils.cpp so
the moved helpers can reference it; behavior is unchanged.

Part of the SLPVectorizer.cpp modularization effort:
https://discourse.llvm.org/t/modularizing-slpvectorizer-cpp/90922
DeltaFile
+76-0llvm/lib/Transforms/Vectorize/SLPVectorizer/SLPTypeUtils.cpp
+4-60llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+46-0llvm/lib/Transforms/Vectorize/SLPVectorizer/SLPTypeUtils.h
+1-0llvm/lib/Transforms/Vectorize/CMakeLists.txt
+127-604 files

LLVM/project f3bd40cllvm/include/llvm/Analysis ValueLattice.h, llvm/include/llvm/Transforms/Utils SCCPSolver.h

[ValueLattice][SCCP] Consider provenance for predicate-derived pointer constants (#160083)

Similarly to what it is being already done in GVN
(fb632ed2377d280b581b8d4653b855e60d611f77), make sure pointers
equalities derived via PredicatedInfo may be propagated so long as
pointer constants' provenance is taken into account, which may be
non-existent. This is achieved by tracking provenance in
ValueLatticeElement and restrain replacement to uses allowed by
`canReplacePointersInUseIfEqual`.

Fixes: https://github.com/llvm/llvm-project/issues/159565.
DeltaFile
+149-0llvm/test/Transforms/SCCP/assume-equality-pointers.ll
+41-6llvm/lib/Transforms/Utils/SCCPSolver.cpp
+19-4llvm/include/llvm/Analysis/ValueLattice.h
+7-0llvm/include/llvm/Transforms/Utils/SCCPSolver.h
+2-2llvm/test/Transforms/SCCP/replace-dereferenceable-ptr-with-undereferenceable.ll
+2-2llvm/lib/Analysis/Loads.cpp
+220-141 files not shown
+222-157 files

LLVM/project 9d3a3faclang/lib/AST TextNodeDumper.cpp, clang/test/AST ast-dump-APValue-lvalue.cpp

[clang][AST] Print OnePastTheEnd bit in `APValue::dump()` (#214450)

For lvalue APValues.
DeltaFile
+11-7clang/test/AST/ast-dump-APValue-lvalue.cpp
+1-0clang/lib/AST/TextNodeDumper.cpp
+12-72 files

LLVM/project 5126975clang-tools-extra/docs/clang-tidy/checks/bugprone optional-value-conversion.md invalid-enum-default-initialization.md

[clang-tidy][docs] Rewrite bugprone check docs to Markdown [2/4]
DeltaFile
+85-86clang-tools-extra/docs/clang-tidy/checks/bugprone/narrowing-conversions.md
+66-75clang-tools-extra/docs/clang-tidy/checks/bugprone/not-null-terminated-result.md
+67-69clang-tools-extra/docs/clang-tidy/checks/bugprone/missing-end-comparison.md
+67-67clang-tools-extra/docs/clang-tidy/checks/bugprone/multiple-new-in-one-expression.md
+53-55clang-tools-extra/docs/clang-tidy/checks/bugprone/invalid-enum-default-initialization.md
+45-46clang-tools-extra/docs/clang-tidy/checks/bugprone/optional-value-conversion.md
+383-39814 files not shown
+783-81120 files

LLVM/project 3cc4656bolt/lib/Core BranchLivenessInfo.cpp, bolt/lib/Passes BranchLivenessUtils.cpp LongJmp.cpp

[BOLT][AArch64] Expand cmpbr when reversing would overflow (#202998)

AArch64 compare-and-branch instructions can usually be reversed by
changing the condition and adjusting the immediate. At boundary values,
that adjustment can underflow or overflow, leaving the branch
non-reversible.

When condition flags are dead at such a branch, split the compare branch
into an explicit compare followed by a conditional branch. The new
sequence lets branch fixup reverse the condition without relying on an
out-of-range adjusted immediate.

Teach the branch-fixing paths to use cached branch liveness information
when deciding whether this expansion is legal. The liveness snapshot is
built before branch relaxation/fixup and is safe for the current users:
they only insert trampolines/stubs between existing CFG edges or invert
branches without changing program semantics.

Since expansion can grow the source basic block, update the local

    [2 lines not shown]
DeltaFile
+131-23bolt/unittests/Core/MCPlusBuilder.cpp
+84-38bolt/test/AArch64/compare-and-branch-inversion.S
+74-29bolt/lib/Passes/LongJmp.cpp
+72-15bolt/lib/Target/AArch64/AArch64MCPlusBuilder.cpp
+75-0bolt/lib/Core/BranchLivenessInfo.cpp
+59-0bolt/lib/Passes/BranchLivenessUtils.cpp
+495-10514 files not shown
+645-12220 files