[qt/clang/llvm-project]: Summary of bulk changes made
KDE Git Services - Bulk Change <[email protected]>
| Newsgroups | gmane.comp.kde.cvs |
|---|---|
| Message-ID | <[email protected]> |
Git repository change summary for qt/clang/llvm-project
Pushed by mirror-service into branch 'upstream/users/petar-avramovic/artifact-combiner-fix'.
Changed from 0000000000000000000000000000000000000000 to e7b958fb71a2e3277b488fc2a4a197e9140942de
Acknowledgement was received that this change introduces only existing code that has been pushed to another public open source repository.
This change contains the following new commits:
Git commit c301b9901ae93fa91c9861ce13d508d53191a378 by GitHub (on behalf of Matthew Devereau) on 03/08/2026 at 11:13..
[AArch64][SVE] Fold nested boolean UMIN trees (#209234)
Fold redundant UMIN clamps in logical boolean reduction trees when all
operations use the same predicate.
https://invent.kde.org/qt/clang/llvm-project/-/commit/c301b9901ae93fa91c9861ce13d508d53191a378
Git commit 5ce177f6cd3672aae1791ba155b5438c9198a8ce by GitHub (on behalf of Harald-R) on 03/08/2026 at 11:16..
Fix llvm-mlir-use-after-erase findings (#210733)
Fix the following warnings identified by the `llvm-mlir-use-after-erase`
check from https://github.com/llvm/llvm-project/pull/210727:
```cpp
mlir/lib/Transforms/Utils/DialectConversion.cpp:2700:33: warning: operation 'op' is used after it was erased [llvm-mlir-use-after-erase]
2700 | curState, std::string(op->getName().getStringRef()) + " folder");
| ^
mlir/lib/Transforms/Utils/DialectConversion.cpp:2685:12: note: operation erased here
2685 | rewriter.replaceOp(op, replacementValues);
| ^
mlir/lib/Dialect/MemRef/Transforms/NormalizeMemRefs.cpp:440:29: warning: operation 'newOp' is used after it was erased [llvm-mlir-use-after-erase]
440 | Value newMemRef = newOp->getResult(resIndex);
| ^
mlir/lib/Dialect/MemRef/Transforms/NormalizeMemRefs.cpp:459:20: note: operation erased here
459 | newOp->erase();
| ^
mlir/lib/Dialect/MemRef/Transforms/NormalizeMemRefs.cpp:440:29: note: the use happens in a later loop iteration than the erase
440 | Value newMemRef = newOp->getResult(resIndex);
| ^
```
The warning at `NormalizeMemRefs.cpp:440` is resolved by breaking the
loop iteration after erasing the operation, similar to what is done at
line 306.
https://invent.kde.org/qt/clang/llvm-project/-/commit/5ce177f6cd3672aae1791ba155b5438c9198a8ce
Git commit 2ef2ab65e8622a81b060b96a2ed579816d01f03f by GitHub (on behalf of Kamlesh Kumar) on 03/08/2026 at 11:26..
[AArch64] Update tests with interleave intrinsics (#212312)
https://invent.kde.org/qt/clang/llvm-project/-/commit/2ef2ab65e8622a81b060b96a2ed579816d01f03f
Git commit d2b28a818981d9703f2ebf0eeeb5e1d9d77dec51 by GitHub (on behalf of Ramkumar Ramachandra) on 03/08/2026 at 11:37..
[ConstFold] Fold fixed-vectors in constantFoldIntrinsic (#213625)
This exposes an underlying bug in wasm.dot-folding, which we fix. The
motivation for this patch is to enable folding of get.active.lane.mask
in VPlan in a follow-up.
https://invent.kde.org/qt/clang/llvm-project/-/commit/d2b28a818981d9703f2ebf0eeeb5e1d9d77dec51
Git commit 3db0dd71c8579fb825bdd2c6148b53496e485375 by GitHub (on behalf of Manuel Carrasco) on 03/08/2026 at 11:44..
Implement support for NSDI DebugFunctionDefinition. (#211853)
This PR depends on the DebugFunction PR:
https://github.com/llvm/llvm-project/pull/211760. This PR implements
support for
[DebugFunctionDefinition](https://github.khronos.org/SPIRV-Registry/nonsemantic/NonSemantic.Shader.DebugInfo.html#DebugFunctionDefinition).
DebugFunctionDefinition must be emitted within the instruction sequence
of its corresponding OpFunction. The current implementation inserts
DebugFunctionDefinition immediately after the last OpVariable, if one
exists, or otherwise immediately after the first OpLabel. The goal is to
satisfy the following
[requirement](https://github.khronos.org/SPIRV-Registry/nonsemantic/NonSemantic.Shader.DebugInfo.html#_binary_form):
> DebugScope, DebugNoScope, DebugDeclare, DebugValue, DebugLine,
DebugNoLine, and DebugFunctionDefinition instructions may interleave
with instructions inside a function, but they must appear at valid
locations within a block as required by SPV_KHR_non_semantic_info. In
particular, they cannot appear before any OpPhi or function-level
variable declarations in a block, and they cannot appear after a merge
instruction.
To support this, I updated SPIRVAsmPrinter to notify the debug handler
whenever an instruction is emitted. The debug handler maintains a small
amount of state so it can detect when the last OpVariable or the first
OpLabel has been emitted and insert DebugFunctionDefinition at the
appropriate location.
https://invent.kde.org/qt/clang/llvm-project/-/commit/3db0dd71c8579fb825bdd2c6148b53496e485375
Git commit 6a7f6a02bb95a75c615cde3194ad77d776b869c5 by GitHub (on behalf of Benedek Kaibas) on 03/08/2026 at 11:50..
[analyzer] Implement BugReporterVisitor for UseAfterLifetimeEnd to trace lifetime source binding (#207052)
Currently the `UseAfterLifetimeEnd` checker can emit warnings, but those
warnings cannot clearly describe to which annotated parameter the return
value is actually bound. When multiple parameters are annotated, it is
unclear which one the return value is bound to. Using
`BugReporterVisitor` to trace back the nodes and emit a note that
explains where the lifetime of the annotated parameter (the source)
ended can be helpful for users.
***NOTE***: This PR is built on #205951. It should only be merged after
#205951 is merged.
Consider the following case:
```cpp
#include <stddef.h>
class Arena {
char buf[128];
char *buffer = buf;
size_t offset = 0;
public:
void *allocate(size_t size) [[clang::lifetimebound]] {
void *p = buffer + offset;
offset += size;
return p;
}
void reset() {offset = 0;}
};
void *arena_dangling() {
Arena arena;
void *p = arena.allocate(128);
arena.reset();
return p; // arena goes out of scope therefore p dangles
}
```
The `UseAfterLifetimeEnd` checker correctly detects this error and emits
path notes that trace where the value was bound and where its lifetime
ends:
```text
temp.cpp:21:3: warning: Returning value bound to 'arena' that will go out of scope [alpha.cplusplus.UseAfterLifetimeEnd]
21 | return p;
| ^~~~~~~~
temp.cpp:19:13: note: Value bound to 'arena' here
19 | void *p = arena.allocate(128);
| ^~~~~~~~~~~~~~~~~~~
temp.cpp:21:3: note: Lifetime of 'arena' ended here
21 | return p;
| ^~~~~~~~
1 warning generated.
```
The motivating example comes from here:
https://discourse.llvm.org/t/clang-static-analyzer-gsoc-2025-teach-the-clang-static-analyzer-to-understand-lifetime-annotations/84487/41?u=bkaibas01
https://invent.kde.org/qt/clang/llvm-project/-/commit/6a7f6a02bb95a75c615cde3194ad77d776b869c5
Git commit 68449895e267174801d3b11afd957548f5796a41 by GitHub (on behalf of Kacper Doga) on 03/08/2026 at 12:16..
[GlobalISel] emit G_BITCAST in widenScalarMergeValues when DstTy does not match WideTy (#203014)
**Problem:**
`LegalizerHelper::widenScalarMergeValues` does not handle the case where
the destination register type is a floating-point type but the widen
operation produces an integer type of the same size.
For example, given:
```
%0:_(i8) = G_CONSTANT i8 0
%1:_(i8) = G_CONSTANT i8 1
%2:_(f16) = G_MERGE_VALUES %0:_(i8), %1_:(i8)
```
With a `minScalarOrElt` rule widening the source type to I16,
`widenScalarMergeValues` enters the `WideSize >= DstSize` path and
assigns the result to a new virtual register. The condition used to
assign directly to DstReg uses type equality (WideTy == DstTy), which
fails when DstTy = f16. As a result, DstReg is left without a
definition.
**Fix:**
After the OR-reduction loop, add a check for the case where DstTy and
WideTy have equal sizes but different types, and emit a G_BITCAST.
**Testing:**
No currently upstream target exercises `G_MERGE_VALUES` with a
floating-point destination type through this widen path, as most targets
promote f16 to s16 before legalization. The fix is therefore covered by
a unit test in `LegalizerHelperTest.cpp`, modeled after the existing
`WidenScalarMergeValuesPointer` test, which directly invokes widenScalar
on a manually constructed `f16 = G_MERGE_VALUES i8, i8` instruction and
verifies that a `G_BITCAST` is emitted as the final instruction.
https://invent.kde.org/qt/clang/llvm-project/-/commit/68449895e267174801d3b11afd957548f5796a41
Git commit 7bf1ded0e061cc388a31f4293afd527f76810ffb by GitHub (on behalf of William Tran-Viet) on 03/08/2026 at 12:23..
[libc++] Clean up headers that relied on `<optional>`'s transitive includes (#213158)
Clear out the headers in <optional> that were left in to not break
other headers, and fix them also. Also fix tests.
https://invent.kde.org/qt/clang/llvm-project/-/commit/7bf1ded0e061cc388a31f4293afd527f76810ffb
Git commit 97fd08dbaf82b35ef860bca11bb047fd60f723d5 by GitHub (on behalf of Kacper Doga) on 03/08/2026 at 12:24..
[GlobalISel] avoid G_TRUNC with floating-point G_MERGE_VALUES source (#206733)
With extended LLT, scalar LLT carry an integer/float kind information.
The `G_TRUNC(G_MERGE_VALUES)` fold in
`LegalizationArtifactCombiner::tryCombineTrunc` truncated, copied or
rebuilt a merge directly from the merge's source register.
**Problem**
When those sources are floating-point this produces artifacts with float
source operand - e.g. `i1 = G_TRUNC f32` or a rebuilt `iN =
G_MERGE_VALUES f32, ...` which are bit level integer operations and must
not take a float operand.
**Fix**
Reinterpret a floating-point merge source to an integer of the same size
via `G_BITCAST` before truncating, copying or rebuilding the merge. So
the emitted artifacts stay on integer operands. Non-float sources and
non-extended-LLT builds are unaffected.
https://invent.kde.org/qt/clang/llvm-project/-/commit/97fd08dbaf82b35ef860bca11bb047fd60f723d5
Git commit f84bacf82a153a75dbf549d8c25d6e73673ea043 by GitHub (on behalf of David Spickett) on 03/08/2026 at 12:31..
[lldb] Introduce RegisterType base class for all register type classes (#196960)
This is refactoring to prepare for
https://github.com/llvm/llvm-project/issues/87471. Where we will be
adding support for describing registers as unions and vectors. See:
https://sourceware.org/gdb/current/onlinedocs/gdb.html/Target-Description-Format.html
A union is like a C union and references other types defined in the XML.
Just like a set of register flags might reference an enum for one of
those flags.
By introducing this base class I'm making the treatment of all these
different types generic. So that when encoding them as XML we can emit
the type's dependencies recursively, and then emit the type itself.
This strategy will also be used later in RegisterTypeBuilderClang to
generate AST to represent these types.
As GDB decided to include size in enums, whenever we emit something it
will get a "user" pointer. This allows an enum type to read the size of
the register it's being attached to. No other type class requires this.
I would call this "parent" but it is not usually the parent. The
heirarchy is:
* A RegisterFlags type contains many flags.
* One of those flags has an enum as its type.
* That enum needs to query two levels up to get the RegisterFlag's size.
LLDB does not care about this enum size attribute, but GDB does so we
emit it for compatibility.
I don't expect anything other than a RegisterFlags to reference an enum
at this time. In theory, a vector's element could be an enum but I do
not know of anything available today that does this.
I'd like to support arbitrary nesting of these types, but only later
once known use cases work well.
For the time being, the generic RegisterType pointer is cast into a
RegisterFlags before use. In future this will become a switch over the
possible register types we support.
https://invent.kde.org/qt/clang/llvm-project/-/commit/f84bacf82a153a75dbf549d8c25d6e73673ea043
Git commit fccabca20c732cc93b018effa7381e2e2a6f9506 by GitHub (on behalf of Timm Baeder) on 03/08/2026 at 12:46..
[clang][bytecode] Protect against invalid C++26 string repr (#213639)
We can't call `getNumElems()` for unknown-size arrays.
https://invent.kde.org/qt/clang/llvm-project/-/commit/fccabca20c732cc93b018effa7381e2e2a6f9506
Git commit ea2933f9aae9dc0bf4bb120bb732c0758d1026fd by GitHub (on behalf of Tom Eccles) on 03/08/2026 at 12:48..
[flang][Lower] Flatten signed real sum terms (#211829)
Second part of generalisations requested in #207377.
Extend real sum reassociation to flatten unparenthesized addition and
subtraction into signed terms. Rebuild split groups with addition and
subtraction while preserving parenthesized subtrees as opaque values.
I did not observe any benchmark result changes as a result of this
patch.
Assisted-by: Codex
https://invent.kde.org/qt/clang/llvm-project/-/commit/ea2933f9aae9dc0bf4bb120bb732c0758d1026fd
Git commit d2e2626045e2380e60f51e75c39acf245572c918 by GitHub (on behalf of Louis Dionne) on 03/08/2026 at 12:53..
[libc++] Don't rely on a transitively included BYTE_ORDER in ctype_base (#213032)
Use libc++'s own _LIBCPP_BIG_ENDIAN macro instead of BYTE_ORDER, which
was relied upon from a transitive <endian.h> include on Glibc.
https://invent.kde.org/qt/clang/llvm-project/-/commit/d2e2626045e2380e60f51e75c39acf245572c918
Git commit 3ea717b891a05dd00006b51e506b30198d57f763 by GitHub (on behalf of Louis Dionne) on 03/08/2026 at 12:54..
[libc++] Add missing includes in the locale headers (#213035)
Several headers use entities from `<__locale>` but rely on picking them
up transitively, in most cases through `<ios>`. Fix this in preparation
for splitting up `<__locale>`.
https://invent.kde.org/qt/clang/llvm-project/-/commit/3ea717b891a05dd00006b51e506b30198d57f763
Git commit dbd0c2d86f02528de4940ee87137259d9b7f0b85 by GitHub (on behalf of Nikolas Klauser) on 03/08/2026 at 12:55..
[libc++] Remove opt-out of the LLVM 23 transitive includes removal (#213245)
We've removed transitive includes by default in LLVM 23, but added an
opt-in to keep the transitive includes for the release. Now that we've
branched we can remove the transitive includes unconditionally.
RFC: https://discourse.llvm.org/t/rfc-remove-unused-transitive-includes-from-the-libc-headers
https://invent.kde.org/qt/clang/llvm-project/-/commit/dbd0c2d86f02528de4940ee87137259d9b7f0b85
Git commit 3d60487f83797a10a6379669647a139e6823d3d2 by GitHub (on behalf of Yair Ben Avraham) on 03/08/2026 at 12:58..
[CIR][AArch64] Lower remaining FP16 vfma and vfms builtins (#210359)
Complete CIR lowering coverage for the remaining AArch64 NEON FP16 fused
multiply-accumulate and fused multiply-subtract builtins.
This covers ACLE wrappers from section 2.6.1.9.3:
- vfma_n_f16, vfmaq_n_f16
- vfms_f16, vfmsq_f16
- vfms_lane_f16, vfmsq_lane_f16
- vfms_laneq_f16, vfmsq_laneq_f16
- vfms_n_f16, vfmsq_n_f16
- vfmsh_lane_f16, vfmsh_laneq_f16
The existing CIR lowering paths already handle these wrappers. Move
their tests from AArch64/v8.2a-neon-intrinsics.c into
AArch64/neon/fused-multiple-fullfp16.c, add direct LLVM, CIR-to-LLVM,
and CIR coverage, and remove the superseded tests.
Strengthen the LLVM checks by tracking operands from their defining
operations and using LLVM-DAG for order-independent setup operations.
Part of #185382
https://invent.kde.org/qt/clang/llvm-project/-/commit/3d60487f83797a10a6379669647a139e6823d3d2
Git commit 2a9aa12745874b5cff513f0d60a63845e6b783af by GitHub (on behalf of Walter Lee) on 03/08/2026 at 13:13..
Bazel 8d292a7c4b952eb5e9c55ed54a17a25c85bd553c (#213661)
This fixes
https://github.com/llvm/llvm-project/commit/8d292a7c4b952eb5e9c55ed54a17a25c85bd553c
(https://github.com/llvm/llvm-project/pull/213265).
Buildkite error link:
https://buildkite.com/llvm-project/upstream-bazel/builds?commit=8d292a7c4b952eb5e9c55ed54a17a25c85bd553c
Co-authored-by: Google Bazel Bot <[email protected]>
https://invent.kde.org/qt/clang/llvm-project/-/commit/2a9aa12745874b5cff513f0d60a63845e6b783af
Git commit 53ee7b167d8aee0a75c1332ca4a6aa037e0869a0 by GitHub (on behalf of Gábor Tóthvári) on 03/08/2026 at 13:13..
[NFC][analyzer] Eliminate NodeBuilder from ExprEngine visit methods and from their utility methods (#212186)
This patch eliminates the remaining uses of the class `NodeBuilder` from
the `ExprEngine::Visit*` methods and from their utility methods such as
`evalLocation`, `evalLoad`, `CreateCXXTemporaryObject` and
`handleConstructor`.
https://invent.kde.org/qt/clang/llvm-project/-/commit/53ee7b167d8aee0a75c1332ca4a6aa037e0869a0
Git commit 981286a235471cfffbf2b18201aea926a0803b9c by GitHub (on behalf of Nicole Aschenbrenner) on 03/08/2026 at 13:21..
[OpenMP] target-fast implies teams/threads oversubscription (#205775)
Enable -fopenmp-assume-teams-oversubscription and
-fopenmp-assume-threads-oversubscription by default under
-fopenmp-target-fast. Adds driver test coverage for both.
Split out of #205325 as a standalone change.
https://invent.kde.org/qt/clang/llvm-project/-/commit/981286a235471cfffbf2b18201aea926a0803b9c
Git commit 23f0aa2f2ea35a8e9b106f97d561482cbf6f17b5 by GitHub (on behalf of Simon Pilgrim) on 03/08/2026 at 13:26..
[X86] movmsk-cmp.ll - update PR39665_c_ray test to match middle-end output (#213659)
These now lower to vXi1 reduction (as bitcast) patterns
The PR39665_c_ray_opt test folds to the same IR, so I've merged the
tests
https://invent.kde.org/qt/clang/llvm-project/-/commit/23f0aa2f2ea35a8e9b106f97d561482cbf6f17b5
Git commit 587ddb34f741ffb8fbcbc258fcfea373463f392f by GitHub (on behalf of Arseniy Obolenskiy) on 03/08/2026 at 13:26..
[SPIR-V] Parse parameterized Memory Access operands with a shared helper (#209262)
Copy printing only special cased Aligned, so alias list and scope IDs
were then misread as additional masks
https://invent.kde.org/qt/clang/llvm-project/-/commit/587ddb34f741ffb8fbcbc258fcfea373463f392f
Git commit 49ace5ab8f1846b47fdad85ac698982e9cb8cda9 by GitHub (on behalf of Ashutosh Nema) on 03/08/2026 at 13:29..
[Transforms][Utils] Test for branch weight preservation in LoopSplitUtils (#213647)
Added a lit test test for branch weight
https://invent.kde.org/qt/clang/llvm-project/-/commit/49ace5ab8f1846b47fdad85ac698982e9cb8cda9
Git commit e78503c4f017a807c23e583f8a6e3ab94d712632 by GitHub (on behalf of Arseniy Obolenskiy) on 03/08/2026 at 13:29..
[SPIR-V] Fix validation errors for function pointers with CodeSectionINTEL storage class (#192973)
CodeSectionINTEL pointers are not valid operands for
PtrCastToGeneric/GenericCastToPtr (including inside OpSpecConstantOp)
https://invent.kde.org/qt/clang/llvm-project/-/commit/e78503c4f017a807c23e583f8a6e3ab94d712632
Git commit fc381d5bf9de78cb6b477f58cf58b8b52bad55de by GitHub (on behalf of Kyungtak Woo) on 03/08/2026 at 13:37..
[bazel] Export TripleName.def and get_triple_system_name.py in LLVM overlay (#213602)
The TargetParser lit regression test
(`llvm/test/tools/TargetParser/get-triple-system-name.test`) runs
`get_triple_system_name_test.py`, which imports
`get_triple_system_name.py` from `llvm/utils/` and reads
`TripleName.def` from `llvm/include/llvm/TargetParser/`.
When executing lit regression tests in downstream sandboxed build
systems, the test fails with `ModuleNotFoundError: No module named
'get_triple_system_name'` because these standalone files are located
outside the test directory and are not staged into the test runfiles
sandbox.
Add `TripleName.def` and `get_triple_system_name.py` to `exports_files`
in the overlay so downstream builds can reference them as test runfile
dependencies.
Assited by: Gemini
https://invent.kde.org/qt/clang/llvm-project/-/commit/fc381d5bf9de78cb6b477f58cf58b8b52bad55de
Git commit d2fcb0c9e11f8d8bedc45db0aeba9e0a53141fe5 by GitHub (on behalf of Timm Baeder) on 03/08/2026 at 13:47..
[clang][bytecode] Handle multiple base paths in dynamic_cast (#213592)
This can happen via virtual bases.
Fixes https://github.com/llvm/llvm-project/issues/213569
https://invent.kde.org/qt/clang/llvm-project/-/commit/d2fcb0c9e11f8d8bedc45db0aeba9e0a53141fe5
Git commit c4203d7b42554379f048e21124757498a67434a9 by GitHub (on behalf of Simon Pilgrim) on 03/08/2026 at 14:10..
[X86] movmsk-cmp.ll - update PR67287 test to match middle-end reduction output (#213671)
This now lowers to a vXi1 reduction (as bitcast) pattern
https://invent.kde.org/qt/clang/llvm-project/-/commit/c4203d7b42554379f048e21124757498a67434a9
Git commit 4905109b00e6916a310cf7c521bd8df19c0d4a11 by GitHub (on behalf of Spencer Bryngelson) on 03/08/2026 at 14:21..
[OpenMP] Analyze the loop-body callback of the static-loop runtime entries (#211287)
Fixes #211132. Also removes the trigger for #198621, see below.
`AAKernelInfo` treats the loop body passed to the
`__kmpc_*_static_loop_*` entries as opaque and records an unknown
parallel region for it, per the TODO at the site. Consequently
`NestedParallelism` is true for any kernel whose parallel region
contains a device workshare loop, and `MayUseNestedParallelism` is
written to the kernel environment as 1 where it should be 0.
The callback is a direct function operand at the callsite, so resolve it
and consult its `AAKernelInfo`, exactly as the `__kmpc_parallel_60`
handling already does for its parallel-region operand a few lines away.
Only record an unknown region when it does not resolve, or does reach
parallel regions. The SPMD-izability half of the TODO is left alone.
Only flang lowers device workshare loops through these entries; clang
emits `__kmpc_for_static_init_4` plus an explicit loop, which the
preceding case already handles. So flang kernels get 1 and clang kernels
get 0 on identical source. Controlled pair, flang, gfx90a:
| construct | runtime loop entry | before | after |
|---|---|---|---|
| `!$omp target parallel` | none | 0 | 0 |
| `!$omp target parallel do` | `__kmpc_for_static_loop_4u` | 1 | **0** |
What the 1 costs. It stops `config::mayUseNestedParallelism()` folding,
so the serialized branch in `__kmpc_parallel_60` stays live and carries
its own call to the microtask. After `__kmpc_parallel_60` is inlined
into the kernel there are then two calls to the outlined region rather
than one, `isSoleCallToLocalFunction` is false, and
`LastCallToStaticBonus` never applies. On AMDGPU that is 15000 x 11 =
165000; the analysis starts at -165045 with one callsite and -45 with
two. With two the region stays out of line and the kernel is no longer a
leaf.
`-Rpass-analysis=kernel-resource-usage`, VGPRs / scratch / occupancy:
| | before | after |
|---|---|---|
| reproducer from #211132, gfx90a | 212 / 48 B / 2 | **94 / 0 / 5** |
| WENO5 + HLLC NEQ=8, gfx942 | 196 / 64 B / 2 | **110 / 0 / 4** |
| NEQ=16 | 214 / 328 B / 2 | **138 / 0 / 3** |
| NEQ=24 | 196 / 456 B / 2 | **110 / 392 B / 4** |
End-to-end on gfx942 (MI325X), 1M cells, best of 50, Mcell/s, checksums
bit-identical: 1.35x, 1.47x, 1.28x at NEQ=8/16/24. Baseline run-to-run
spread across jobs is wider than the patched one, so treat the resource
numbers above, which are deterministic, as the primary evidence.
For #198621: step 2 of that root cause identifies the same
`MayUseNestedParallelism=1` as what prevents LTO folding
`omp_get_num_threads()` into a register read, which is what leaves
`DistributeFor` with `NumThreads=1` and skips a suffix of iterations.
Scalar kernels are immune there because they get 0. This refines the
field for the array-expression kernels too, so it addresses that cause
rather than the symptom.
Testing: added `spmdization_kernel_env_static_loop.ll`, which covers
both directions, a callback with no parallel region refining to 0 and a
callback that does contain one staying at 1. It fails without the patch.
`llvm/test/Transforms` (11676) and `llvm/test/CodeGen/AMDGPU` (4920),
16596 tests, 14668 passed with 39 expected failures and no regression.
The one failure, `Transforms/ThinLTOBitcodeWriter/no-type-md.ll`, is
pre-existing and fails identically with the patch reverted.
This affects performance-critical applications on large AMD GPU
supercomputers, including [MFC](https://github.com/MFlowCode/MFC).
All numbers above come from the validated reproducers attached to
#211132 and are independently reproducible; they stand on their own.
This was found and root-caused with the assistance of AI tools.
https://invent.kde.org/qt/clang/llvm-project/-/commit/4905109b00e6916a310cf7c521bd8df19c0d4a11
Git commit f7075d0da225b3de1cc83345a3a74d2f310d1057 by GitHub (on behalf of Jan Trusiłło) on 03/08/2026 at 14:40..
[offload] add nodiscard support to offload-tblgen and mark ol_errc_t (#209727)
Offload API functions may fail with error codes that shouldn't be
ignored. Most notably, if `olInit` fails and its error return value is
ignored, it is easy to use the library in an invalid uninitialized
state, which can and has caused confusion. In those cases, it may be
useful to have the ability to mark some API function with
`[[nodiscard]]`
This PR adds an optional `nodiscard` property to offload-tblgen's
`Function`, `Enum`, and `Struct`. If set, an `OL_NODISCARD` macro is
emitted, which expands to `[[nodiscard]]` on >=C++17 and >=C23, and to
nothing otherwise.
`nodiscard` is set for `ol_errc_t`, meaning every call to a function
that returns it will emit a compiler warning if the return value is
ignored and the TU is compiled on a supported language mode.
`libsycl` and `llvm-gpu-loader` still build cleanly and are unaffected
by the change.
Worth considering: should there be an opt-out (`#define
OL_DISABLE_NODISCARD` or similar)?
Assisted-by: Claude
https://invent.kde.org/qt/clang/llvm-project/-/commit/f7075d0da225b3de1cc83345a3a74d2f310d1057
Git commit deecdb92e1600c47b0dad4a13730440c7dbe7c17 by GitHub (on behalf of Alexey Bataev) on 03/08/2026 at 14:51..
[SLP][NFC]Add extra test with alternate add/sub vectorization, NFC
Reviewers:
Pull Request: https://github.com/llvm/llvm-project/pull/213693
https://invent.kde.org/qt/clang/llvm-project/-/commit/deecdb92e1600c47b0dad4a13730440c7dbe7c17
Git commit 58f386207ac8dca5ad4729a3ba9e6f448fba99c3 by GitHub (on behalf of Ivan R. Ivanov) on 03/08/2026 at 14:55..
[offload] Remove `omptarget` references from tests (#208205)
Make check lines more generic so that we can move and rename components
without breaking the tests
This is in preparation for splitting off parts of libomptarget into
libompaccsupport, which will be used by both OpenACC and OpenMP. Some
debug prints will be printed from `ompaccsupport` and not `omptarget`,
thus the need for this change.
https://invent.kde.org/qt/clang/llvm-project/-/commit/58f386207ac8dca5ad4729a3ba9e6f448fba99c3
Git commit dfcd28df1d80c1056aa820bd148e6dba42166945 by GitHub (on behalf of blazej-smorawski) on 03/08/2026 at 14:57..
[offload] Add `dlwrap::loaded` function to check for optional symbols (#210737)
This PR adds a new template into `dlwrap` namespace that can be used to
check if a symbol was correctly loaded. It adds and easy way to see if
version of shared object in a system has required capability. We could
use it to improve prefetch in CUDA backend as noted
[here](https://github.com/llvm/llvm-project/blob/main/offload/plugins-nextgen/cuda/src/rtl.cpp#L912)
without breaking compatibility with older platforms using CUDA older
than 13.
In the case of prefetch, the new `dlwrap` API could be used like:
```cpp
bool BatchedPrefetchAvailable = dlwrap::loaded<cuMemPrefetchBatchAsync>();
if (BatchedPrefetchAvailable)
cuMemPrefetchAsync(....)
else
// Current implementation
```
Small note, to implement the prefetch we will also have to make loading
of the symbols optional inside plugins too. This would require to change
it
[here](https://github.com/llvm/llvm-project/blob/main/offload/plugins-nextgen/cuda/dynamic_cuda/cuda.cpp#L176),
but I think that the change can be a part of a PR that implements
prefetch.
https://invent.kde.org/qt/clang/llvm-project/-/commit/dfcd28df1d80c1056aa820bd148e6dba42166945
Git commit 3edb821ef483d91b99defd7297a724ab32f12457 by GitHub (on behalf of Simon Pilgrim) on 03/08/2026 at 15:01..
[X86] vector-compare-all_of/any_of - updates tests to use reduction intrinsics (#213683)
These more closely match middle-end IR and currently expand to the
existing shuffle/bitcast patterns.
https://invent.kde.org/qt/clang/llvm-project/-/commit/3edb821ef483d91b99defd7297a724ab32f12457
Git commit e2c3b4e03a763d4a83cbc1176c075f082c3e966e by GitHub (on behalf of Sergey Semenov) on 03/08/2026 at 15:04..
[libsycl][Unit] Tighten mock liboffload API argument checks (#211035)
Prior to this patch, unit test default actions for mock liboffload
returned errors when receiving invalid arguments. There are only a few
valid scenarios where the runtime should expect and handle error codes
returned by liboffload (for example, checking whether a pointer is USM
or not). In most cases, the calls should not be made with invalid
arguments by libsycl at all, and especially not with the type of invalid
arguments that we can check for in default actions, like nullptrs or
invalid size values.
This patch changes such default action checks to trigger test failures
directly instead of mocking error codes.
https://invent.kde.org/qt/clang/llvm-project/-/commit/e2c3b4e03a763d4a83cbc1176c075f082c3e966e
Git commit 877c39aa8e15abe05c4c9562743d49b29689f2ce by GitHub (on behalf of Abid Qadeer) on 03/08/2026 at 15:05..
[OpenMPIRBuilder] Handle empty blocks in restoreIPandDebugLoc (#212535)
`restoreIPandDebugLoc` previously only recovered a debug location when
the insertion block was non-empty, using its last instruction. For an
empty block it left the current debug location unchanged so instructions
emitted afterwards could have wrong debug location.
This PR enhance `restoreIPandDebugLoc` to also handle the empty-block
case: when the insertion point is at the end of an empty block,
synthesize a location scoped to the parent function's subprogram
provided the function has debug metadata.
This helps us get a valid debug location when we switch to `CodeGenIP`
in `emitOffloadingArrays` even when `CodeGenIP` is pointing to an empty
`BB`.
Fixes https://github.com/llvm/llvm-project/issues/212488
Co-authored-by: Cursor <[email protected]>
https://invent.kde.org/qt/clang/llvm-project/-/commit/877c39aa8e15abe05c4c9562743d49b29689f2ce
Git commit 469dcdfd46d5102b1cab0fabf45c1ae1c5081eb0 by GitHub (on behalf of Ivan R. Ivanov) on 03/08/2026 at 15:12..
[offload][test] Instruct clang-format to not reflow comments (#213696)
Without this, clang-format attempts to reflow check lines in tests,
resulting in broken tests.
https://invent.kde.org/qt/clang/llvm-project/-/commit/469dcdfd46d5102b1cab0fabf45c1ae1c5081eb0
Git commit 786f2efa16e3570f445da680a1a0d68dfa2daaa6 by GitHub (on behalf of Ian Anderson) on 03/08/2026 at 15:21..
[libc++][CI] run-buildbot and libcxx-lit need a way to pass the paths to cmake and ninja (#213511)
macOS/Xcode don't have cmake or ninja anywhere in a default PATH, so
run-buildbot and libcxx-lit fail unless you do some PATH surgery before
running them. Allow passing them as environment variables instead, so
run-buildbot can be invoked as `CMAKE=$(xcrun --find cmake)
NINJA=$(xcrun --find ninja) CC=$(xcrun --find clang) CXX=$(xcrun --find
clang++) run-buildbot` on macOS. Allow cmake to be passed to libcxx-lit
in a similar fashion.
https://invent.kde.org/qt/clang/llvm-project/-/commit/786f2efa16e3570f445da680a1a0d68dfa2daaa6
Git commit 17fd0c3e29074ed21b3de6cf850d5dc23c702bd0 by GitHub (on behalf of Jonas Devlieghere) on 03/08/2026 at 15:25..
[lldb][test] Give a directly created lldb-dap session the init commands (#213553)
create_debug_adapter passes the commands that carry the configuration
the test suite was invoked with, and a test that builds a
DebugAdapterServer itself got none of them, so that session ran
unconfigured. It matters wherever the suite configures the debugger
through settings, such as pointing a platform at the runtime it
launches.
https://invent.kde.org/qt/clang/llvm-project/-/commit/17fd0c3e29074ed21b3de6cf850d5dc23c702bd0
Git commit 7279e4042d207b077ca752af7b982bd6e745b7f4 by GitHub (on behalf of original-cooling-space) on 03/08/2026 at 15:26..
[benchmark] Fix -Wunused-but-set-variable warning in basic_test (#213637)
Fix a build error when building benchmark unit tests with modern
GCC/Clang compilers under strict warning options (-Werror).
In `test/basic_test.cc`, the variable `sum` in `BM_OneTemplateFunc` was
assigned but never read, triggering `-Wunused-but-set-variable`.
Silenced the warning by marking sum with `[[maybe_unused]]`, preserving
the benchmark function's logic while ensuring clean build output.
### Description
Fixes a build error when compiling `third-party/benchmark` unit tests
with modern GCC/Clang compilers under `-Werror`.
In `test/basic_text.cc`, the variable `sum` in `BM_OneTemplatcFunc` was
assigned but never read, triggering `-Wunused-but-set-variable`.
### Solution
Silenced the warning by marking sum with `[[maybe_unused]]`, preserving
the benchmark function's logic while ensuring clean build output.
### Test Plan
1. Configured CMake with `-DBENCHMARK_ENABLE_TESTING=ON` and
`-DBENCHMARK_ENABLE_WERROR=ON`.
2. Built the target: `cmake --build build -j$(nproc)` -> Build succeed
with zero warnings/errors.
3. Executed unit tests: `ctest --test-dir build` -> 100% test passed.
### Environment
- **OS**: Linux (6.6.87.2-microsoft-standard-WSL2)
- **Compiler**: Clang 22.1.8 / GCC 16.1.1 20260728
- **CMake**: 4.4.2
https://invent.kde.org/qt/clang/llvm-project/-/commit/7279e4042d207b077ca752af7b982bd6e745b7f4
Git commit e7713ee70b87a9ca1b5f38e090bf90677365a43a by GitHub (on behalf of Andrew Ng) on 03/08/2026 at 15:30..
[dyndbg][llvm][ELF] Add ELF section type for dynamic debugging (#208803)
Add ELF section type `SHT_LLVM_DYNDBG_ELF` for embedding the "inner"
unoptimized dynamic debugging ELF object within the "outer" optimized
ELF object.
RFC: https://discourse.llvm.org/t/90113
https://invent.kde.org/qt/clang/llvm-project/-/commit/e7713ee70b87a9ca1b5f38e090bf90677365a43a
Git commit c9d04c5ac99338be132189e33c7a40791fb51265 by GitHub (on behalf of Karim Alweheshy) on 03/08/2026 at 15:34..
[lld] Report temporal BP profile resolution (#212127)
https://invent.kde.org/qt/clang/llvm-project/-/commit/c9d04c5ac99338be132189e33c7a40791fb51265
Git commit 4484148c6dd12f3b0b1cefeee30f7d18ad8c9999 by Petar Avramovic on 03/08/2026 at 15:36..
AMDGPU/GlobalISel: Precommit tests for upcoming bug fix
Here we have:
artifact combiner creating one element unmerge and
unmerge lowering of FP source using FP type for bit twiddling.
https://invent.kde.org/qt/clang/llvm-project/-/commit/4484148c6dd12f3b0b1cefeee30f7d18ad8c9999
Git commit e7b958fb71a2e3277b488fc2a4a197e9140942de by Petar Avramovic on 03/08/2026 at 15:37..
GlobalISel: Add type size guards in tryCombineMergeLike
Bug in LegalizationArtifactCombiner when:
DstSize < UnmergeSrcSize case can create unmerge with one element.
DstSize > UnmergeSrcSize case can end up attempting to create merge
with one source element and hits assert(TmpVec.size() > 1).
https://invent.kde.org/qt/clang/llvm-project/-/commit/e7b958fb71a2e3277b488fc2a4a197e9140942de