[CodeGen] Declare command line options of the machine pipeliner in TableGen (#246484)
WindowSchedulingFlag becomes an enum class with WS_On, the -window-sched
default, as its zero enumerator.
-pipeliner-opt-size reads its value, so -enable-pipeliner-opt-size=false
no longer enables the pipeliner at -Os. -pipeliner-dbg-res and
-pipeliner-show-mask, read only in LLVM_DEBUG, exist only in assertions
builds.
Renames, with the old spelling kept as an alias:
```
-enable-pipeliner-opt-size -> -pipeliner-opt-size
```
LLM-aided
[analyzer][NFC] Use a base region map in RemoveDeadBindingsWorker (#246433)
RemoveDeadBindingsWorker looked up the cluster of a region in the store
every time it was added to the worklist, and tracked visited clusters in
a separate set that it probed again when filtering the store.
Record every cluster and a visited flag in a map from the base region
when the clusters are generated, so adding a region to the worklist is a
single hash lookup. If every cluster is live, return the store
unchanged. The worker no longer uses ClusterAnalysis.
On some LLVM TUs (GVN, LiveVariables, RegionStore, SemaExpr) this
reduces the instructions of the static analyzer by 2.5-3.3%.
Assisted-by: Claude Opus 5.5
---------
Co-authored-by: Gabor Horvath <gaborh at apple.com>
[cmake] Escape compiler launchers in the NATIVE configure command (#246475)
Newer ccache versions support specifying options directly on the command
line. Make sure `-DCMAKE_<LANG>_COMPILER_LAUNCHER` is correctly
propagated to the NATIVE sub-build if the user passed a list.
Assisted-By: Claude
Co-authored-by: Claude Sonnet 5.5 <noreply at anthropic.com>
tcp/rack: reject unknown rate_sample_method values
The net.inet.tcp.rack.rate_sample_method sysctl is copied into every
new RACK connection but accepts any integer, while the
TCP_BBR_RACK_RTT_USE socket option only accepts USE_RTT_HIGH (0),
USE_RTT_LOW (1) and USE_RTT_AVG (2). With any other value,
tcp_rack_xmit_timer_commit() panics an INVARIANTS kernel on the first
RTT sample of each new connection ("Unknown rtt variant"). Without
INVARIANTS it returns early on every sample, so the connection never
updates its SRTT, RTTVAR or RTO.
Validate the sysctl with a handler that accepts only the three values
that the socket option accepts, and document the third value in the
sysctl description and in tcp_rack(4).
Reviewed by: tuexen
Co-authored-by: Claude Opus 5.5
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D62072
tcp/rack: range-check pace_max_seg sysctl and socket option
The net.inet.tcp.rack.pacing.pace_max_seg sysctl is a 32-bit integer,
but rack_init() copies it into each new connection's 7-bit bitfield
rc_user_set_max_segs. Values that do not fit are truncated, and a value
of 128 becomes 0. A connection with rc_user_set_max_segs of 0 ends up
with a pacing max segment size of 0, and rack_setup_fast_output() then
executes rounddown(left_to_send, 0), causing an integer divide fault:
Fatal trap 18: integer divide fault while in kernel mode
#5 rack_do_segment_nounlock+0x29eb
... (fault in rack_setup_fast_output() inlined into rack_output())
The TCP_RACK_PACE_MAX_SEG socket option clamps values above
MAX_USER_SET_SEG (63), but it accepts 0, which leads to the same
division by zero.
Validate the sysctl with a handler that only accepts 1 to
MAX_USER_SET_SEG, and reject a socket option value of 0 with EINVAL
[12 lines not shown]
Add misc/paseo-hub: Agentic development environment (automation hub)
- Installed from the published @getpaseo/hub npm package, which ships
the prebuilt server and web app
- fs-native-extensions, which locks the embedded database, has no
FreeBSD support; it is built with a new FreeBSD backend using
flock(2), fspacectl(2), and extattr(2)
- rc script runs Hub as paseo-hub through daemon(8), listening on
127.0.0.1:3000 with its embedded database in /var/db/paseo-hub
Assisted-by: Claude Code (Opus 5.5, Fable 5.2)
Add www/paseo-web: Agentic development environment (web app)
- Prebuilt web app taken from the @getpaseo/server npm package; no
build
- Works with pairing links from any daemon and with net/paseo-relay
Assisted-by: Claude Code (Opus 5.5, Fable 5.2)
Add misc/paseo-desktop: Agentic development environment (desktop app)
- Built from the GitHub source and run with devel/electron44; amd64
only, as lightningcss has no FreeBSD binary for other architectures
- Runs the daemon and the CLI from misc/paseo; version locked to it
- Patches point resource paths at DATADIR, treat FreeBSD like Linux,
and leave updates to pkg
- node_modules archive pruned of non-FreeBSD prebuilt binaries
Assisted-by: Claude Code (Opus 5.5, Fable 5.2)
Add net/paseo-relay: Agentic development environment (relay server)
- Upstream has no releases; DISTVERSION g<date> tracks a commit
- Hex dependencies are fetched as distfiles and unpacked offline by
files/hex-deps.exs
- The OTP release bundles ERTS from lang/erlang-runtime29
- rc script runs the relay as paseo-relay, with Erlang distribution off
Assisted-by: Claude Code (Opus 5.5, Fable 5.2)
Add misc/paseo: Agentic development environment (daemon and CLI)
- Installed from the published @getpaseo/cli npm package, with
node_modules prefetched per architecture (aarch64, amd64)
- node-pty is rebuilt for FreeBSD, carrying microsoft/node-pty#961
- Dictation is off by default: its local speech engine (sherpa-onnx)
has no FreeBSD build
- rc script runs the daemon as paseo_user through daemon(8)
- ZSH option generates the zsh completion from the CLI's commander
definition
Assisted-by: Claude Code (Opus 5.5, Fable 5.2)
[LifetimeSafety][NFC] Use one allocator per analyzed function (#246490)
Each of the four immutable collection factories created its own
BumpPtrAllocator, and the fact, origin list and loan managers had one
each, so every analyzed function allocated seven slabs and four
allocator objects even when it produced only a handful of facts. Most
functions are small, so this setup dominated their cost. Allocate
everything from a single allocator owned by LifetimeSafetyAnalysis.
On some LLVM TUs (GVN, LiveVariables, RegionStore, SemaExpr) with
-fsyntax-only -Wlifetime-safety, this reduces the instructions of the
lifetime safety analysis by 4.7-8.8% (0.6-0.9% of the whole
compilation).
Assisted-by: Claude Opus 5.5
Co-authored-by: Gabor Horvath <gaborh at apple.com>
[LifetimeSafety][NFC] Skip the moved loans analysis for functions without moves (#246489)
Most functions do not pass anything to an rvalue reference parameter, so
no loan is ever moved and the analysis computes an empty map at every
point. Record whether a MovedOriginFact was created and skip the
analysis otherwise.
On some LLVM TUs (GVN, LiveVariables, RegionStore, SemaExpr) with
-fsyntax-only -Wlifetime-safety, this reduces the instructions of the
lifetime safety analysis by 5.3-7.3% (0.5-0.8% of the whole
compilation).
Assisted-by: Claude Opus 5.5
Co-authored-by: Gabor Horvath <gaborh at apple.com>
[libc++][pstl] Add a parallel implementation of exclusive scanning (#244683)
This PR generalises the existing implementation of parallel
`transform_inclusive_scan` to support both inclusive and exclusive
scans.
The implementation is pulled out into a new free function
`__statpart::__transform_scan()` that gets an additional template
parameter specifying the flavour of scanning.
Depending on that parameter the leaf scanning lambda implicitly switches
between inclusive and exclusive scans.
Both `inclusive_transform_scan` and `exclusive_transform_scan` just call
this new function with a different template parameter, i.e.
`__transform_scan</*inclusive=*/true>(...)` and
`__transform_scan</*inclusive=*/false>(...)`.
[llvm-cov] Look up expansion regions by FileID with binary search
Region vectors are already sorted by FileID, so filtering for one file
is just selecting a contiguous subrange. Do that with a binary search
instead of scanning the whole function.
[CIR] Test lowering of undef and poison aggregate constants
An undef or poison array, record or complex constant lowers to
llvm.mlir.undef or llvm.mlir.poison of the whole type before the
per-type lowering, so the removed isa checks never matched.
Assisted-by: Claude Code (Opus 5.5).
[libc++][pstl] Add a parallel implementation of std::copy_if (#241966)
This PR adds a parallel implementation of `std::copy_if` based on a
single-pass scanning.
Each partition is represented in the look back as the number of elements
for which the user-provided predicate returns `true` (partition
occupancy in other words).
This way the prefix of the loopback partition represents the position in
the destination range where its elements should be copied to.
The predicate flags are stored in a dynamically allocated bitset, which
has a size of `max_partition_size * max_workers_count` bits, aligned to
the cache line size.
[LowerMemIntrinsics] Make TTI non-optional and simplify signature of expandMemSet(Pattern)AsLoop (NFC) (#246090)
Simplify and remove the TTI-pointer null-allowing overloads. Nothing is
currently using them anyway.
[LangRef][MemoryBuiltins] Add support for CHERIoT's heap_allocate and heap_free functions. (#245094)
This requires relaxing the LangRef requirement that `allockind(free)`
functions must return `void`. CHERIoTRTOS' primary heap free API
`heap_free` returns an integer error code, necessitating this change.
Once integer-returning `allockind(free)` functions are permitted, we
also add an extensible path for looking up the return value to substitue
in the case where `free(alloc(...))` is elided. For now we require this
to be 0.
[lld-macho] Collect S_ATTR_LIVE_SUPPORT sections with the markLive roots
Co-Authored-By: Claude Opus 5.5 <noreply at anthropic.com>
Co-Authored-By: Claude Fable 5.2 <noreply at anthropic.com>
tests/net/bpf: run the bpf:inject test with RSS again
1abb62867f2a skipped the test on RSS kernels because epair(4) delivered
the injected frames out of order. The reordering within a flow is fixed
in if_epair, but the test still failed in about one run in seven: the
first capture starts with the ARP request from ping(8), which is not an
IP packet and goes to the first epair queue, while the ICMP flow goes to
the queue its hash selects. Written back to back by the inject step,
the two may arrive in either order.
Add static ARP entries on both ends so that the captures hold only the
ICMP flow, and remove the skip. On an 8-CPU RSS kernel the test then
passed 250 of 250 runs with the if_epair fix and failed 26 of 150
without it.
While here, use the -j option of ifconfig(8), netstat(1) and arp(8)
instead of jexec(8).
Reviewed by: glebius, pouria
[2 lines not shown]
when building a KRL from a control file, do not treat a # character
that is not at the start of a line or preceeded by whitespace as the
start of a comment, as key IDs may legitimately contain these
Anthropic ANT-2026-ZF4XFAKS