compat/freebsd32: set uio_rw for trailer's uio in freebsd32_sendfile()
PR: 297516
Reported by: asomers
Fixes: dfad790c8cca ("sendfile: stop abusing kern_writev()")
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
netipsec/xform_ipcomp.c: fix sockaddr type set in ipcomp6_nonexp_encapcheck()
Noted and reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58646
PF_KEY socket: limit the length of copied socket address
for SADB_UPDATE op SADB_X_EXT_NEW_ADDRESS_SRC/DST extensions, by
checking the sa_len matching the address family requirements before
doing the copy.
Also convert KEY_SETSECASIDX() and KEY_SETSECSPIDX() to functions and
apply the sa_len clamping there.
See https://github.com/0xdeadbeefnetwork/pfkey-sadb-overflow
PR: 297264
Tested by: Wafa Hamzah <wafah at nvidia.com> (previous version)
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58646
kern/sys_process.c: make vmspace_rwmem() similar to io functions
In particular, if there were any bytes moved, and then vm_fault()
faulted, do not return an error, but report the short io instead.
PR: 297512
Reviewed by: markj
Tested by: Stéphane D'Alu <sdalu at sdalu.com>
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58838
kern/kern_proc.c: do not throw out read data in get_ps_strings()
Since vmspace_iop()/proc_readmem() might return -1 on error from
vmspace_rwmem(), account for this and stop reading but return already
accumulated data if any, instead of returning an error.
PR: 297512
Reported and tested by: Stéphane D'Alu <sdalu at sdalu.com>
Reviewed by: markj
Fixes: e1b0d051bbf7 ("proc: Allow to make proc_rwmem() operate on a consistent address space")
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D58838
www/{nginx,nginx-devel,freenginx}: 3rd-party modules management
Rename www/lua-stream-nginx-module to www/nginx-module-lua-stream
to follow the nginx-module-* naming scheme for dedicated 3rd-party
module ports and adjust the consumers. Relax the BUILD_DEPENDS to
an unversioned dependency while here, matching the LUA option.
While here, rename the internal NJS_QJS_CFLAGS variable to
_NJS_QJS_CFLAGS so it is no longer treated as an option helper.
Sponsored by: Netzkommune GmbH
Increase the default mlock limit from 64k to 256k
The current default has been unchanged for 14 years. Increase it to
keep pace with modern hardware and software. security/pinentry-gnome,
in particular, can sometimes need 112 kB.
PR: 297452
MFC after: 2 weeks
Sponsored by: ConnectWise
Reviewed by: cye, emaste
Differential Revision: https://reviews.freebsd.org/D58811
[CIR] Accept fixed-width vectors in x86_64 callconv lowering (#215118)
The CallConvLowering bridge rejects a vector in a parameter or return
position, so a function taking one fails the pass. It also never reads
the AVX level, which is what decides whether a vector wider than 128
bits reaches a register.
A vector is accepted now where the classifier and clang size it the same
way, which means a whole-byte element and a power-of-two width. Scalable
vectors and the other widths stay rejected. The module's AVX level comes
from the target ABI name, as `CodeGenModule` does. A classifier per
level lets a target attribute raise it for one function. An ABI older
than the rule pins every function back to the module's level. A direct
call takes its callee's level, and an indirect call the level of the
function containing it.
CIRGen records target features on a definition but not on a declaration,
so a declaration carrying the attribute is classified at the module's
level until [#214986](https://github.com/llvm/llvm-project/pull/214986)
[4 lines not shown]
[mlir] Add shouldPromoteIfSingleIteration option to loopUnrollByFactor (#215080)
Add a shouldPromoteIfSingleIteration parameter to loopUnrollByFactor to
control whether single-iteration loops are promoted during unrolling.
When set to false, the function skips calls to promoteIfSingleIteration
on the main loop, epilogue loop, and the unroll-factor-1 early-exit
path.
The parameter defaults to true to preserve existing behavior.
[lldb-dap][NFC] Use wildcard imports for test decorators (#216235)
Replace explicit imports `from ... import (a, b, c)` with wildcard
imports `from ... import *` for `lldbsuite.test.decorators`,
This lets downstream forks introduce extra decorators (e.g. to skip
tests on private configurations) without needing to patch each test's
import list.
[Related
discourse](https://discourse.llvm.org/t/do-we-want-to-tighten-up-imports-in-the-api-testcases/91557/3)
[AArch64][CostModel] Adjust the cost of pure partial add reductions. (#214723)
These reductions can lower to a [SU]ADALP rather than a widening add
pair, so using partial reductions becomes profitable for two-way
widening reduction loops such as (https://godbolt.org/z/v8vr9Pzqb):
```c
long sadalp(const int *a, long n) {
long s = 0;
for (long i = 0; i < n; i++)
s += (long)a[i];
return s;
}
```
[Clang][Sema] Fix an ICE where structured binding packs within a lambda were not added to the CapturingScopeInfo (#214716)
Fixed a bug where structured binding packs within a lambda were not
added to the `CapturingScopeInfo` during `ActOnDecompositionDeclarator`,
which also led to invalid expressions being considered for delayed
lambda diagnostics, when they should have been diagnosed immediately.
Fixes #214160
Signed-off-by: Baba Dan Constantin <babadany2999 at gmail.com>
www/code-server: Update to 4.132.0
Update to code-server 4.132.0, which bundles VS Code 1.132.0.
Changelog: https://github.com/coder/code-server/releases
Sponsored by: Netzkommune GmbH
CodeGen: Remove TargetOptions::FloatABIType
This is now fully replaced with the "float-abi" module flag.
If the module flag is not present, the default is computed
from the triple. Consumers are updated to read the module flag.
RuntimeLibraryAnalysis now defers analysis until run() on a Module,
instead of during the pass constructor as before. This requires copying
all of the remaining relevant TargetOptions so they are available
when the module is seen.
Unfortunately, ARM still depends on TargetOptions for determining
the float-abi. -target-abi=aapcs16 still changes the default float-abi,
but an explicit module flag wins.
Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
CodeGen: Synthesize "float-abi" module flag from -float-abi
Avoid annoying test updates when the corresponding TargetOptions
field is removed. Make the -float-abi llc/opt option a lit test
convenience that records the floating-point ABI in the IR,
mirroring how -mcpu/-mattr are recorded as function attributes.
Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
lli: Record the host triple on triple-less modules (#216132)
The JIT compiles for the host, but modules without a target triple kept
an empty triple, which module-triple-based analyses (e.g. runtime
libcall selection) cannot resolve. Set the resolved JIT triple on the
module. This defends against jit test regressions when
RuntimeLibraryInfo
starts getting computed from the module instead of TargetOptions.
Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
[AMDGPU] Fix performFMACombine FDOT2 fold for subnormal handling (#205101)
The fold from v_fma_mix_f32 pairs to v_dot2_f32_f16/v_dot2c_f32_f16
was gated only on fp-contract flags, ignoring how each instruction
handles f16 subnormal inputs under different denormal modes.
Hardware testing across multiple GPU generations shows that gfx90a
(CDNA2) is the sole outlier: v_dot2c unconditionally flushes f16
subnormal inputs to zero in all MODE configurations, while v_fma_mix_f32
preserves them when ieee=1 (the default compute kernel mode). All other
tested GPUs with dot2 instruction do not flush f16 subnormal inputs.
Add GCNSubtarget::dot2UnconditionalFlush() to capture this hardware
quirk.
Gate the fold on the function's f32 denormal mode:
- dot2UnconditionalFlush(): allow fold only when f32 denorm =
PreserveSign, so both instructions flush f16 subnormals.
- All other GPUs: allow fold only when f32 denorm = IEEE, so both
instructions preserve f16 subnormals. Dynamic mode is also rejected
[9 lines not shown]