CodeGen: Stop using TargetLowering's libcall info in PreISelIntrinsicLowering (#239898)
The TargetLowering copy of RuntimeLibcallsInfo should be deleted and
only the analysis should be used.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
[SPARC] Branch directly on the result of a constrained FP compare (#239385)
A branch on a constrained FP compare currently materializes the compare
result with a select of 1/0 and then branches on an integer compare of
that value against zero.
Branch on the FP condition codes directly when the compare's output
chain feeds only the branch, either directly or through a token factor
used only by the branch. The compare is glued to the branch, so this
is not done when another node is ordered after the compare, such as a
call.
Also look through the "and X, 1" that brcond expansion inserts when X
is already a SELECT_[IF]CC of 1 and 0, which lets the existing
LookThroughSetCC fold the soft-quad f128 compare as well.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
Hexagon: Remove redundant clearKillFlags calls (#239894)
HexagonOptAddrMode recomputes kill flags with Liveness::resetKills
after any change, so its clears are redundant.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
AArch64: Remove clearKillFlags calls on virtual registers (#239782)
Kill flags are no longer permitted on virtual registers, so clearing
them is a no-op. Remove the calls where the register can only be
virtual.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
BPF, Lanai, ARC, M68k: Register null target streamer (#239823)
Since 44a08dc732c5, llc -filetype=null is a fatal error on targets
that do not register a null target streamer. These targets do not need
a target specific streamer for the null case, so register the base
MCTargetStreamer.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
live ISO: hand launchd /dev/null stdio, not the console
The live ISO's /init wires stdout/stderr to /dev/console for its own
[init] progress and error lines, then execs launchd. launchd only opens
/dev/null for closed fds, so PID 1 and every job without StandardOutPath
or StandardErrorPath inherited the console, and their stderr reached the
screen on a normal boot.
Redirect stdio to /dev/null on the exec of launchd, matching a disk boot
where the kernel starts launchd with no fds open. /init's own output and
failure paths before that point still go to the console; the exec-failed
message now writes to /dev/console explicitly. Verbose boots keep
launchd's console logging, which launchd opens itself under -v.
Co-Authored-By: Claude Opus 5.5 <noreply at anthropic.com>
poudriere-jail.8: Now there are pkgbase src packages so remove outdated line
(cherry picked from commit fd8e1fd46b7085268fc3c14dc4c4be6ea8697d0d)
Conflicts:
src/man/poudriere-jail.8
PR #1394
[Support] Pass tool options to parseCommandLineOptions
`RegisterMCToolOptions` adds `MCToolOptions` to the process-wide
registry. Once lld registers them, every later parse in the process
accepts `-crel`, including clang's `-mllvm`, which then ignores it.
Add a `parseCommandLineOptions` overload that takes the libraries a tool
opts in to. Replace `RegisterMCToolOptions` with `mc::getToolOptions`
and `codegen::getToolOptions`, which tools pass where they parse,
including lld's `-mllvm`, gold's `-plugin-opt`, and libLTO's debug
options. `RegisterCodeGenFlags` no longer registers the MC options.
`LibraryOptionsContext` records the library that parsed each argument,
so `assign` replays without looking up the registry, which does not
contain tool options.
LLM-aided
[MC] Declare the MCTargetOptions command line options in TableGen (#239920)
Move RegisterMCTargetOptionsFlags options into a private `MCToolOptions`
struct, different from MCCLOptions since `MCToolOptions` requires tool
opt-in. RegisterMCToolOptions, renamed from RegisterMCTargetOptionsFlags
(LLVMOption and clang driver use "flags" for boolean options), registers
the struct, so `clang -mllvm -crel` remains an error.
Remove the getters without outside readers. llc reads `MCRelaxAll`
instead of `getExplicitRelaxAll`, so `-mc-relax-all=false` no longer
warns with a non-object file type.
LLM-aided
Update p5-CGI to 5.02
Many updates for CVE, including some that are not backwards compatible,
however tests for modules that depend on this one all still passed.
https://metacpan.org/dist/CGI/changes
[ADT] Add LLVM_ATTRIBUTE_WARN_UNUSED to ADT classes (#239908)
This patch adds LLVM_ATTRIBUTE_WARN_UNUSED to various ADT classes so
that compilers can diagnose unused variables of these types even though
they have non-trivial constructors or destructors.
Remarks:
- Local testing confirms that unused direct-constructed variables of
each touched class trigger -Wunused-variable if and only if the
attribute is present.
- Derived classes such as SmallPriorityWorklist and SmallSetVector are
annotated explicitly because compilers do not inherit warn_unused from
base classes.
- Other ADT classes are left alone for now because adding the attribute
to them would trigger warnings in existing code.
[5 lines not shown]
[Support] Pass tool options to parseCommandLineOptions
`RegisterMCToolOptions` adds `MCToolOptions` to the process-wide
registry. Once lld registers them, every later parse in the process
accepts `-crel`, including clang's `-mllvm`, which then ignores it.
Add a `parseCommandLineOptions` overload that takes the libraries a tool
opts in to. Replace `RegisterMCToolOptions` with `mc::getToolOptions`
and `codegen::getToolOptions`, which tools pass where they parse,
including lld's `-mllvm`, gold's `-plugin-opt`, and libLTO's debug
options. `RegisterCodeGenFlags` no longer registers the MC options.
`LibraryOptionsContext` records the library that parsed each argument,
so `assign` replays without looking up the registry, which does not
contain tool options.
LLM-aided
[MC] Declare the MCTargetOptions command line options in TableGen
Move RegisterMCTargetOptionsFlags options into a private `MCToolOptions`
struct, different from MCCLOptions since `MCToolOptions` requires tool
opt-in. RegisterMCToolOptions, renamed from RegisterMCTargetOptionsFlags
(LLVMOption and clang driver use "flags" for boolean options), registers
the struct, so `clang -mllvm -crel` remains an error.
Remove the getters without outside readers. llc reads `MCRelaxAll`
instead of `getExplicitRelaxAll`, so `-mc-relax-all=false` no longer
warns with a non-object file type.
LLM-aided
mail/vandelay: JMAP account migration and backup utility
Vandelay is a one-shot account migration utility for JMAP from the
Stalwart Labs team (the authors of mail/stalwart). It imports an
account from JMAP, IMAP, CalDAV, CardDAV, WebDAV, ManageSieve,
Maildir++, Google Takeout, Microsoft Exchange Server (EWS) or Exchange
Online (Graph) into a self-contained local SQLite archive, and exports
that archive into a target JMAP server. Both steps are resumable, so
the archive also works as a per-account backup.
PR: 300376
[Support] Pass tool options to parseCommandLineOptions
`RegisterMCToolOptions` adds `MCToolOptions` to the process-wide
registry. Once lld registers them, every later parse in the process
accepts `-crel`, including clang's `-mllvm`, which then ignores it.
Add a `parseCommandLineOptions` overload that takes the libraries a tool
opts in to. Replace `RegisterMCToolOptions` with `mc::getToolOptions`
and `codegen::getToolOptions`, which tools pass where they parse,
including lld's `-mllvm`, gold's `-plugin-opt`, and libLTO's debug
options. `RegisterCodeGenFlags` no longer registers the MC options.
`LibraryOptionsContext` records the library that parsed each argument,
so `assign` replays without looking up the registry, which does not
contain tool options.
LLM-aided
[MC] Declare the MCTargetOptions command line options in TableGen
Move RegisterMCTargetOptionsFlags options into a private `MCToolOptions`
struct, different from MCCLOptions since `MCToolOptions` requires tool
opt-in. RegisterMCToolOptions, renamed from RegisterMCTargetOptionsFlags
(LLVMOption and clang driver use "flags" for boolean options), registers
the struct, so `clang -mllvm -crel` remains an error.
Remove the getters without outside readers. llc reads `MCRelaxAll`
instead of `getExplicitRelaxAll`, so `-mc-relax-all=false` no longer
warns with a non-object file type.
LLM-aided
[CodeGen][MC] Pass a LibraryOptionsContext to the MC option readers. NFC (#239919)
Rename `InitMCTargetOptionsFromFlags` to `getMCTargetOptions` and
`InitTargetOptionsFromCodeGenFlags` to `getTargetOptions`. Most of these
options take values, so "Flags" is a misnomer.
These functions and `getABIName` now take the `LibraryOptionsContext` to
read from. A per-context option declared in TableGen has no global value.
LLM-aided
[CIR][X86] Add support for addcarryx and subborrow builtins (#239685)
Lower __builtin_ia32_addcarryx_u32/u64 and
__builtin_ia32_subborrow_u32/u64
to the llvm.x86.addcarry.* and llvm.x86.subborrow.* intrinsics, matching
classic CodeGen.
These builtins support `_addcarryx_*` (adxintrin.h) as well as
`_addcarry_*` and
`_subborrow_*` (adcintrin.h) intrinsics, which previously were NYI.
The tests add ClangIR RUN lines to the existing
clang/test/CodeGen/X86/{adx,adc}-builtins.c: `-fclangir -emit-llvm` runs
checked
against the existing CHECK lines, and `-fclangir -emit-cir` runs with
new CIR
checks.
Assisted-by: Claude Code (Claude Opus 5.5)
[mlir][vector] Update doc for vector.broadcast (nfc) (#239707)
Follow-up for #228727:
* Simplify the formula for computing the source index (no need for a
special case when source_dim == 1)
* Add more examples.
The examples were created by @yueshengys in #227574, thank you!