LLVM/project 443782f — llvm/lib/Transforms/Utils ControlFlowUtils.cpp, llvm/test/Transforms/FixIrreducible basic.ll undef-phis.ll

[ControlFlowHub] Keep the incoming value of a redirected self-loop (#237903)

When reconnectPhis moves a PHI entry for a self-loop of Out (BB == Out)
into the new PHI in the guard block, it replaced the incoming value with
the new PHI itself. That is only right if the incoming value is the
original PHI, and that case is already handled: if the original PHI ends
up with no operands it is replaced by the new PHI everywhere, including
in the new PHI's own operand. Any other value, such as the next value
of an induction variable, was lost.

Keep the incoming value instead. This special case goes back to the
original UnifyLoopExits code, where BB == Out cannot happen.
FixIrreducible
reaches it when the header of an irreducible cycle has a self-loop.

In FixIrreducible/basic.ll the value along the self-loop is now the
input's own undef. In FixIrreducible/undef-phis.ll all the moved values
are now undef, so the PHI is replaced by undef (not poison, after
#237407).

    [3 lines not shown]
DeltaFile
+137-0llvm/test/Transforms/FixIrreducible/phi-self-loop.ll
+4-6llvm/lib/Transforms/Utils/ControlFlowUtils.cpp
+1-2llvm/test/Transforms/FixIrreducible/undef-phis.ll
+1-1llvm/test/Transforms/FixIrreducible/basic.ll
+143-94 files

LLVM/project 26ff0e1 — flang/include/flang/Evaluate tools.h, flang/lib/Evaluate fold-logical.cpp

[Flang][NFC] Remove trivial uses of SearchTypes (#238479)

Second cleanup after #216960

Some uses of `evaluate::SearchTypes` only use for a single TypeCategory.
With KIND not a template parameter anymore and uses only single static
TypeCategory, the visitor code does not need to be polymorphic anymore.
Most of these only look for a specific known-in-advance KIND, such that
we don't even need to loop over all kinds.

For the remaining uses I had the idea to turn `SearchTypes` into a
function that takes a polymorphic lambda. However, some visitor classes
such as `LocationHelper` and `AsConstantHelper` contain more methods
than just the callback method which diminishes the advantage over the
additional change churn.

Change applied using AI
DeltaFile
+40-78flang/lib/Evaluate/fold-logical.cpp
+6-43flang/include/flang/Evaluate/tools.h
+7-30flang/lib/Semantics/expression.cpp
+9-22flang/lib/Semantics/check-case.cpp
+62-1734 files

LLVM/project 98178cd — llvm/test/CodeGen/LoongArch/lasx vec-sext-invec-mask.ll build-vector.ll, llvm/test/CodeGen/LoongArch/lsx scalar-load-to-vector.ll vec-sext.ll

[LoongArch] Load scalars into vector lane 0 with FLD/VLDREPL

Inserting a loaded integer into lane 0 of an undefined vector, which is
also how sub-128-bit vector loads are legalized, was lowered to a scalar
load plus [X]VINSGR2VR. VINSGR2VR merges into its destination, so it
carries a false dependency on the previous value of that register, and
it needs a GPR-to-vector move.

Use FLD.{S/D} for 32/64-bit elements and [X]VLDREPL.{B/H} for 8/16-bit
elements instead. They write the whole register in one instruction.

When the register allocator reuses one vector register for several such
loads, the false dependency serializes otherwise independent chains. In
the GSM autocorrelation loop (9 x i64 multiply-accumulate over i16 taps)
on LA664:

  VF2: 0.953s -> 0.724s
  VF4: 1.446s -> 0.856s
DeltaFile
+76-80llvm/test/CodeGen/LoongArch/lasx/build-vector.ll
+32-50llvm/test/CodeGen/LoongArch/lsx/vec-sext.ll
+33-41llvm/test/CodeGen/LoongArch/lsx/scalar-load-to-vector.ll
+30-36llvm/test/CodeGen/LoongArch/lsx/ir-instruction/uitofp.ll
+28-32llvm/test/CodeGen/LoongArch/lsx/ir-instruction/sitofp.ll
+20-32llvm/test/CodeGen/LoongArch/lasx/vec-sext-invec-mask.ll
+219-27121 files not shown
+521-67427 files

LLVM/project ca4a922 — clang/test/Profile c-mcdc-not.c c-mcdc-nested-ternary.c

[Clang] Use fixed triple for more Profile tests (NFC) (#239186)

The index type size will differ between 32-bit and 64-bit platforms,
producing slightly different IR. Use a fixed 64-bit triple to
keep output consistent.
DeltaFile
+3-3clang/test/Profile/c-mcdc.c
+2-2clang/test/Profile/c-mcdc-not.c
+2-2clang/test/Profile/c-mcdc-nested-ternary.c
+2-2clang/test/Profile/c-mcdc-logicalop-ternary.c
+2-2clang/test/Profile/c-mcdc-class.cpp
+11-115 files

HardenedBSD/src 9f15c88 — sys/dev/sound/pci envy24ht.c

Merge remote-tracking branch 'rad/hardened/current/master' into hardened/current/pledge
DeltaFile
+11-22sys/dev/sound/pci/envy24ht.c
+11-221 files

LLVM/project 09c7da1 — llvm/test/CodeGen/LoongArch/lasx scalar-load-to-vector.ll, llvm/test/CodeGen/LoongArch/lsx scalar-load-to-vector.ll

[LoongArch][NFC] Pre-commit tests for loading a scalar into a vector
DeltaFile
+237-0llvm/test/CodeGen/LoongArch/lsx/scalar-load-to-vector.ll
+137-0llvm/test/CodeGen/LoongArch/lasx/scalar-load-to-vector.ll
+374-02 files

HardenedBSD/src 31722be — sys/dev/sound/pci envy24ht.c

Merge branch 'freebsd/current/main' into hardened/current/master
DeltaFile
+11-22sys/dev/sound/pci/envy24ht.c
+11-221 files

HardenedBSD/src d96e806 — lib/libc/string memset.3, sys/netpfil/ipfw ip_fw_table_algo.c

Merge branch 'freebsd/15-stable/main' into hardened/15-stable/main
DeltaFile
+3-2lib/libc/string/memset.3
+1-1sys/netpfil/ipfw/ip_fw_table_algo.c
+4-32 files

HardenedBSD/ports 669c38f — x11-toolkits/plasma6lts-kdeplasma-addons pkg-plist, x11-wm/plasma6-kwin-x11 pkg-plist

Merge branch 'freebsd/main' into hardenedbsd/main
DeltaFile
+6,137-0x11/plasma6lts-plasma-workspace/pkg-plist
+4,101-0x11/plasma6lts-plasma-desktop/pkg-plist
+2,080-0x11-toolkits/plasma6lts-kdeplasma-addons/pkg-plist
+1,743-0x11-wm/plasma6lts-kwin/pkg-plist
+0-1,528x11-wm/plasma6-kwin-x11/pkg-plist
+1,526-0x11-wm/plasma6lts-kwin-x11/pkg-plist
+15,587-1,528352 files not shown
+29,872-2,585358 files

OPNSense/core 8810f02 — src/etc rc.reboot rc.halt, src/etc/inc system.inc

system: simplify rc.halt and rc.reboot and use it during firmware upgrades as well

Run stop through our /etc/rc.shutdown hook and use the RC scripts everywhere.

Related to: https://forum.opnsense.org/index.php?topic=53287.0
DeltaFile
+1-5src/etc/inc/system.inc
+1-4src/etc/rc.halt
+1-3src/etc/rc.reboot
+1-1src/etc/rc.syshook.d/early/05-upgrade
+4-134 files

LLVM/project 3582495 — clang/lib/CIR/Lowering CIRPasses.cpp, clang/test/CIR/CodeGen call-conv-lowering-amdgpu-cxx-records.cpp call-conv-lowering-amdgpu-return-types.c

[CIR] Enable CallConvLowering for AMDGPU triples
DeltaFile
+165-0clang/test/CIR/CodeGen/call-conv-lowering-amdgpu-arg-types.c
+158-0clang/test/CIR/CodeGen/call-conv-lowering-amdgpu-return-types.c
+137-0clang/test/CIR/CodeGenHIP/call-conv-lowering-amdgpu-kernel-args.hip
+74-0clang/test/CIR/CodeGen/call-conv-lowering-amdgpu-cxx-records.cpp
+4-4clang/test/CIR/CodeGenHIP/cleanup-alloca-addrspace.hip
+4-2clang/lib/CIR/Lowering/CIRPasses.cpp
+542-61 files not shown
+544-87 files

HardenedBSD/ports a16a6c7 — x11-wm/theseus-ship Makefile

x11-wm/theseus-ship: Deprecate

Depends on broken x11-toolkits/como

PR:             300186
DeltaFile
+3-0x11-wm/theseus-ship/Makefile
+3-01 files

FreeBSD/ports a16a6c7 — x11-wm/theseus-ship Makefile

x11-wm/theseus-ship: Deprecate

Depends on broken x11-toolkits/como

PR:             300186
DeltaFile
+3-0x11-wm/theseus-ship/Makefile
+3-01 files

FreeBSD/ports 5e5d5bf — x11-toolkits/como Makefile

x11-toolkits/como: Make as BROKEN and deprecate

Does not support KDE Plasma 6.8

PR:             300186
DeltaFile
+4-0x11-toolkits/como/Makefile
+4-01 files

HardenedBSD/ports 5e5d5bf — x11-toolkits/como Makefile

x11-toolkits/como: Make as BROKEN and deprecate

Does not support KDE Plasma 6.8

PR:             300186
DeltaFile
+4-0x11-toolkits/como/Makefile
+4-01 files

pkgng/pkgng 31bc16f — libpkg pkg_add.c triggers.c, libpkg/private utils.h

utils: build random names without the shared rand() state
DeltaFile
+33-9libpkg/utils.c
+2-9libpkg/triggers.c
+0-4libpkg/pkg_add.c
+1-0libpkg/private/utils.h
+36-224 files

pkgng/pkgng f222e66 — libpkg dns_utils.c

ldns: do not share a resolver between SRV lookups (thread safety)
DeltaFile
+44-9libpkg/dns_utils.c
+44-91 files

pkgng/pkgng 48269e3 — libpkg pkg_sandbox.c

sandbox: prefer getpwnam_r()
DeltaFile
+4-3libpkg/pkg_sandbox.c
+4-31 files

pkgng/pkgng 6904115 — libpkg pkg_cpe.c pkg_osvf.c

cpe, osvf: use strtok_r() instead of strtok()
DeltaFile
+5-2libpkg/pkg_osvf.c
+3-2libpkg/pkg_cpe.c
+8-42 files

LLVM/project aa607d7 — llvm/lib/Analysis ValueTracking.cpp InstructionSimplify.cpp, llvm/test/Transforms/InstSimplify ldexp.ll

[InstSimplify] Fix poison propagation for ldexp (#239135)
DeltaFile
+12-4llvm/test/Transforms/InstSimplify/ldexp.ll
+0-5llvm/lib/Analysis/InstructionSimplify.cpp
+2-0llvm/lib/Analysis/ValueTracking.cpp
+14-93 files

LLVM/project 7d21367 — libc/src/__support/OSUtil/linux/syscall_wrappers CMakeLists.txt pkey_free.h, libc/src/sys/mman/linux CMakeLists.txt pkey_free.cpp

[libc] Use a syscall wrapper for pkey_free

This PR move pkey_free behind the centralized syscall wrappers, following libc/docs/dev/syscall_wrapper_refactor.md.
DeltaFile
+39-0libc/src/__support/OSUtil/linux/syscall_wrappers/pkey_free.h
+10-13libc/src/sys/mman/linux/pkey_free.cpp
+17-2utils/bazel/llvm-project-overlay/libc/BUILD.bazel
+13-0libc/src/__support/OSUtil/linux/syscall_wrappers/CMakeLists.txt
+4-3libc/src/sys/mman/linux/CMakeLists.txt
+83-185 files

LLVM/project 51f9073 — libc/src/__support/OSUtil/linux/syscall_wrappers CMakeLists.txt pkey_alloc.h, libc/src/sys/mman/linux CMakeLists.txt pkey_alloc.cpp

[libc] Use a syscall wrapper for pkey_alloc

This PR move pkey_alloc behind the centralized syscall wrappers, following libc/docs/dev/syscall_wrapper_refactor.md.
DeltaFile
+40-0libc/src/__support/OSUtil/linux/syscall_wrappers/pkey_alloc.h
+11-15libc/src/sys/mman/linux/pkey_alloc.cpp
+17-2utils/bazel/llvm-project-overlay/libc/BUILD.bazel
+13-0libc/src/__support/OSUtil/linux/syscall_wrappers/CMakeLists.txt
+4-3libc/src/sys/mman/linux/CMakeLists.txt
+85-205 files

LLVM/project e606eb9 — libc/src/__support/OSUtil/linux/syscall_wrappers CMakeLists.txt mremap.h, libc/src/sys/mman/linux CMakeLists.txt mremap.cpp

[libc] Use a syscall wrapper for mremap

This PR move mremap behind the centralized syscall wrappers, following libc/docs/dev/syscall_wrapper_refactor.md.
DeltaFile
+38-0libc/src/__support/OSUtil/linux/syscall_wrappers/mremap.h
+12-13libc/src/sys/mman/linux/mremap.cpp
+17-1utils/bazel/llvm-project-overlay/libc/BUILD.bazel
+13-0libc/src/__support/OSUtil/linux/syscall_wrappers/CMakeLists.txt
+4-2libc/src/sys/mman/linux/CMakeLists.txt
+84-165 files

OPNSense/core 1b71292 — src/opnsense/mvc/app/controllers/OPNsense/Auth/Api UserController.php, src/opnsense/mvc/app/controllers/OPNsense/Auth/forms dialogPriv.xml dialogUser.xml

System: Access - add "authority" option to ACL's which can be set to one of 'limited', 'administrative', 'unrestricted', this will help the user to identify sensitive roles more easily.
DeltaFile
+65-26src/opnsense/mvc/app/models/OPNsense/Core/ACL.php
+15-5src/opnsense/mvc/app/models/OPNsense/Core/ACL/ACL.php
+13-1src/opnsense/mvc/app/controllers/OPNsense/Auth/Api/UserController.php
+8-0src/opnsense/mvc/app/controllers/OPNsense/Auth/forms/dialogUser.xml
+5-0src/opnsense/mvc/app/controllers/OPNsense/Auth/forms/dialogPriv.xml
+3-0src/opnsense/mvc/app/views/OPNsense/Auth/user.volt
+109-322 files not shown
+111-328 files

LLVM/project 8ac35aa — mlir/include/mlir/IR OpBase.td, mlir/include/mlir/Interfaces ViewLikeInterface.td DataLayoutInterfaces.td

[mlir][ODS] Set `cppIncludes` on core traits and interfaces

Set the `cppIncludes` field introduced in #236155 on the traits and
interfaces defined in MLIR's core. Generated declarations using them now include the
headers declaring them.
Dialect interfaces get the field as well, although their generated
declarations do not emit includes yet.

Record-level `let` statements were generally preferred (as is currently convention with e.g., `cppNamespace`) with just occasional use of top-level `let` for e.g., many small trait definitions.

Co-authored-by: Claude <noreply at anthropic.com>
DeltaFile
+11-3mlir/include/mlir/Interfaces/SideEffectInterfaces.td
+11-1mlir/include/mlir/IR/OpBase.td
+9-2mlir/include/mlir/Interfaces/InferTypeOpInterface.td
+9-0mlir/include/mlir/Interfaces/MemorySlotInterfaces.td
+8-0mlir/include/mlir/Interfaces/DataLayoutInterfaces.td
+5-1mlir/include/mlir/Interfaces/ViewLikeInterface.td
+53-740 files not shown
+135-1046 files

pkgng/pkgng fd57fac — libpkg metalog.c

metalog: serialise the writes to the metalog

The stream was a plain global: two threads adding entries could interleave
their buffered writes, and a close racing with an add left a dangling
stream. Protect it with a mutex and clear the pointer once closed.
DeltaFile
+12-1libpkg/metalog.c
+12-11 files

pkgng/pkgng d9a4e57 — libpkg pkgdb.c

pkgdb: stop caching the length of the database directory

The length was computed on the first call and kept in a static, so any
later change of the database directory trimmed the paths at the wrong
offset. Compute it on every call, this is not a hot path.
DeltaFile
+1-4libpkg/pkgdb.c
+1-41 files

pkgng/pkgng a2bd081 — libpkg pkg_jobs_conflicts.c

conflicts: build the SipHash key only once and thread safe
DeltaFile
+12-7libpkg/pkg_jobs_conflicts.c
+12-71 files

LLVM/project 328395d — llvm/lib/CodeGen MachineSink.cpp, llvm/test/CodeGen/X86 setuge.ll

[MachineSink] Don't pass LiveIntervals and SlotIndexes to SplitCriticalEdge (#238888)

LiveIntervals and SlotIndexes are not used by this pass.
SplitCriticalEdge does not need them as well. This removes them and all
mentions of those analysis from MachineSink.

This was causing a crash under NewPM pipeline because SlotIndexes were
passed to SplitCriticalEdge, which was attempting to update it, but the
SI became corrupted in PerformTrivialForwardCoalescing which destroys MI
without updating SI
DeltaFile
+9-19llvm/lib/CodeGen/MachineSink.cpp
+1-0llvm/test/CodeGen/X86/setuge.ll
+10-192 files

LLVM/project bb09e01 — compiler-rt/lib/copyprof/tests copyprof_state_test.cpp

[CopyProf][NFC] Add argument comments in state test. (#237763)

Split out of #232851 as requested in review.

Stack: #237763 (this PR) → #232851 → #235453 → #235454 → #235455
DeltaFile
+3-3compiler-rt/lib/copyprof/tests/copyprof_state_test.cpp
+3-31 files