LLVM/project 0a82646clang/docs SanitizerSpecialCaseList.rst ReleaseNotes.rst, llvm/lib/Support SpecialCaseList.cpp

[SpecialCaseList] Add backward compatible dot-slash handling

This PR is preparation for:
* https://github.com/llvm/llvm-project/pull/167283

The new behavior is controlled by the `Version` field in the special
case list file.

- Version 1 and 2: Path is matched as-is, regardless of presence of "./".
- Version 3, 5 and higher: Paths with leading dot-slash are canonicalized
  to paths without dot-slash before matching. This means that a rule
  like `src=./foo` will never match, and `src=foo` will match both
  `foo` and `./foo`. (Version 3 never became default but has this behavior).
- Version 4: Transitionary version. Paths are matched both ways
  (canonicalized and non-canonicalized) to maintain backward compatibility.
  If a match only works with the old behavior (non-canonicalized), a warning
  is emitted.

This change allows for a gradual transition to the new behavior, while

    [6 lines not shown]
DeltaFile
+49-1llvm/unittests/Support/SpecialCaseListTest.cpp
+42-6llvm/lib/Support/SpecialCaseList.cpp
+21-0clang/docs/SanitizerSpecialCaseList.rst
+8-0clang/docs/ReleaseNotes.rst
+120-74 files

LLVM/project 5b84027lldb/source/Plugins/ObjectFile/Mach-O MachOTrie.cpp, lldb/unittests/ObjectFile/MachO MachOTrieTest.cpp

