RuntimeLibcalls: Drop errno effects on targets without math errno
Teach the triple about targets which never support writing errno from
math functions. This is distinct from clang's -fno-math-errno default,
which is also enabled on some targets whose libm can set errno, such
as NetBSD. In the future we could add a no-math-errno module flag, but
that would exacerbate an existing bug where linking a -fno-math-errno
TU into a -fmath-errno TU will implicitly take the first linked
module's setting.
To do this make math errno a separate libcall property instead of
directly encoding it in the memory effects. This is necessary because
of non-math errno users.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
[libc] Use LIBC_INLINE_VAR for str_to_float lookup tables (#241075)
This should remove 2 unnecessary copies (total ~22KiB).
Now we have three copies in strtod.cpp, strtof.cpp, strtold.cpp.
[MemProf] Remove stale asserts on ELF segment layout (#231481)
Closes: [#231479](https://github.com/llvm/llvm-project/issues/231479)
This removes three assertions causing an assert error when attempting to
read a shared library whose offset is not 0 using llvm-profdata.
The assertions do not seem to apply to the code after them. The
symbolization that follows them does not seem to rely on them:
```
object::SectionedAddress
RawMemProfReader::getModuleOffset(const uint64_t VirtualAddress) {
if (VirtualAddress > ProfiledTextSegmentStart &&
VirtualAddress <= ProfiledTextSegmentEnd) {
const uint64_t AdjustedAddress =
VirtualAddress + PreferredTextSegmentAddress - ProfiledTextSegmentStart;
return object::SectionedAddress{AdjustedAddress};
}
```
`PreferredTextSegmentAddress` is read from the program header and
[5 lines not shown]
NAS-145406 / 28.0.0-BETA.1 / Require NTS for S3 Object Lock only when require_nts is set (#20282)
s3d refused every time source without NTS, so on the default NTP servers
every object-locked bucket was read-only. Render require_nts into its
[server] section, and when the setting changes, restart S3 once chronyd
has selected a source again (up to 60 s).
Needs truenas_s3 with the [server] require_nts key.
---------
Co-authored-by: claude_103 <claude_103 at ixsystems.com>
[mlir][x86] Do not lower masked reads in VectorContractBF16ToFMA (#244895)
`VectorContractBF16ToFMA` turns the LHS and RHS reads of a
`vector.contract`
into x86 packed loads. It checked the reads for out-of-bounds dims, but
not
for a mask. So a masked read was lowered anyway and its mask was lost:
the
masked-off lanes read memory instead of getting the padding.
For example, `%mask` was unused after the rewrite:
```mlir
%2 = vector.transfer_read %arg1[%c0, %c0, %c0], %pad, %mask
{in_bounds = [true, true, true]} : memref<1x32x2xbf16>, vector<1x8x2xbf16>
%3 = vector.contract {...} %1, %2, %acc
: vector<1x1x2xbf16>, vector<1x8x2xbf16> into vector<1x8xf32>
```
[7 lines not shown]
[X86][FastISel] Fix crash when storing a vector of null pointers (#244590)
Since #195486, a vector of null pointers is a `ConstantPointerNull`.
`X86FastEmitStore` still replaces it with a scalar integer zero, so
256-bit and 512-bit stores copy that zero from a general-purpose
register to a vector register, which fails with "Cannot emit physreg
copy instruction".
Build the zero from the type of the null value instead, as
`FastISel::materializeConstant` does.
Fixes #244129
Assisted-by: Claude Opus 5.5
[PGO] Address review: opt-in -pgo-use-missing-func=none|cold|hot
Make missing-function annotation opt-in via -pgo-use-missing-func=none|cold|hot (defaulting to none) and extract annotateOnLookupFailure().
[AArch64][NFC] Add [de]interleave6 tests
interleave6 and deinterleave6 already have support for custom lowering
using st3/ld3 and uzp/zip, but was missing test coverage for a sequence
where values are interleaved and stored, or loaded and deinterleaved.
Assisted-by: Codex
[AArch64] Enable Custom Lowering of [de]interleave8
To enable lowering of [de]interleave8 intrinsics, we can
use the custom lowering for Factors of 4, as these are split
into intrinsics where native support is available for the relevant
ld/st instructions on AArch64.
Previously an operation where a store follows an interleave, or a
deinterleave follows a load, this would have been lowered to scalar
ldr and str instructions, instead, ld4/st4 is used reducing the number
of uzp or zip instructions needed to complete the sequence.
Assisted-by: Codex (tests)
[mlir][llvm] Register the DLTI dialect with the LLVM IR translations (#245414)
This PR registers the DLTI dialect alongside the LLVM IR translations,
which allows their callers (e.g. `mlir-runner`, the C API) to parse
modules that carry DLTI dialect attributes.
Previously, DLTI was registered by hand in the `--mlir-to-llvmir` and
`--import-llvm` translations. Those registrations are now removed.
Also test that `mlir-runner` and the C API can parse a module carrying
DLTI attributes.
Assisted-by: Claude
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
Attributor: Don't report a change when no functions are internalized
internalizeFunctions returned true for an empty set, so this reported
a change for every module and invalidated all function analyses even
when it did nothing.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>
legitimize_operand() tries to use convert double constants to float, if the
conversion is lossless, in order to reduce register pressure. But the way the
code has been written is too optimistic in deciding which double values can
indeed get safely converted to float. Trust exact_real_truncate() instead,
which knows better.
Bug reported by Izumi Tsutsui, thanks!
OpenMPOpt: Invalidate function analyses individually
Avoid discarding analyses that never need to be invalidated, such as
TargetLibraryInfo.
Co-authored-by: Claude Opus 5.5 <noreply at anthropic.com>