[NFC][AMDGPU] Generalize some LDS MemoryUtils (#195611)
In preparation for upcoming work, I need some functions used by the LDS
lowering
system to work on any GV. I removed the LDS specific queries inside
these functions
and replaced them with functors passed by the caller, so these utility
functions can be reused.
I also cleaned-up a few things that weren't up to code, such as
lowercase variable names.
[BOLT] Add test for perf2bolt perfscript profile output (#201792)
Perf2bolt is able to generate perfscript output format via
`--profile-format=perfscript` from perf.data, and use it as an input
with `-ps`.
Updated the existing 'perf_test.test' and 'perf_brstack.test' to cover the
generation and parsing of the 'perfscript' format.
Depends on:
https://github.com/llvm/llvm-project/pull/171144https://github.com/llvm/llvm-project/pull/163785
[mlir][CSE] fix use-after-free (#203849)
There was a use-after free introduced accidentally by e79e056ee982
[mlir][CSE] Remove the opsToErase container and immediately delete dead
ops. (#203702) This change fixes it by moving the copy of the location
(the "use") to before the deletion of the op (the "free").
Locating the use-after-free has been assisted by Claude Code. The
implementation of the fix has been done without it.
Signed-off-by: Stefan Schuermans <schuermans at roofline.ai>
devel/electron{37,38,39,40,41,42}: Unbreak chromium tarball extraction on -current
When a user tries to build electron using a 16-current jail, it fails
in the extract phase with the following error:
tar: Pathname can't be converted from UTF-8 to current locale
tar: Error exit delayed from previous errors
This is due to the ports framework sets the environment variable
LC_ALL to C, which causes tar to fail to extract files containing
non-ASCII characters in their names. To cope with this, EXTRACT_ENV
was introduced in the commit 98103f194302. Utilizing this variable
when extracting the chromium tarball fixes the error.
PR: 296017
Reported by: Dan Kotowski <dan.kotowski at a9development.com>,
fgorter <fgorter at gmail.com>
[X86] Fold nested VGF2P8AFFINEQB instructions (#195210)
Given that `vgf2p8affineqb` can perform arbitrary XOR permutations of
the input, all nested affine transformations can be performed with a
single instruction. The matrix for such fold can be calculated by
permuting the sub-matrix by the super-matrix at a byte, rather than bit,
granularity. This patch:
- Folds nested `vgf2p8affineqb` instructions with constant matrix
operands into one.
- Folds the sub-immediate by performing a affine transformation by the
super-matrix.
- Can fold non-splat super-matrices if the sub-immediate is zero.
- Includes test coverage for complex nested affine transformations,
verifying the correctness of the folded matrix and immediate.
- Includes negative test coverage for when the fold isn't possible.
Fixes #179607
[LLVM][CodeGen][SVE] Reimplement SVE VLS predicate load/store transformation as DAG combines. (#203314)
This is part of an effort to remove SVEIntrinsicOpts.
[clang][bytecode] Update what primtypes need a Descriptor ctor func (#203834)
Now that IntegralAP is allocated via InterpState/Program, we don't need
to initialize it. The same is true for Floating.
And with the new `InitMapPtr` being zero by default as well, we don't
need ctor funcs for primitive array types if the element type doesn't
need one.
NAS-141234 / 26.0.0-RC.1 / Drop VM and container devices on pwenc secret reset (by Qubad786) (#19136)
## Problem
vm_device.attributes and container_device.attributes are
sa.JSON(encrypted=True). When the pwenc secret that wrote them is gone,
every read decrypts to {}, which then fails the dtype-discriminated
attributes validation and makes vm.query / container.query raise for
every caller — including port.ports_mapping, which cascades into the
Containers pool validator.
## Solution
Delete both tables in the pwenc reset routine, matching how other rows
whose only payload is an encrypted blob are handled (keychain, cloud
credentials, ACME DNS). The blobs are unrecoverable once the key is
gone, and attributes has no valid empty form to fall back to. vm_vm and
container_container have no encrypted columns, so they're left intact to
preserve the user's VM / container list for reconfiguration.
Original PR: https://github.com/truenas/middleware/pull/19135
Co-authored-by: M. Rehan <mrehanlm93 at gmail.com>
misc/mate-user-guide: add GitHub releases site hint to PORTSCOUT
Move PORTSCOUT after USE_* variables and add the GitHub releases site
hint to help portscout find new versions.
[clang-tidy] Fix altera-unroll-loops crash on multi-decl for init (#203865)
Avoid calling `DeclStmt::getSingleDecl()` unless the declaration
statement contains a single declaration.
Closes https://github.com/llvm/llvm-project/issues/203856
[libc++] Enable header tests under all configurations (#202543)
Most of the header tests (e.g. double_include) only check that headers
are includable or have properties that hold all the time, regardless of
any active carve-outs. In accordance with that, this patch enables said
tests even when carve-outs are active.
Only the transitive inclusion test is kept disabled by carve-outs
because the transitive includes can't reasonably be maintained
when carve-outs are active.
Related to #202246 and #202001.
[LLVM][InstCombine][SVE] Canonicalise sve.ptrue(SV_POW2) to splat(i1 true). (#203556)
SVE vectors must be a power-of-two in length, making pow2 synonymous
with all.
Merge tag 'pull-fixes' of gitolite.kernel.org:pub/scm/linux/kernel/git/viro/vfs
Pull udf fix from Al Viro:
"I just noticed that a udf fix had been sitting in #fixes since
February; still applicable, Jan's Acked-by applied. Very belated pull
request"
* tag 'pull-fixes' of gitolite.kernel.org:pub/scm/linux/kernel/git/viro/vfs:
udf: fix nls leak on udf_fill_super() failure
[LV][NFC] Use APFloat class when printing out costs per lane (#201824)
At the moment it's difficult to auto-generate CHECK lines for
cost model output because the floating point value printed
out along with "Estimated cost per lane" is fragile and can
vary from target to target. See PR #201580 for an example of
this. Also, I would like to start using auto-generation of
cost model CHECK lines more often in tests to make life
easier for developers to update them.
Following reviewer feedback, I've solved this by using the
APFloat class to create a deterministic and consistent way
of printing out a floating point value across all targets.
However, this also then leads to significant changes in many
tests, in particular there are a very large number of changes
in the WebAssembly/memory-interleave.ll file. Rather than
manually edit and change every single case I have opted for
auto-generation of cost CHECK lines instead. This requires
adding a new debug-only flag called
[5 lines not shown]
[lldb][NFC] Use unique_ptr for SearchFilter (#203239)
Originally we did not have a better option, but now ownership of
SearchFilters is more precisely represented using unique_ptrs. If, in
the future, any of the use sites here truly requires shared ownership,
the conversion at the site that requires it is trivial (it can even be
done implicitly).
Mk/bsd.port.mk: Use SETENV for EXTRACT_ENV
Follow the precedent set by the other *_ENV variables in the ports
framework. The only practical effect is a very slight slowdown.
Fixes: 98103f194302 ("Mk/bsd.port.mk: Add EXTRACT_ENV")
Requested by: arrowd
MFH: 2026Q2
Reviewed by: mat
Differential Revision: https://reviews.freebsd.org/D57302
(cherry picked from commit 1223a9d807e5855d72c8af0cdb3152241cf9c97f)
Mk/bsd.port.mk: Use SETENV for EXTRACT_ENV
Follow the precedent set by the other *_ENV variables in the ports
framework. The only practical effect is a very slight slowdown.
Fixes: 98103f194302 ("Mk/bsd.port.mk: Add EXTRACT_ENV")
Requested by: arrowd
MFH: 2026Q2
Reviewed by: mat
Differential Revision: https://reviews.freebsd.org/D57302
[mlir][bufferization] Add error for memref return types
Add validation to reject functions with memref return types, as static
memory planning is incompatible with returning memrefs. In allocate mode,
the arena is freed at function exit, making returned memrefs invalid. In
arg mode, returning a memref from the input arena violates typical memory
ownership patterns.
When a function has memref return types, the pass:
1. Emits a clear error message
2. Fails gracefully without transforming the function
3. Preserves the original IR
This prevents silent bugs where returned memrefs would point to freed or
external memory.
Changes:
- Add return type validation at start of runOnOperation()
- Check all result types for MemRefType
[2 lines not shown]
[mlir][bufferization] Add arena-mode pass option (allocate vs arg)
Add arena-mode pass option to control how the shared arena is obtained:
- 'allocate' (default): Creates arena via memref.alloc within the function
- 'arg': Uses function's first argument as the pre-allocated arena
The 'arg' mode is useful when the arena is pre-allocated externally and
passed to the function, enabling use cases like pre-allocated scratch
buffers or memory pools.
In 'arg' mode, the pass validates that:
1. The context is a function operation
2. The function has at least one argument
3. The first argument is memref<...xi8>
If validation fails, the pass emits an error and fails gracefully.
Changes:
- Add arena-mode option to Passes.td with default 'allocate'
[3 lines not shown]