[clang-tidy] Fix trailing semicolon and lost comment in readability-use-std-min-max (#208782)
Fix two bugs in readability-use-std-min-max when the if body has no
braces.
For brace-less if bodies, If->getEndLoc() points to the expression end
rather than the trailing semicolon, truncating replacements and losing
comments. We find the semicolon via findNextToken and extend the range
consistent with compound statement logic.
Before:
if (n < -1) n = -1 ; -> n = std::max(n, -1); ;
if (n > 1) n = 1/*comment*/; -> n = std::min(n, 1);;
After:
if (n < -1) n = -1 ; -> n = std::max(n, -1);
if (n > 1) n = 1/*comment*/; -> n = std::min(n, 1); /*comment*/
Fixes #208708.
AI Usage: This patch is AI-assisted, reviewed and verified by me.
[AMDGPU] Use SubtargetPredicates for the f32/f16 -> fp8/bf8 conversions (#213383)
The follow-up #212888 left for the other direction. HasCvtFP8SDWASrcSel
and HasCvtFP8ByteSel replace isGFX940Plus and isGFX11Plus on the f32 ->
fp8/bf8 conversions, which split by the same encoding characteristic, so
the two feature descriptions become direction-neutral. The f16 ->
fp8/bf8 conversions had no feature at all, so add
FeatureF16FP8ConversionInsts, the mirror of the existing
FeatureFP8F16ConversionInsts, and use it in place of isGFX1250Plus.
Assisted-By: Claude Opus 5
vfs_mountroot: unmute console in interactive prompt
If boot_mute is set the system appears to hang during the mountroot
prompt. Temporarily unmute the console so the prompt is visible.
Reviewed by: kib
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D58549
[libc++] Implement LWG4169: `std::atomic<T>`'s default constructor should be constrained (#131950)
Drive-by: Rename `constexpr_noexcept.compile.pass.cpp` to
`ctor.default.pass.cpp` as test coverage is added to it, and compile and
run it in all modes.
ixl: enforce the assigned VF MAC address
When allow-set-mac is disabled, the MAC filter validation condition
rejects the assigned VF unicast address while allowing any different
unicast address. The equality test was accidentally inverted when this
code moved to the boolean address helper.
Accept multicast and the assigned unicast address, and reject other
unicast addresses as intended.
Fixes: 7d4dceec1030 ("ixl(4): Fix VLAN HW filtering")
MFC after: 3 days
[MLIR][CMake] Extend MLIRIR PCH reuse to transitive dependants
llvm_update_pch() only offers a PCH to targets that name the defining
library as a *direct* dependency, because across LLVM subprojects a
transitively reused PCH drags in unrelated headers and causes name
collisions. Within MLIR that concern is much weaker: mlir/IR/pch.h holds
MLIR core headers that essentially every MLIR library includes anyway.
Add mlir_reuse_ir_pch(), which offers MLIRIR's PCH to any target that
actually reaches MLIRIR through its link graph. The reachability check
matters: a PCH containing MLIR IR headers emits out-of-line symbols that
only libMLIRIR provides, so handing it to a Support-only target such as
tblgen-lsp-server breaks the link.
The helper is called from add_mlir_library() and add_mlir_tool(), and
again from mlir_target_link_libraries(), where most tests, unittests and
libMLIR.so-avoiding libraries actually attach their MLIR dependencies. It
is idempotent and skips targets that define their own PCH, that opt out
with DISABLE_PCH_REUSE, that override RTTI/EH, or that contain C/ObjC
[18 lines not shown]