[lldb][Mach-O] Bound export-trie symbol name length (#202947)

`ParseTrieEntries` assembles a symbol name by appending every edge label
along a trie path into a `std::string`. A corrupt export trie can encode
an edge label whose terminator is far away in the trie data, making a
single label many megabytes long. Appending it requests an unbounded
allocation, which can crash lldb while parsing the symbol table.

Reject a trie whose assembled name exceeds a sane bound (1 MiB) as
corrupt data, the same way an unterminated edge label is already
handled. Add a unit test covering an oversized edge label.

Assisted-by: Claude
DeltaFile
+15-0lldb/unittests/ObjectFile/MachO/MachOTrieTest.cpp
+10-0lldb/source/Plugins/ObjectFile/Mach-O/MachOTrie.cpp
+25-02 files

FreeBSD/src b61ab2dshare/man/man5 src.conf.5, share/mk src.opts.mk

src.opts.mk: enable OPENSSL_KTLS by default on riscv64

1e649491b8567151270095fda3bce8faea394952 enabled KERN_TLS in
riscv/conf/GENERIC, but didn't enable OPENSSL_KTLS.

This passes all testcases in the sys/kern/ssl_sendfile suite and
fixes CI failures seen here:
https://ci.freebsd.org/job/FreeBSD-main-riscv64-test/16606/testReport/sys.kern/ssl_sendfile/

PR:     293810
Fixes:  1e649491b8567151270095fda3bce8faea394952
MFC after:      3 days
Reviewed by:    gallatin, ngie
Differential Revision:  https://reviews.freebsd.org/D57316
DeltaFile
+3-3share/man/man5/src.conf.5
+2-2share/mk/src.opts.mk
+5-52 files

FreeBSD/src 1e25cdalib/libc/riscv gd_qnan.h

libc: fix strtold NaN representation on riscv

Regenerate gd_qnan.h on riscv using the qnan.c
config tool found in contrib/gdtoa.

This fixes the following tests in CI:
lib/libc/stdio/scanfloat_test:infinities_and_nans
lib/libc/stdlib/strtod_test:strtold_nan

Reviewed by:    jrtc27
MFC after:      3 days
Differential Revision:  https://reviews.freebsd.org/D57405
DeltaFile
+3-3lib/libc/riscv/gd_qnan.h
+3-31 files

FreeBSD/src 9f2a38clib/libc/tests/secure fortify_uio_test.c generate-fortify-tests.lua

libc/fortify_uio_test: replace stdin in base readv tests

This fixes the readv_before_end and preadv_before_end test
timeout failures on riscv.

See https://ci.freebsd.org/job/FreeBSD-main-riscv64-test/lastCompletedBuild/testReport/lib.libc.secure/fortify_uio_test/readv_before_end/

Reviewed by:    kevans, emaste
MFC after:      3 days
Differential Revision:  https://reviews.freebsd.org/D57420
DeltaFile
+18-0lib/libc/tests/secure/fortify_uio_test.c
+2-0lib/libc/tests/secure/generate-fortify-tests.lua
+20-02 files

LLVM/project be72f36clang/docs SanitizerSpecialCaseList.rst ReleaseNotes.rst, llvm/lib/Support SpecialCaseList.cpp

[SpecialCaseList] Add backward compatible dot-slash handling

This PR is preparation for:
* https://github.com/llvm/llvm-project/pull/167283

The new behavior is controlled by the `Version` field in the special
case list file.

- Version 1 and 2: Path is matched as-is, regardless of presence of "./".
- Version 3, 5 and higher: Paths with leading dot-slash are canonicalized
  to paths without dot-slash before matching. This means that a rule
  like `src=./foo` will never match, and `src=foo` will match both
  `foo` and `./foo`. (Version 3 never became default but has this behavior).
- Version 4: Transitionary version. Paths are matched both ways
  (canonicalized and non-canonicalized) to maintain backward compatibility.
  If a match only works with the old behavior (non-canonicalized), a warning
  is emitted.

This change allows for a gradual transition to the new behavior, while

    [6 lines not shown]
DeltaFile
+42-6llvm/lib/Support/SpecialCaseList.cpp
+46-1llvm/unittests/Support/SpecialCaseListTest.cpp
+21-0clang/docs/SanitizerSpecialCaseList.rst
+8-0clang/docs/ReleaseNotes.rst
+117-74 files

OpenBSD/ports OdGwqOldevel/sdl3 Makefile

   hidden dep on libinput-openbsd, found by naddy@
VersionDeltaFile
1.8+2-1devel/sdl3/Makefile
+2-11 files

LLVM/project d5a1860lldb/docs python_api_enums.md CMakeLists.txt, lldb/scripts gen-python-api-enums.py

[lldb][docs] Generate the Python API enums page from headers (#202780)

The "Python API enumerators and constants" page was added by
3cae8b33297b as an explicit stop-gap: its contents were grepped out of
the headers by hand, with the few available doc strings copied over
manually. That commit noted the real fix would be a tool that parses the
enum/constant headers and emits the page automatically.

Being hand-maintained, the page drifted badly out of sync. By now it was
missing 19 enums and 60+ enumerators, still documented three values that
no longer exist, and carried stale descriptions.

Add gen-python-api-enums.py, which parses lldb-enumerations.h and
lldb-defines.h and emits the page at build time. It is pulled into
python_api_enums.md via the {build-include} directive, the same
mechanism already used for the generated settings page, so the page can
stay in sync with the source.

Enums from the separately generated SBLanguages.h (eLanguageName*) are

    [2 lines not shown]
DeltaFile
+5-3,279lldb/docs/python_api_enums.md
+310-0lldb/scripts/gen-python-api-enums.py
+20-1lldb/docs/CMakeLists.txt
+335-3,2803 files

LLVM/project ee6f14alibcxx/include optional, libcxx/test/std/utilities/optional/optional.object/optional.object.ctor U.pass.cpp

[libc++] Strengthen optional value constructor noexcept

The standard does not require `optional<T>(U&&)` to be potentially throwing; it simply does not specify noexcept for the primary `optional<T>` converting constructor. Standard library implementations are permitted [[res.on.exception.handling]/5](https://eel.is/c++draft/res.on.exception.handling#5) to strengthen exception specifications for non-virtual library functions, as long as the strengthened specification is correct.

GNU libstdc++ already does this:
https://github.com/gcc-mirror/gcc/blob/master/libstdc%2B%2B-v3/include/std/optional#L911-L913
https://github.com/gcc-mirror/gcc/blob/master/libstdc%2B%2B-v3/include/std/optional#L962-L974

The existing libc++ code only added noexcept for the C++26 `optional<T&>` case, guarded by `is_lvalue_reference_v<_Tp>`. It is safe to remove that gate and use the general condition instead:
```
noexcept(is_nothrow_constructible_v<_Tp, _Up>)
```

For `optional<T&>`, this still becomes the intended reference-construction check. For ordinary `optional<T>`, it correctly reflects whether constructing `T` from `U` can throw. The constructor only forwards into the contained object construction and updates optional bookkeeping, so if `T` is nothrow-constructible from `U`, the optional construction is also nothrow.
DeltaFile
+21-0libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/U.pass.cpp
+5-12libcxx/include/optional
+26-122 files

LLVM/project 5a605efclang/docs SanitizerSpecialCaseList.rst ReleaseNotes.rst, llvm/lib/Support SpecialCaseList.cpp

[𝘀𝗽𝗿] initial version

Created using spr 1.3.7
DeltaFile
+46-1llvm/unittests/Support/SpecialCaseListTest.cpp
+30-6llvm/lib/Support/SpecialCaseList.cpp
+21-0clang/docs/SanitizerSpecialCaseList.rst
+8-0clang/docs/ReleaseNotes.rst
+105-74 files

LLVM/project 4b5f74bflang/lib/Semantics resolve-names.cpp, flang/test/Semantics/OpenMP declare-target-resolve.f90 declare-target-symbols.f90

[flang][OpenMP] Implicit declarations of procedures in DECLARE_TARGET (#201935)

This replaces commit 8f5df8891840b, since it was rejecting the following
case:
```
  function baz(a)
    !$omp declare target to(baz)
    real, intent(in) :: a
    baz = a
  end

  program main
    !$omp declare target(baz)
    integer, save :: baz        ! error: 'baz' is already declared
  end
```
Instead of flagging an error, the 'baz' in the directive should be
resolved to the explicitly declared variable.


    [26 lines not shown]
DeltaFile
+149-87flang/lib/Semantics/resolve-names.cpp
+94-0flang/test/Semantics/OpenMP/declare-target-resolve.f90
+35-0flang/test/Semantics/OpenMP/declare-target-symbols.f90
+4-4flang/test/Semantics/OpenMP/declare-target08.f90
+282-914 files

LLVM/project c8378f4clang/docs SanitizerSpecialCaseList.rst ReleaseNotes.rst, llvm/lib/Support SpecialCaseList.cpp

[𝘀𝗽𝗿] initial version

Created using spr 1.3.7
DeltaFile
+46-1llvm/unittests/Support/SpecialCaseListTest.cpp
+30-6llvm/lib/Support/SpecialCaseList.cpp
+21-0clang/docs/SanitizerSpecialCaseList.rst
+8-0clang/docs/ReleaseNotes.rst
+105-74 files

FreeBSD/ports 15950a1mail/archiveopteryx Makefile pkg-plist

mail/archiveopteryx: Fix pkg-plist
DeltaFile
+1-1mail/archiveopteryx/Makefile
+1-0mail/archiveopteryx/pkg-plist
+2-12 files

OpenBSD/ports JkCCugQdevel/ocaml-menhir distinfo Makefile, devel/ocaml-menhir/pkg PLIST PFRAG.native

   update menhir to 20240715 for ocaml 5 support
VersionDeltaFile
1.16+14-0devel/ocaml-menhir/pkg/PLIST
1.13+2-2devel/ocaml-menhir/distinfo
1.7+4-0devel/ocaml-menhir/pkg/PFRAG.native
1.32+1-2devel/ocaml-menhir/Makefile
1.4+1-0devel/ocaml-menhir/pkg/PFRAG.dynlink-native
+22-45 files

OpenBSD/ports R1L97Xisysutils/findlib distinfo Makefile

   update findlib to 1.9.8 for ocaml 5 support

   ok avsm@ (MAINTAINER)
VersionDeltaFile
1.15+2-2sysutils/findlib/distinfo
1.51+1-2sysutils/findlib/Makefile
+3-42 files

OpenBSD/ports R2plxNKdevel/ocaml-ocamlbuild distinfo Makefile, devel/ocaml-ocamlbuild/patches patch-Makefile

   update ocamlbuild to 0.14.3 for ocaml 5 support
VersionDeltaFile
1.3+3-3devel/ocaml-ocamlbuild/patches/patch-Makefile
1.5+2-2devel/ocaml-ocamlbuild/distinfo
1.18+1-1devel/ocaml-ocamlbuild/Makefile
+6-63 files

OpenBSD/ports pdlmmPksecurity/gringotts Makefile, security/gringotts/patches patch-src_grg_entries_vis_c

   security/gringotts: use proper object type-casting macro to appease llvm22
VersionDeltaFile
1.1+12-0security/gringotts/patches/patch-src_grg_entries_vis_c
1.24+1-1security/gringotts/Makefile
+13-12 files

LLVM/project e9fbddflldb/include/lldb/API SBProcess.h, lldb/source/API SBProcess.cpp

[lldb] Expose SBProcess::IsLiveDebugSession() (#203111)

Expose the existing `Process::IsLiveDebugSession()` through the SB API
as `SBProcess::IsLiveDebugSession()`, letting clients distinguish a live
debuggee from a post-mortem session such as a core file or minidump. It
returns `false` when there is no underlying process, consistent with
other `SBProcess` query methods.
DeltaFile
+17-0lldb/test/API/python_api/process/TestProcessAPI.py
+9-0lldb/source/API/SBProcess.cpp
+9-0lldb/test/API/functionalities/postmortem/elf-core/TestLinuxCore.py
+9-0lldb/include/lldb/API/SBProcess.h
+44-04 files

LLVM/project ca42466llvm/lib/Target/AMDGPU AMDGPURegBankLegalizeRules.cpp, llvm/test/CodeGen/AMDGPU llvm.amdgcn.mfma.ll llvm.amdgcn.mfma.gfx90a.ll

AMDGPU/GlobalISel: RegBankLegalize rules for gfx90a/gfx942 MFMAs (#194076)

Add rules for gfx90a/gfx942 MFMA/SMFMAC intrinsics.

I see some regressions with imm splat tests and stores that could have
taken agprs. I will try to address those in a follow-up patch.
DeltaFile
+2,484-3llvm/test/CodeGen/AMDGPU/llvm.amdgcn.mfma.ll
+1,650-7llvm/test/CodeGen/AMDGPU/llvm.amdgcn.mfma.gfx90a.ll
+212-96llvm/test/CodeGen/AMDGPU/llvm.amdgcn.mfma.i8.ll
+107-174llvm/test/CodeGen/AMDGPU/GlobalISel/regbankselect-amdgcn.mfma.gfx942.mir
+71-114llvm/test/CodeGen/AMDGPU/GlobalISel/regbankselect-amdgcn.mfma.gfx90a.mir
+35-2llvm/lib/Target/AMDGPU/AMDGPURegBankLegalizeRules.cpp
+4,559-39611 files not shown
+4,595-40917 files

LLVM/project d9e7704mlir/test/Integration/GPU/ROCM lit.local.cfg

[mlir][ROCM] Disable integration tests on shared library builds (#203114)

Recent ROCm builds cause conflicts when loading the HIP library into
mlir-rocm-runner when LLVM is built as a shared library (this manifests
as duplicate command-line options).

Fixing this properly would require dlopen()-ing the HIP libraries or
some other such workaround, which can be done later.

For now, disable these tests on such builds.
DeltaFile
+6-0mlir/test/Integration/GPU/ROCM/lit.local.cfg
+6-01 files

LLVM/project 8dfa78bllvm/lib/Target/AMDGPU AMDGPURewriteAGPRCopyMFMA.cpp

Added braces to conform to AMDGPU coding style.
DeltaFile
+2-1llvm/lib/Target/AMDGPU/AMDGPURewriteAGPRCopyMFMA.cpp
+2-11 files

LLVM/project 127a4c1lldb/source/Plugins/Disassembler/LLVMC DisassemblerLLVMC.cpp DisassemblerLLVMC.h, lldb/source/Plugins/ObjectFile/ELF ObjectFileELF.cpp

[LLDB]  RISCV feature attribute support and allows overriding additional(default) feature (#147990)

Parse ELF attributes to automatically set disassembler features.
llvm-objdump calls ELFObjectFile::getFeatures, then turns that into a
cstr to pass to createMCSubtargetInfo.
The lldb disassembler builds features for various architectures manually
and adds in the value from the command line.
If this is empty, it uses the default. then it turns that into a cstr
and passes it to createMCSubtargetInfo.

For Hexagon and RISC-V, parse the attributes, set up features, add
anything else needed.
If this is empty, pick the default.
Then turn into a cstr and pass to createMCSubtargetInfo (via
MCDisasmInstance::Create).

This patch adds RISCV feature attribute support and allows overriding
additional(default) feature.


    [3 lines not shown]
DeltaFile
+103-20lldb/source/Plugins/Disassembler/LLVMC/DisassemblerLLVMC.cpp
+45-0lldb/test/Shell/Disassemble/TestDisassembleRISCVInstructions.test
+42-0lldb/unittests/Disassembler/RISCV/TestMCDisasmInstanceRISCV.cpp
+7-0lldb/source/Plugins/Disassembler/LLVMC/DisassemblerLLVMC.h
+4-0lldb/test/Shell/lit.cfg.py
+2-2lldb/source/Plugins/ObjectFile/ELF/ObjectFileELF.cpp
+203-222 files not shown
+205-238 files

LLVM/project 245186ellvm/include/llvm/Target/GlobalISel Combine.td, llvm/test/CodeGen/AArch64/GlobalISel combine-or-and-xor.ll combine-or-and-xor.mir

[GlobalISel] Add `or_and_xor_to_or` pattern from SelectionDAG (#201108)

This PR adds the `fold (or (and X, (xor Y, -1)), Y) -> (or X, Y)`
pattern from SelectionDAG to GlobalISel.

---------

Co-authored-by: Matt Arsenault <arsenm2 at gmail.com>
DeltaFile
+213-0llvm/test/CodeGen/AArch64/GlobalISel/combine-or-and-xor.ll
+206-0llvm/test/CodeGen/AArch64/GlobalISel/combine-or-and-xor.mir
+40-1llvm/include/llvm/Target/GlobalISel/Combine.td
+459-13 files

NetBSD/src smWFDRSdoc 3RDPARTY CHANGES

   update m4
VersionDeltaFile
1.2216+5-5doc/3RDPARTY
1.3270+2-1doc/CHANGES
+7-62 files

LLVM/project 6d16aacllvm/test/CodeGen/AMDGPU rewrite-vgpr-mfma-to-agpr-spill-joint-dom-mir.mir

Dropped IR section instructions, removed IR references.
DeltaFile
+4-9llvm/test/CodeGen/AMDGPU/rewrite-vgpr-mfma-to-agpr-spill-joint-dom-mir.mir
+4-91 files

NetBSD/src Nct9WC7usr.bin/m4 eval.c gnum4.c, usr.bin/m4/lib ohash.c

   Sync m4 with OpenBSD
VersionDeltaFile
1.31+175-163usr.bin/m4/eval.c
1.1+331-0usr.bin/m4/lib/ohash.c
1.14+136-133usr.bin/m4/gnum4.c
1.52+100-116usr.bin/m4/main.c
1.18+101-91usr.bin/m4/mdef.h
1.14+89-25usr.bin/m4/look.c
+932-52824 files not shown
+1,106-60830 files

OpenBSD/ports 6FsfPUWnet/tailscale distinfo modules.inc, net/tailscale/patches patch-net_dns_manager_go

   Update to tailscale-1.98.5

   From Adriano Barbosa (maintainer)
VersionDeltaFile
1.66+178-126net/tailscale/distinfo
1.40+63-45net/tailscale/modules.inc
1.69+1-1net/tailscale/Makefile
1.20+2-0net/tailscale/pkg/PLIST
1.3+0-0net/tailscale/patches/patch-net_dns_manager_go
+244-1725 files

NetBSD/src FDHaSH0external/bsd/file/dist configure aclocal.m4, external/bsd/file/dist/doc Makefile.in

   regen autoconf stuff.
VersionDeltaFile
1.30+187-403external/bsd/file/dist/configure
1.19+209-299external/bsd/file/dist/aclocal.m4
1.14+28-49external/bsd/file/dist/missing
1.24+24-44external/bsd/file/dist/Makefile.in
1.21+27-32external/bsd/file/dist/src/Makefile.in
1.18+5-53external/bsd/file/dist/doc/Makefile.in
+480-8806 files not shown
+530-98012 files

LLVM/project d757502llvm/test/CodeGen/AMDGPU amdgcn.bitcast.1024bit.ll amdgcn.bitcast.512bit.ll, llvm/test/CodeGen/AMDGPU/NextUseAnalysis spill-vreg-many-lanes.mir acyclic-770bb.mir

rebase

Created using spr 1.3.7
DeltaFile
+157,802-172,153llvm/test/CodeGen/AMDGPU/amdgcn.bitcast.1024bit.ll
+275,101-0llvm/test/CodeGen/AMDGPU/NextUseAnalysis/spill-vreg-many-lanes.mir
+144,679-0llvm/test/CodeGen/AMDGPU/NextUseAnalysis/acyclic-770bb.mir
+49,173-49,137llvm/test/CodeGen/AMDGPU/amdgcn.bitcast.512bit.ll
+42,349-42,348llvm/test/MC/AMDGPU/gfx8_asm_vop3.s
+41,419-41,418llvm/test/MC/AMDGPU/gfx7_asm_vop3.s
+710,523-305,05650,716 files not shown
+7,631,039-3,752,51550,722 files

LLVM/project 0d62bf3llvm/lib/Support SpecialCaseList.cpp

[NFC][SpecialCaseList] Introduce Matcher::matchInternal helper (#203097)

Extract the core matching logic (std::visit on the variant) from
Matcher::match
into a private Matcher::matchInternal helper method. This is a
preparation step
for implementing warning logic that will need to call the matching logic
multiple times.

Also make Matcher's M and Options member variables private as part of
this
refactoring.

Assisted-by: Gemini
DeltaFile
+8-3llvm/lib/Support/SpecialCaseList.cpp
+8-31 files