[CIR] Search the feature list once and assert on multiversioning
Review feedback on #215118.
funcAvxLevel walked the whole feature list once per name and was called
twice, so it now makes a single pass.
It also has no equivalent of the `hasAttr<TargetAttr>()` gate classic
uses. A multiversioned function's feature list carries the same `+avx`
entry a plain `target` attribute produces, so this would take a raised
level where classic keeps the module's. CIRGen rejects multiversioning
today, so an assert on opFuncMultiVersioning marks the gate that has to
go in when that changes.
Comments naming a function or file in classic CodeGen came out. They go
stale when that code moves, and one already had, claiming a declaration
carries no features. x86TargetAttrAvx is now allowsX86TargetAttrAvx,
after the function that produces it.
Assisted-by: Cursor / claude-opus-5
devel/tevent: clamp far-future poll(2) timeout to avoid a busy-loop
When a timer is scheduled far enough in the future,
tvalp->tv_sec * 1000 overflows the int millisecond value that
poll_event_loop_poll() passes to poll(2). poll(2) then fails with
EINVAL and tevent spins in a busy-loop instead of sleeping. Clamp
the computed timeout to INT_MAX in that case.
PR: 297401
Approved by: 0mp (samba)
Sponsored by: Netzkommune GmbH
HashingTest.cpp: Prune `StructWithHashBuilderAndHashValueSupport::hash_value()` [-Wunused-template] (#215561)
The customized version of `hash_value()` won't use it.
[LLVMOffload] Fix LLVMOffloadKernel dylib dependency (#215902)
LLVMOffloadKernel was linking Offload through LINK_COMPONENTS, which
does not preserve the required LLVMOffload target dependency in dylib
builds. Match the other `offload/` libraries by selecting LLVM deps via
`LLVM_LINK_LLVM_DYLIB`, then link LLVMOffload explicitly.
thunderbolt: Reset controllers
Reset routine for both v1.0 and v2.0 routes, chosen depending on version
reported in caps.
Reviewed by: imp
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D49452
[clang][SYCL] Enable GPURelocatableDeviceCode and predefine __CLANG_RDC__ (#215437)
SYCL device compilation defaults to RDC. The driver now passes -fgpu-rdc
to the SYCL device -cc1 invocation by default (disabled with
-fno-gpu-rdc), setting the GPURelocatableDeviceCode LangOpt.
Expose RDC to source code for SYCL through the `__CLANG_RDC__`
predefined macro, similar to CUDA and HIP.
---------
Co-authored-by: Claude <noreply at anthropic.com>
Co-authored-by: Nick Sarnie <nick.sarnie at intel.com>
[CIR] Test the atomic wrapper's rejection at the pass level
CIRGen wraps an atomic narrower than its lock-free size in an anonymous padded
record whose trailing member is pad. The x86_64 classifier rejects padded
records. That rejection is pass behavior, so it belongs with the other cases
in x86_64-aggregate-nyi.cir rather than in a driver test of its own.
It also covers the anonymous record path, which every case in that file had
missed.
Assisted-by: Cursor / claude-opus-5
[libc++] Stabilize the LNT machines we are going to generate data for (#215583)
Now that the test suite has the necessary fixes to go back in time
reasonably far, update it and update the names of the machines to
version them.
As a drive-by, make the expression we use to target macOS runners
consistent with what we use in the pre-commit CI jobs.
18333 stmf_sbd: get/load PP data ioctls must validate buffer sizes
Reviewed by: Bill Sommerfeld <sommerfeld at hamachi.org>
Reviewed by: Vitaliy Gusev <gusev.vitaliy at gmail.com>
Approved by: Gordon Ross <gordon.w.ross at gmail.com>
NAS-142156 / 27.0.0-BETA.1 / Restore global logging state mutated by the logger tests (#19497)
## Problem
`test_app_metadata_generate::test_broken_app_is_logged` has failed every
incremental build since it was added, while passing when its file is run
on its own. `run_unit_tests.py` puts both unit test directories through
`pytest.main()` in a single interpreter, and
`test__middleware_logger_paths` calls `setup_syslog_handler()` for every
entry in `ALL_LOG_FILES` — which attaches a queue handler and sets
`propagate = False`, neither of which it can undo. By the time the
middleware suite runs, `app_lifecycle` no longer propagates to root,
which is the only place `caplog` installs its handler, so `caplog.text`
comes back empty. `ALL_LOG_FILES` also carries an unnamed entry, so one
of those leaked handlers lands on the root logger and every record from
the second run was being shipped off to the real middlewared log.
## Solution
Added an autouse fixture to the logger tests that snapshots propagation
up front and, on teardown, restores it and strips any queue handler the
[11 lines not shown]
[clang][Sema] Check exported default constructors in nested classes (#214275)
Teach Clang to check exported default constructors declared in nested
classes. This prepares Microsoft ABI constructor closures for
non-dependent nested classes before CodeGen.
This fixes a failure seen when compiling PyTorch on Windows. An exported
nested
class with defaults for every constructor parameter caused Clang to emit
its
constructor closure without cached default arguments and assert in
MicrosoftCXXABI.cpp.
Assisted by: GPT-5.6 Sol
[libc++] Align and avoid inlining benchmark functions (#213938)
We're currently having the problem that clearly unrelated benchmarks
sometimes change performance in significant ways. This is an attempt to
mitigate that issue by aligning the functions and thus making it less
likely that unrelated changes cause changes in cache behaviour.
Co-authored-by: Louis Dionne <ldionne.2 at gmail.com>