[CIR] Split side_effect into memory effects, nounwind, and willreturn
side_effect was carrying three facts at once. It described the memory a
callee may touch, and it was also the only thing lowering derived
nounwind and willreturn from, so any callee with a known memory effect
got both. That is wrong for one that can throw, and willreturn had no
other representation in CIR at all.
const and pure now record the three separately, and the enum is replaced
by a structured #cir.memory_effects carrying the same six ModRef slots as
the LLVM dialect. On an operation it prints compactly, as memory(none)
or memory(read, argmem: readwrite). No lowered IR changes.
Assisted-by: Cursor / claude-opus-5
[CIR] Split side_effect into memory effects, nounwind and willreturn
side_effect was carrying three facts at once. It described the memory a
callee may touch, and it was also the only thing lowering derived
nounwind and willreturn from, so any callee with a known memory effect
got both. That is wrong for one that can throw, and willreturn had no
other representation in CIR at all.
const and pure now record the three separately, and the enum is replaced
by a structured #cir.memory_effects carrying the same six ModRef slots as
the LLVM dialect. On an operation it prints compactly, as memory(none)
or memory(read, argmem: readwrite). No lowered IR changes.
Assisted-by: Cursor / claude-opus-5
[mlir][SCF] Avoid crash in parallel loop unrolling test pass (#222644)
This fixes crashes in `--test-parallel-loop-unrolling` when
`unroll-factors` is missing or contains zero.
Previously, the test pass forwarded an empty or invalid factor list to
the parallel-loop unrolling utility, violating its preconditions and
triggering an assertion.
The pass now emits an error and signals pass failure when:
* `unroll-factors` is not provided.
* Any unroll factor is zero.
Regression tests verify the diagnostics for both invalid inputs using
`-verify-diagnostics`.
Fixes #222535.
Co-authored-by: Purnima Shrivastava <purnimashrivastava05@.com>
[llvm-exegesis] Add RawPerfEvent raw PMU counter path in createCounter (#208364)
Introduces RawPerfEvent, a PerfEvent derived class that constructs
perf_event_attr directly from EventSelect and UMask, bypassing
pfm_get_os_event_encoding for cycle and uops events.
createCounter routes to RawPerfEvent when PfmCountersInfo contains a
non-negative EventSelect for the cycle or uops counter slot, falling
back to the existing libpfm symbolic path otherwise. Extended
createBenchmarkRunner gate checks to allow raw-only counters in latency
and uops modes.
This wiring is opt-in. Existing behavior is unchanged.
Adds unit tests covering RawPerfEvent construction, config field
encoding, and kernel exclusion flag correctness.
Validated on AMD Zen2: latency measurements via the raw path match the
libpfm symbolic path on identical hardware.
Towards #187930
[MLIR][XeVM] Fix mask lifetime in HandleVectorExtractPattern (#223879)
When a contiguous-slice shuffle is hoisted through a bitcast that
changes
the element count, the slice is rewritten against the bitcast source by
rescaling the mask into a local SmallVector and rebinding the `mask`
ArrayRef to it. That SmallVector was declared inside the
`if (maskScale != 1)` block, so it was destroyed before the two uses of
`mask` that follow the block - a stack-use-after-scope.
It is benign on uninstrumented builds, which is why precommit did not
catch it, but the sanitizer bots trap it on
Conversion/XeVMToLLVM/mxfp_scale_binary_hoist.mlir, the first test whose
chain drives the length-changing bitcast path:
ERROR: AddressSanitizer: stack-use-after-scope
READ of size 4
#23 mlir::detail::DenseArrayAttrImpl<int>::get(MLIRContext*,
ArrayRef<int>)
[22 lines not shown]
[CIR] Accept a union whose empty member is [[no_unique_address]] (#223538)
The record-wide reject for a member CIRGen marks empty is there for the
struct arm of mapCIRType, which reads such a member as an unnamed
bit-field standing for the bytes it occupies. This does not apply to a
union, so the reject moves into the struct branch.
Which variants the classifier sees then falls to the union arm, and it
now reads that from each variant's own storage rather than from its
mark. A zero-sized variant and one that is empty for the ABI are
skipped. One whose mark says empty over storage that holds data is not.
Assisted-by: Cursor / claude-opus-5
[llvm-profgen] Strip coroutine suffixes from DWARF info (#217980)
https://github.com/llvm/llvm-project/pull/141889 preserves coroutine
suffixes into the DWARF linkage name, which may unexpectedly pass down
those suffixes into the profile in llvm-profgen. The logging also shows
extremely high percentages of samples being recovered from symbol table
because of the unstripped suffixes introduced from DWARF linkage name.
```
warning: 45.38%(754559/1662830) of samples are from ranges that belong to functions recovered from symbol table.
```
This fix strips the coroutine in: 1) the inital
`loadSymbolsFromDWARFUnit` for profiled functions and 2) the stack
`symbolize` that constructs the context trie
Also updates the coroutine unittest to move coroutine header from
experimental to standard.
Drop v1 of the aws-cli: it enteref maintenance mode on July 15, 2026 and will
reach end-of-support on July 15, 2027. v2 is a drop-in replacement for most use
cases, and there's no point in maintaining 2 versions in tree. v1 can still be
installed with pip if needed.
"Yay" on the idea from sthen@ rsadowski@ joel@ (maintainer of v2)