VM_KERNEL_PT_PAGES is an old-pmap parameter, so segregate it to
the old-pmap, and default it there to a common value that individual
platforms can override if desired.
sysutils/heirloom: Fix with LLVM 21
FreeBSD 16-CURRENT recently imported LLVM 21. Seemingly ambiguous
code as in the patch is now flagged as an error.
(cherry picked from commit c9bc2a71a2129e4c222c8043c7261635b83b08ba)
sysutils/heirloom: Fix with LLVM 21
FreeBSD 16-CURRENT recently imported LLVM 21. Seemingly ambiguous
code as in the patch is now flagged as an error.
MFH: 2026Q2
NAS-140816 / 26.0.0-BETA.2 / Remove truenas-initrd.py and now dead dependencies (by anodos325) (#18838)
This commit removes local copy of truenas-initrd.py script, which is now
provided by https://github.com/truenas/upgrade_pyutils.
Since this script was the only consumer of the rootfs util to toggle
readonly property on filesystem it is also removed.
Original PR: https://github.com/truenas/middleware/pull/18830
Co-authored-by: Andrew Walker <andrew.walker at truenas.com>
[InstSimplify] Fix invalid dereference in simplifyBinaryIntrinsic (#194825)
For the simplifyBinaryIntrinsic interface the `Call` argument passed in
may be null, which differs from other interfaces such as
simplifyIntrinsic and simplifyUnaryIntrinsic which require `Call` to be
non-null. See FoldBinaryIntrinsic in InstSimplifyFolder.h where the
`Call` argument has a default value of null.
That means for all uses of `Call` in simplifyBinaryIntrinsic we must
first check the pointer is not null to avoid an invalid dereference.
This PR fixes the case for the get.active.lane.mask intrinsic.
There isn't currently an easy way to test this fix because the only
place I can see where FoldBinaryIntrinsic is called without a null
`Call` is VPlanTransforms.cpp and we don't currently invoke the function
for get.active.lane.mask intrinsics.
[mlir][vector] drop unit dim from memrefs for xfer_read/write with non-reduced mask (#187076)
Handles the case where the mask does not need to be trimmed, i.e. it's
already equal to the reduced vector type, for
`XferRead/WriteDropUnitDims` patterns.
Signed-off-by: Ege Beysel <beysel at roofline.ai>
[llvm][ADT] Add erase method to ScopedHashTableScope (#193516)
This PR introduces an `erase` method to `ScopedHashTable`, designed to
remove the most recent value associated with a given key within the
scope stack. To support efficient deletion, the internal
`ScopedHashTableVal` structure has been refactored into a doubly linked
list, allowing the predecessor of a node to be identified in O(1) time
during removal. Fix the MLIR CSE issue
https://github.com/llvm/llvm-project/pull/191135#discussion_r3100850607.
Part of https://github.com/llvm/llvm-project/pull/193778.
arm64: Fix a MTE check
It should be for FEAT_MTE2 as the registers aren't implemented for
FEAT_MTE.
While here fix the style of the comment explaining the check.
Reported by: markj
Fixes: 58de79153622 ("arm64: mte: configure initial state for system registers")
Sponsored by: Arm Ltd
arm64: Support some per-thread sctlr_el1 fields
This will be used to enable MTE from userspace.
Sponsored by: Arm Ltd
Differential Revision: https://reviews.freebsd.org/D55950
NAS-140814 / 26.0.0-BETA.2 / Copy VM NVRAM and TPM state on clone (by Qubad786) (#18839)
## Context
In continuation of the changes made in
https://github.com/truenas/middleware/pull/18764, the same fixes have
been applied to the VM cloning process ensuring that when a VM is cloned
- relevant files are copied over of the VM as well so tpm/secure boot
function as intended.
Original PR: https://github.com/truenas/middleware/pull/18828
Co-authored-by: M. Rehan <mrehanlm93 at gmail.com>
[clang][Lex] Collapse relative extern module paths when recursing to prevent unbounded path length growth. (#193691)
Ref #147220.
### Problem Description
Bazel's use of clang modules for its `layering_check` emits `extern
module` declarations relative to some base path meaning those paths
usually include long sequences of `../` followed by the path to the
module itself.
When parsing `extern module` in the module file, we (I believe
intentionally) silently ignore missing module files. Currently in the
problem case if the file existence check failed for any _other_ reason
it also silently ignores it. This means that `-fmodules-strict-decluse`
that bazel uses for the layering_check can throw a spurious
`err_undeclared_use_of_module` error which is the problem reported in
#147220.
Clang's `extern module` parsing chooses to concatenate these relative
[17 lines not shown]
[flang][NFC] Converted five tests from old lowering to new lowering (part 53) (#194772)
Convert five tests to use new HLFIR lowering instead of legacy FIR
lowering:
Lower/allocatable-callee.f90, Lower/allocatable-caller.f90,
Lower/assignment.f90, Lower/assumed-shape-caller.f90,
Lower/Intrinsics/count.f90
[VPlan] Check FOR/FMinMaxNum epilogue restrictions in VPlan. (#191815)
Move checking of FOR/FMinMaxNum restriction checks for epilogue
vectorization to hasUnsupportedHeaderPhiRecipe and perform checks
directly on VPlan.
This unifies the checking code and enables epilogue vectorization of
VPlans with dead FORs, although the latter should be cleaned up by
scalar optimizations earlier in practice.
PR: https://github.com/llvm/llvm-project/pull/191815
[InstCombine] Fold select of ordered fcmps of fabs over NaN-scrubber selects to a single select (#192182)
Fold `select (fcmp <ordered> (fabs (select isKnownNeverNaN X, X, Y)),
K), ...` into a single compare/select directly on `X`. The outer fcmp is
limited to ordered predicates, since only they preserve the original
non-NaN behavior.
fixes #143649
alive2: https://alive2.llvm.org/ce/z/G8UmjY
Generalized proof (needs local alive2 build):
```alive2
declare double @llvm.fabs.f64(double)
define double @src(double %x, double %y, double %k) {
entry:
%ord = fcmp ord double %x, 0.000000e+00
[14 lines not shown]
[mlir][x86] Support for `f8` AMX tiled dot-product. (#194786)
This patch enable AMX tiled dot-product support for `f8E4M3FN` and
`f8E5M2` types in MLIR by lowering to below llvm instrincs:
- `llvm.x86.tdpbf8ps`
- `llvm.x86.tdpbhf8ps`
- `llvm.x86.tdphbf8ps`
- `llvm.x86.tdphf8ps`