HardenedBSD/ports a7aa281 — misc/codex/files patch-codex-rs_core_tests_suite_remote__env.rs patch-codex-rs_Cargo.lock, security/boringssl Makefile

Merge branch 'freebsd/main' into hardenedbsd/main
DeltaFile
+44-0security/boringssl/files/extra-patch-ssl_span__test.cc
+31-0security/boringssl/files/extra-patch-crypto_bytestring_bytestring__test.cc
+11-11misc/codex/files/patch-codex-rs_Cargo.lock
+7-2security/boringssl/Makefile
+4-4misc/codex/files/patch-codex-rs_core_tests_suite_remote__env.rs
+3-3textproc/tgrep/distinfo
+100-2019 files not shown
+136-5425 files

LLVM/project 7a1da19 — clang/lib/AST/ByteCode Compiler.cpp

[clang][bytecode] Only implicitly destroy locals for EvalEmitter (#248064)

For bytecode, we want to avoid the double destroy ops. We need to call
`destroyLocals()` so we can use the return value. When evaluating
directly, we need to destroy locals in the destructor too so we don't
leak memory when a one of our visit functions returns an error early.
DeltaFile
+13-6clang/lib/AST/ByteCode/Compiler.cpp
+13-61 files

LLVM/project 6aac142 — mlir/include/mlir/Dialect/XeGPU/Utils XeGPUUtils.h, mlir/lib/Dialect/XeGPU/Transforms XeGPULayoutImpl.cpp

[MLIR][XeGPU] Fix shape_cast layout inference when a split dim is followed by others (#245127)

For a shape_cast that splits source dims, inferShapeCastSourceLayout
collapsed the result dim groups from first to last. Collapsing a group
shifts the dim indices of the groups after it. For 32x64 -> 8x4x64, the
groups are [[0, 1], [2]]. After [0, 1] is collapsed, [2] is out of
bounds and collapseDims crashes.

The PR fix it by collapsing the groups from the last one, so earlier
groups keep their indices.

assisted-by-claude
.

---------

Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
DeltaFile
+23-0mlir/test/Dialect/XeGPU/propagate-layout-subgroup.mlir
+5-3mlir/lib/Dialect/XeGPU/Transforms/XeGPULayoutImpl.cpp
+3-2mlir/lib/Dialect/XeGPU/Utils/XeGPUUtils.cpp
+3-0mlir/include/mlir/Dialect/XeGPU/Utils/XeGPUUtils.h
+34-54 files

LLVM/project 74e9294 — llvm/docs AMDGPUMemoryModel.md

Define synchronization scope and clamp scopes to execution scope

- Add a Synchronization Scope section defining syncscope and syncscope instance.
- Clamp syncscope and A/V scope to execution scope when specified smaller.
- Clarify default A/V scope for synchronizing vs. other A/V operations.
- Simplify the Inclusive Scopes wording to refer to any two operations.

Assisted-by: AI
DeltaFile
+31-11llvm/docs/AMDGPUMemoryModel.md
+31-111 files

LLVM/project 0bde66c — utils/bazel/llvm-project-overlay/llvm BUILD.bazel

[Bazel] Fixes 4a325bc (#248342)

This fixes 4a325bc9c4c26ab7a3a653551df2724a5ac277cb (#244507).

Buildkite error link:
https://buildkite.com/llvm-project/upstream-bazel/builds?commit=4a325bc9c4c26ab7a3a653551df2724a5ac277cb

Co-authored-by: Google Bazel Bot <google-bazel-bot at google.com>
DeltaFile
+1-1utils/bazel/llvm-project-overlay/llvm/BUILD.bazel
+1-11 files

LLVM/project 5832ee4 — lld/MachO MarkLive.cpp

[lld-macho] Pad markLive worklist shards and move stack on idle

Avoid false cache-line sharing on Worklist's 16-byte header across
threads by aligning each nextLevel/level shard to 128 bytes. In drain(),
move the worker's stack directly into its empty nextLevel shard and
return once anyWorkerIdle is observed. Also drop an outdated sentence in
drain()'s comment.
DeltaFile
+13-6lld/MachO/MarkLive.cpp
+13-61 files

LLVM/project d98efb6 — compiler-rt/lib/asan asan_allocator.cpp, compiler-rt/lib/sanitizer_common sanitizer_allocator_secondary.h

[asan] Find the block of a large chunk without scanning all large chunks (#243675)

When a large chunk leaves the quarantine, `GetBlockBegin()` scans all
large blocks under a lock, so programs that hold thousands of them slow
down. These blocks are page aligned. Look for a `LargeChunkHeader` at
the start of the chunk header's page first, and scan only if it doesn't
point back at the chunk.

x86_64 Linux CPU time: about -30% for a `malloc(132K)`/`free` loop with
10,000 blocks live, -3.5% for a synthetic numpy script with 20,000
arrays. No change on llvm-test-suite or ASan clang.

`GetBlockBegin()`'s two header CHECKs are repeated in `Deallocate()`,
for all sanitizers. A `free()` with a forged `LargeChunkHeader` now
crashes instead of returning silently.

Assisted-by: Claude. I have reviewed every line of this PR.
DeltaFile
+79-0compiler-rt/test/asan/TestCases/Posix/large_chunk_recycle.cpp
+24-1compiler-rt/lib/asan/asan_allocator.cpp
+2-0compiler-rt/lib/sanitizer_common/sanitizer_allocator_secondary.h
+105-13 files

FreeBSD/doc ec99002 — website/content/en/releases/14.4R errata.adoc, website/content/en/releases/14.5R errata.adoc

Add erratum affecting 14.4R, 14.5R and 15.1R

FreeBSD-EN-26:33.tcp affects all supported releases
DeltaFile
+1-0website/content/en/releases/15.1R/errata.adoc
+1-0website/content/en/releases/14.5R/errata.adoc
+1-0website/content/en/releases/14.4R/errata.adoc
+3-03 files

FreeBSD/doc 1ca567d — website/content/en/releases/14.4R errata.adoc, website/content/en/releases/14.5R errata.adoc

Add security advisories affecting 14.4R, 14.5R and 15.1R

FreeBSD-SA-26:95.arm64 affects 15.1R
FreeBSD-SA-26:96.krb5 affects 15.1R
FreeBSD-SA-26:97.pam_xdg affects all supported releases
FreeBSD-SA-26:98.bsnmp affects all supported releases
FreeBSD-SA-26:99.linux affects all supported releases
FreeBSD-SA-26:100.unix affects 15.1R
FreeBSD-SA-26:101.setrlimit affects all supported releases
FreeBSD-SA-26:102.socket affects all supported releases
FreeBSD-SA-26:103.ptrace affects all supported releases
FreeBSD-SA-26:104.proc affects all supported releases
DeltaFile
+5-0website/content/en/releases/15.1R/errata.adoc
+3-0website/content/en/releases/14.5R/errata.adoc
+3-0website/content/en/releases/14.4R/errata.adoc
+11-03 files

LLVM/project 769596d — llvm/lib/Transforms/Utils CloneFunction.cpp, llvm/test/Transforms/Inline memprof_inline_invoke.ll

CloneFunction: Check invokes for memprof metadata when pruning

The pruning cloner reports whether the cloned code contains !memprof
or !callsite metadata, but only looked at non-terminator calls. The
inliner uses this to decide whether to strip the metadata from the
copied calls if the original call site has no !callsite metadata.

As a result, the metadata was not stripped from an inlined invoke
unless the callee also had a call with the metadata.

Assisted-by: Claude
DeltaFile
+97-0llvm/test/Transforms/Inline/memprof_inline_invoke.ll
+11-4llvm/lib/Transforms/Utils/CloneFunction.cpp
+108-42 files

LLVM/project 4a325bc — llvm/include/llvm/Target/Hexagon HexagonRelocation.h, llvm/lib/ExecutionEngine/RuntimeDyld RuntimeDyldELF.cpp

[Hexagon] Add relocation application helpers and use them in RuntimeDyld (#244507)

Add target-side helpers for applying ELF relocations to Hexagon
instruction encodings. Hexagon instruction operands may occupy
non-contiguous bit fields, so the helpers use the scalar
instruction-encoding table and the Hexagon ABI relocation descriptions
to scatter relocated values into the correct bits.

Expose a C-linkage API in llvm/Target/Hexagon/HexagonRelocation.h so
that RuntimeDyld and other Hexagon toolchain components do not depend on
private declarations:

* LLVMHexagonApplyRelocation: apply a relocation to an instruction.
* LLVMHexagonGetRelocationInfo: query the ABI properties of a relocation
(effective bits, bit mask, alignment, shift, signedness and whether
range and alignment are verified) through the LLVMHexagonRelocInfo
struct.
* LLVMHexagonVerifyRange, LLVMHexagonVerifyAlignment and
LLVMHexagonIsTruncated: relocation validation checks for diagnostics.

    [34 lines not shown]
DeltaFile
+2,844-0llvm/lib/Target/Hexagon/Utils/HexagonDepMask.h
+1,162-0llvm/lib/Target/Hexagon/Utils/HexagonRelocationInfo.h
+233-0llvm/lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
+177-0llvm/lib/Target/Hexagon/Utils/HexagonFindMask.cpp
+80-0llvm/include/llvm/Target/Hexagon/HexagonRelocation.h
+78-0llvm/unittests/Target/Hexagon/HexagonRelocationTest.cpp
+4,574-016 files not shown
+4,894-022 files

LLVM/project ed236a2 — llvm/utils/mlgo-utils/IR2Vec generateTriplets.py

Address comments
DeltaFile
+2-2llvm/utils/mlgo-utils/IR2Vec/generateTriplets.py
+2-21 files

LLVM/project c17bec0 — clang/test/CodeGen sanitize-ignorelist-mainfile.c asan-new-pm.ll, llvm/include/llvm/IR RuntimeLibcalls.td

AddressSanitizer: Declare runtime functions with RuntimeLibcallsInfo

Declare the asan runtime functions with RuntimeLibcallsInfo, so they
get the signatures and attributes from the libcall definitions. The
ELF globals registration functions are only declared for ELF targets,
which are the only users.

It is now an error to run the pass for a target that does not provide
the asan runtime. Tests with no triple, or a triple without an OS, now
use a Linux triple.

The experiment report functions are only used by a hidden testing
option, so keep declaring them by name and drop their RuntimeLibcalls
entries.

The kind of hacky part of this is the pass is now reasoning directly
in terms of LibcallImpl, instead of looking up the LibcallImpl from
the Libcall. This is because at the moment non-codegen passes don't
have a simple way of using LibcallLoweringInfo. There arguably should

    [4 lines not shown]
DeltaFile
+89-64llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp
+38-37llvm/test/Instrumentation/AddressSanitizer/vector-load-store.ll
+7-15llvm/include/llvm/IR/RuntimeLibcalls.td
+15-0llvm/test/Instrumentation/AddressSanitizer/unsupported-target.ll
+5-6clang/test/CodeGen/asan-new-pm.ll
+5-5clang/test/CodeGen/sanitize-ignorelist-mainfile.c
+159-12732 files not shown
+200-16938 files

LLVM/project ac6a36d — orc-rt/include CMakeLists.txt

[orc-rt] Install headers via a CMake file set. (#248335)

The public headers were installed via the PUBLIC_HEADER property, which
flattened the directory structure and dropped files with duplicate names
in different directories.

Switch orc-rt-headers to a HEADERS file set so that the directory
structure is preserved.

Assisted-by: claude
DeltaFile
+16-17orc-rt/include/CMakeLists.txt
+16-171 files

LLVM/project d43c083 — mlir/lib/Dialect/XeGPU/Transforms XeGPULayoutImpl.cpp, mlir/test/Dialect/XeGPU propagate-layout-inst-data.mlir

[mlir][XeGPU] Do not widen leading-dim inst_data for multi_reduction (#245106)

#240592 made layout propagation keep a reused slice parent's larger
inst_data on every non-reduced dim of a vector.multi_reduction source.
When that dim comes before the last two, blocking produces tiles such as
2x8x16. Lane-level distribution of multi_reduction only supports sources
whose leading dims are unit, so the blocked op then fails to legalize.

This PR keeps the parent's inst_data only on the last two dims. Leading
dims keep inst_data[i] = lane_layout[i] * lane_data[i], so they stay
unit.

assisted-by-claude

---------

Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
DeltaFile
+19-0mlir/test/Dialect/XeGPU/propagate-layout-inst-data.mlir
+9-3mlir/lib/Dialect/XeGPU/Transforms/XeGPULayoutImpl.cpp
+28-32 files

LLVM/project 3b2bd06 — clang/docs ReleaseNotes.md, clang/lib/Analysis UnsafeBufferUsage.cpp

[-Wunsafe-buffer-usage] Allow safe `memset(&x, val, sizeof(T))` calls (#247816)

`-Wunsafe-buffer-usage` currently treats `memset(&x, val, sizeof(x))` as
safe (via `isUnsafeMemset`), but warns on `memset(&x, val, sizeof(T))`
even when `x` has type T. This causes the checker to flag glibc's
`CPU_ZERO(&cpuset)` macro (which expands to `__builtin_memset(&cpuset,
'\0', sizeof(cpu_set_t))`)as unsafe.

This patch updates `isUnsafeMemset` to also consider `memset(&x, val,
sizeof(T))` safe when `x` is a `DeclRefExpr` whose type matches `T`.

---
*Disclosure: AI assistance was used in the development and
implementation of this change.*
DeltaFile
+108-2clang/test/SemaCXX/warn-unsafe-buffer-usage-libc-functions.cpp
+26-12clang/lib/Analysis/UnsafeBufferUsage.cpp
+5-0clang/docs/ReleaseNotes.md
+139-143 files

LLVM/project 2349d7f — llvm/lib/Target/X86 X86Subtarget.cpp

[spr] update

Created using spr 2.0.0-beta.2
DeltaFile
+2-3llvm/lib/Target/X86/X86Subtarget.cpp
+2-31 files

LLVM/project bbcc4ed — llvm/lib/Target/X86 X86ISelLoweringCall.cpp X86Subtarget.cpp, llvm/test/CodeGen/X86 ifunc-pic-i386.ll

[spr] update

Created using spr 2.0.0-beta.2
DeltaFile
+295-0llvm/test/CodeGen/X86/ifunc-pic-i386.ll
+11-1llvm/lib/Target/X86/X86Subtarget.cpp
+7-4llvm/lib/Target/X86/X86ISelLoweringCall.cpp
+313-53 files

LLVM/project 67545a8 — llvm/test/CodeGen/X86 ifunc-i386.ll

[test][X86] Precommit tests for 32-bit ELF PIC local IFUNCs (#248322)

Add codegen tests for calls, tail calls, musttail calls, and address
materialization of internal, hidden, and dso_local IFUNCs on i386 ELF.

The test covers the pic and static relocation models with SelectionDAG,
FastISel, and GlobalISel. The checks record the current output, where
PIC code references these IFUNCs with R_386_PC32 and R_386_GOTOFF.

Needed by #248318.

Assisted-by: Gemini
DeltaFile
+439-0llvm/test/CodeGen/X86/ifunc-i386.ll
+439-01 files

LLVM/project 788f0f2 — llvm/lib/Transforms/Vectorize/SLPVectorizer SLPTree.cpp

fixing undef issue
DeltaFile
+1-1llvm/lib/Transforms/Vectorize/SLPVectorizer/SLPTree.cpp
+1-11 files

LLVM/project 4e9dcc6 — clang/include/clang/CIR/Dialect/IR CIRTypes.td CIRDialectBytecode.td, clang/lib/CIR/Dialect/IR CIRDialectBytecode.cpp CIRTypes.cpp

[CIR] Add bytecode encodings for struct and union types (#247883)

Struct and union types were the last CIR types stored as their printed
text in bytecode. The printed form of a record expands every record it
reaches that has not been printed yet, so the text grows with the depth
of nesting and dominates CIR bytecode for C++.

A named record can refer to itself, so the reader creates it incomplete
and publishes it with tryStartCyclicRead (#229910) before reading its
members. Anonymous records cannot refer to themselves and are built once
their members are read.

Bytecode output for two of the CIR codegen TUs (-fclangir -emit-cir -c
on preprocessed sources, same binaries):
```
  CIRGenModule.cpp:  7.3 GB, 4m41s, 10 GB RSS -> 4.5 MB, 19s, 1.2 GB RSS
  CIRGenExprCXX.cpp: 3.9 GB, 2m11s,  6 GB RSS -> 2.0 MB, 12s, 0.9 GB RSS
```
For reference, their -O3 LLVM bitcode is 1.4 MB and 0.5 MB.
DeltaFile
+325-0clang/unittests/CIR/RecordBytecodeTest.cpp
+89-0clang/test/CIR/Bytecode/records.cir
+57-14clang/lib/CIR/Dialect/IR/CIRTypes.cpp
+66-0clang/lib/CIR/Dialect/IR/CIRDialectBytecode.cpp
+39-2clang/include/clang/CIR/Dialect/IR/CIRDialectBytecode.td
+35-0clang/include/clang/CIR/Dialect/IR/CIRTypes.td
+611-162 files not shown
+615-208 files

LLVM/project efe64ed — llvm/lib/Target/X86 X86Subtarget.cpp

[spr] update

Created using spr 2.0.0-beta.2
DeltaFile
+2-3llvm/lib/Target/X86/X86Subtarget.cpp
+2-31 files

LLVM/project da8f682 — clang/include/clang/CIR/Dialect/IR CIRTypes.td, clang/lib/CIR/Dialect/IR CIRTypes.cpp

[CIR] Add verifier enforcement of illegal SVE types (#247874)

This change updates the VectorType verifier to reject illegal SVE vector
sizes and updates the StructType, UnionType, and ArrayType verifiers to
reject scalable SVE vectors and svecount as elements/members.

Although LLVM IR represents tuples as a struct of SVE vectors, I intend
to add a dedicated tuple type in CIR.

Assisted-by: Cursor / various models
DeltaFile
+61-15clang/lib/CIR/Dialect/IR/CIRTypes.cpp
+63-9clang/test/CIR/IR/invalid-vector.cir
+49-2clang/test/CIR/IR/vector.cir
+44-0clang/test/CIR/IR/invalid-sizeless.cir
+25-7clang/include/clang/CIR/Dialect/IR/CIRTypes.td
+242-335 files

HardenedBSD/src 652a8a7 — release Makefile.vm

EC2: Use stream-optimized VMDK format

Once enabled on all of the branches, this will reduce bandwidth
consumption from uploading weekly snapshot builds from ~500 GB to
~100 GB, as well as significantly speeding up the process.

MFC after:      2 months
Sponsored by:   Amazon

(cherry picked from commit 34f2f57b836d9cec02130419f5272495860d4ddf)
DeltaFile
+1-1release/Makefile.vm
+1-11 files

FreeBSD/src 652a8a7 — release Makefile.vm

EC2: Use stream-optimized VMDK format

Once enabled on all of the branches, this will reduce bandwidth
consumption from uploading weekly snapshot builds from ~500 GB to
~100 GB, as well as significantly speeding up the process.

MFC after:      2 months
Sponsored by:   Amazon

(cherry picked from commit 34f2f57b836d9cec02130419f5272495860d4ddf)
DeltaFile
+1-1release/Makefile.vm
+1-11 files

LLVM/project d4c0607 — lld/MachO Symbols.h Target.h

[lld][MachO] Avoid redundant work in Writer::scanRelocations() (#246903)

During relocation scanning, `Writer::scanRelocations()` looks up
`target->getRelocAttrs(r.type)` up to three times per symbol relocation
(in `scanRelocations()`, `validateSymbolRelocation()`, and
`prepareSymbolRelocation()`), tests `r.referent` twice for symbol
referents, and makes an out-of-line call to `validateSymbolRelocation()`
on every symbol relocation even though it only rejects two rare
thread-local-variable cases.

Move `validateSymbolRelocation()` (whose only caller is
`Writer::scanRelocations()`) into `Writer.cpp`, split the rare TLV
validation logic into a `LLVM_ATTRIBUTE_NOINLINE` helper, and mark
`DylibSymbol` `final` so `dysym->isTlv()` avoids a virtual call on the
fast path. Fetch `RelocAttrs` once per relocation, pass it to
`validateSymbolRelocation()` and `prepareSymbolRelocation()`, hoist
loop-invariant `target->relocAttrs` and `config->emitChainedFixups`, and
dispatch on `r.referent` once for non-subtractor relocations.

Assisted by Gemini + Claude.
DeltaFile
+42-27lld/MachO/Writer.cpp
+6-1lld/MachO/Target.h
+1-1lld/MachO/Symbols.h
+49-293 files

LLVM/project 9bb26d4 — llvm/test/CodeGen/X86 ifunc-pic-i386.ll ifunc-i386.ll

[spr] update

Created using spr 2.0.0-beta.2
DeltaFile
+471-0llvm/test/CodeGen/X86/ifunc-i386.ll
+0-367llvm/test/CodeGen/X86/ifunc-pic-i386.ll
+471-3672 files

LLVM/project bc3525b — llvm/test/CodeGen/X86 ifunc-pic-i386.ll ifunc-i386.ll

[spr] update

Created using spr 2.0.0-beta.2
DeltaFile
+439-0llvm/test/CodeGen/X86/ifunc-i386.ll
+0-335llvm/test/CodeGen/X86/ifunc-pic-i386.ll
+439-3352 files

LLVM/project 7ee4267 — llvm/docs/CommandGuide llvm-ir2vec.md, llvm/test/tools/llvm-ir2vec triplets-max-arg-index.mir

[llvm-ir2vec] Add --max-arg-index to bound the Arg relations in triplets
DeltaFile
+38-0llvm/test/tools/llvm-ir2vec/triplets-max-arg-index.mir
+18-9llvm/utils/mlgo-utils/IR2Vec/generateTriplets.py
+5-19llvm/tools/llvm-ir2vec/lib/IRUtils/IRUtils.cpp
+17-0llvm/tools/llvm-ir2vec/lib/Common.h
+12-4llvm/docs/CommandGuide/llvm-ir2vec.md
+11-0llvm/tools/llvm-ir2vec/llvm-ir2vec.cpp
+101-321 files not shown
+104-357 files

LLVM/project 9244a01 — llvm/docs/CommandGuide llvm-ir2vec.md, llvm/test/tools/llvm-ir2vec triplets-max-arg-index.ll

[llvm-ir2vec] Add --max-arg-index to bound the Arg relations in IR triplets
DeltaFile
+40-0llvm/test/tools/llvm-ir2vec/triplets-max-arg-index.ll
+18-3llvm/tools/llvm-ir2vec/lib/IRUtils/IRUtils.cpp
+4-1llvm/docs/CommandGuide/llvm-ir2vec.md
+62-43 files