LLVM/project 5bfcaebclang/lib/Headers riscv_packed_simd.h, clang/test/CodeGen/RISCV rvp-intrinsics.c

[RISCV][P-ext] Support Packed Store (#223619)

See also
https://github.com/riscv/riscv-p-spec/blob/master/P-ext-intrinsics.adoc#packed-store.
DeltaFile
+183-0clang/test/CodeGen/RISCV/rvp-intrinsics.c
+66-0cross-project-tests/intrinsic-header-tests/riscv_packed_simd.c
+41-0clang/test/Sema/riscv-pst-pointer-types.c
+22-0clang/lib/Headers/riscv_packed_simd.h
+312-04 files

LLVM/project 57186afllvm/include/llvm/IR PassManager.h, llvm/lib/IR PassManager.cpp

[NewPM] Add helper function to skip for opt-bisect

With the introduction of CodeGen passes to the NewPM infrastructure, we
get the concept of required passes that perform optimizations and want
to skip them when running under opt bisect. This occurs for passes like
SelectionDAG and StackColoring. Add a helper function to make it easy to
query, although make it specific to opt bisect unlike the LegacyPM
skipFunction. A helper function is slightly more convenient (i.e., no
need to forward the pass name explicitly).

Reviewers: nikic, arsenm, aeubanks

Pull Request: https://github.com/llvm/llvm-project/pull/223486
DeltaFile
+20-0llvm/lib/IR/PassManager.cpp
+8-0llvm/include/llvm/IR/PassManager.h
+28-02 files

LLVM/project a2239cbllvm/lib/CodeGen/AsmPrinter AsmPrinter.cpp, llvm/test/CodeGen/RISCV cheri-global-cap-init.ll

[CHERI][RISCV][AsmPrinter] Use pointer index size rather than pointer size in AsmPrinter constant lowering. (#220100)

This prevents a crash due to APInt width mismatches during
accumulateConstantOffset for CHERI targets.
DeltaFile
+14-0llvm/test/CodeGen/RISCV/cheri-global-cap-init.ll
+1-1llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
+15-12 files

LLVM/project b691225clang/test/CodeGen exception-model-flag.c, clang/test/CodeGen/WebAssembly exception-model-flag.c

clang: Fix exception model flag tests if webassembly isn't build (#223770)

The wasm and emscripten RUN lines require the WebAssembly backend due to
the use of -mllvm -wasm-enable-eh, until that flag is fully replaced with
the new exception model flag.

Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
DeltaFile
+16-0clang/test/CodeGen/WebAssembly/exception-model-flag.c
+0-8clang/test/CodeGen/exception-model-flag.c
+16-82 files

LLVM/project ba2fc84llvm/lib/Target/AArch64 SVEShuffleOpts.cpp

AArch64: Avoid dependin on createDataLayout in a pass

This should read directly from the context IR's module.
DeltaFile
+3-3llvm/lib/Target/AArch64/SVEShuffleOpts.cpp
+3-31 files

LLVM/project b0f5017flang-rt/lib/cuda allocator.cpp allocatable.cpp, flang-rt/unittests/Runtime/CUDA AllocatorCUF.cpp Allocatable.cpp

[flang][cuda][NFC] Move CUFDeviceIsActive function to the right place (#223453)

The definition and declaration were done in different files (descriptor
and allocator). Move all to allocatable as this check is used for the
automatic deallocation.
DeltaFile
+56-0flang-rt/lib/cuda/allocatable.cpp
+0-55flang-rt/lib/cuda/allocator.cpp
+11-2flang/lib/Optimizer/Builder/Runtime/CUDA/Support.cpp
+1-10flang/lib/Optimizer/Builder/Runtime/CUDA/Descriptor.cpp
+9-0flang-rt/unittests/Runtime/CUDA/Allocatable.cpp
+0-8flang-rt/unittests/Runtime/CUDA/AllocatorCUF.cpp
+77-754 files not shown
+86-8310 files

LLVM/project a3d2f4bmlir/lib/Dialect/Linalg/Transforms PadTilingInterface.cpp, mlir/test/Dialect/Linalg pad-neutral.mlir

[[mlir][linalg] Infer reduction-neutral padding values in rewriteAsPaddedOp (#216517)

**Problem**: 
with no explicit options.paddingValues, rewriteAsPaddedOp padded every
operand with zero — silently corrupting reductions (a padded
maximumf/mulf element gets combined).

**Change**: 
Added a new public linalg::inferPaddingValues(builder, toPad) to pick a
semantics-preserving value per operand:
  - no reduction dim → zero;
  - contraction → zero (0 annihilates through the multiply);
- other reductions → the combiner's neutral (-inf for maximumf, 1 for
mulf, …), found via matchReduction so the real accumulator combiner is
used.

rewriteAsPaddedOp calls it when options.paddingValues is empty. If no
value can be inferred, it returns failure() with the error "could not
infer a padding value"; the caller is then expected to determine the

    [6 lines not shown]
DeltaFile
+368-0mlir/test/Dialect/Linalg/pad-neutral.mlir
+157-6mlir/lib/Dialect/Linalg/Transforms/PadTilingInterface.cpp
+525-62 files

LLVM/project a97b2abllvm/docs SecurityTransparencyReports.rst CodingStandards.md, utils/docs/llvm_sphinx/ext absolute_links.py

[docs] Prefer portable Markdown documentation links

Document and enforce source-relative Markdown links for documents and
generated heading anchors. Diagnose nonportable project: and generated HTML
links, and convert the existing LLVM Markdown links to the preferred form.
DeltaFile
+103-2utils/docs/llvm_sphinx/ext/absolute_links.py
+38-2llvm/docs/SphinxQuickstartTemplate.md
+20-0utils/docs/llvm_sphinx/ext/absolute_links_test/markdown.md
+6-6llvm/docs/MergeFunctions.md
+3-3llvm/docs/CodingStandards.md
+2-2llvm/docs/SecurityTransparencyReports.rst
+172-1522 files not shown
+197-3728 files

LLVM/project 2323ab2llvm/utils update_test_checks.py

[UTC] Strip only standalone positional %s in update_test_checks.py (#221153)

Previously, update_test_checks.py used tool_cmd_args.replace("%s", "")
to strip the input file when passing the IR via stdin. However, this
blindly removed "%s" from any option argument, leaving an empty value
(e.g., -lowertypetests-read-summary=).

Update the argument stripping to only remove standalone positional
"< %s" or "%s", preserving option arguments with "%s" values so they can
be expanded via common substitutions.

This enables update_test_checks.py to work for tests such as
llvm/test/Transforms/LowerTypeTests/cfi-jumptable-hotness-summary.ll,
which passes -lowertypetests-read-summary=%s on the RUN line.

Assisted-by: Gemini
DeltaFile
+5-1llvm/utils/update_test_checks.py
+5-11 files

LLVM/project 5fbcd6ellvm/cmake config-ix.cmake, llvm/include/llvm/Config config.h.cmake

[CMake] Prune dead and unnecessary try_compiles from config.h (#223765)

This relands the change directly on `main` after #223600 was
accidentally
merged into its stacked base branch. This reuses the approvals from
@aengelke and @MaskRay on #223600.

Several config-ix checks either have no consumer or can be performed
directly by the source that needs the feature. Remove six compiler
invocations from a typical Linux configure:

* HAVE_PTHREAD_MUTEX_LOCK has been unused since LLVM switched its mutex
implementation to std::recursive_mutex in 2019.
* The Linux magic-header results have never been propagated to config.h,
so CMake builds already use Path.inc's fallback constants.
* FE_ALL_EXCEPT and FE_INEXACT can be tested directly after including
cfenv.
* The Valgrind and CrashReporter headers can be detected with
__has_include in their only consuming translation units.

    [8 lines not shown]
DeltaFile
+0-17utils/bazel/llvm_configs/config.h.cmake
+0-17utils/bazel/llvm-project-overlay/llvm/include/llvm/Config/config.h
+0-17llvm/include/llvm/Config/config.h.cmake
+0-15llvm/cmake/config-ix.cmake
+6-8llvm/lib/Support/Valgrind.cpp
+4-9utils/bazel/llvm-project-overlay/llvm/config.bzl
+10-834 files not shown
+16-10410 files

LLVM/project 88cab6bllvm/test/TableGen RuntimeLibcallEmitter-variant-beats-exclusion.td, llvm/utils/TableGen/Basic RuntimeLibcallsEmitter.cpp

RuntimeLibcallsEmitter: Let a consumer's own library variant beat its exclusion (#221953)

A target can pull a shared library via LibraryRef<Lib, [impls]> to drop
some impls, then re-add its own versions through a same-name library variant
guarded on that target. Previously the exclusion's setUnavailable calls were
emitted at the end of setAvailableLibFuncs_<name>, after every variant, so they
clobbered the target's own re-adds.

Defer emitting a variant until after the exclusions when it re-adds an
impl its own consumer excludes (same predicates), so the target's re-add wins
while the exclusion still suppresses every other variant's contribution.

This is yet unused infrastructure for future changes.

Co-authored-by: Claude (Opus 4.8) <noreply at anthropic.com>
DeltaFile
+70-26llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp
+55-0llvm/test/TableGen/RuntimeLibcallEmitter-variant-beats-exclusion.td
+125-262 files

LLVM/project bb08625clang/lib/Driver/ToolChains/Arch ARM.cpp, clang/test/Driver eabi.c

CodeGen: Remove TargetOptions::EABIVersion (#222672)

The field's only effect was gating the __aeabi_mem*[4|8] libcalls via
the IsEABI4/IsEABI5 predicates. That distinction is derivable from the
triple's environment, so replace the two predicates with a single
triple-derived IsEABIVersion and delete the field.

The clang -meabi option and clang::TargetOptions::EABIVersion are
retained (now codegen-inert); the llc/opt -meabi flag is removed. -meabi
now only takes effect on triples with a bare-EABI/GNU environment pair
(arm-none-eabi <-> gnueabi), which is the only case with a triple
representation.

Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
DeltaFile
+32-0clang/lib/Driver/ToolChains/Arch/ARM.cpp
+4-21llvm/test/CodeGen/ARM/arm-eabi.ll
+13-6clang/test/Driver/eabi.c
+7-11llvm/include/llvm/IR/RuntimeLibcalls.h
+0-17llvm/lib/Target/ARM/ARMTargetMachine.cpp
+7-7llvm/lib/IR/RuntimeLibcalls.cpp
+63-6232 files not shown
+123-14938 files

LLVM/project 00323c9clang/include/clang/CIR/Dialect/IR CIROps.td, clang/lib/CIR/Dialect/IR CIRAttrs.cpp CIRDialect.cpp

[CIR][EH] Add dialect elements for dynamic exception specification (#223503)

This change introduces the CIR dialect elements that will be needed to
implement dynamic exception specification handling. At this point
nothing generates any of these elements, and they are not handled in CFG
flattening or EH ABI lowering. Those will be implemented in follow-up
changes.

See clang/docs/CIR/CleanupAndEHDesign.md for the design of this feature.

Assisted-by: Cursor / various models
DeltaFile
+183-1clang/test/CIR/IR/invalid-try-catch.cir
+150-0clang/test/CIR/IR/try-catch.cir
+143-4clang/lib/CIR/Dialect/IR/CIRDialect.cpp
+107-1clang/include/clang/CIR/Dialect/IR/CIROps.td
+81-0clang/test/CIR/Transforms/eh-abi-lowering-eh-spec-nyi.cir
+30-14clang/lib/CIR/Dialect/IR/CIRAttrs.cpp
+694-205 files not shown
+821-2711 files

LLVM/project 8ef6955clang/docs OverflowBehaviorTypes.md, clang/include/clang/AST TypeBase.h

[Clang] Keep qualifiers outside of OverflowBehaviorType nodes (#222190)

`__typeof_unqual__` wasn't stripping `const` off of an overflow behavior
type:

```c
  __typeof_unqual__(const __ob_trap int) x; // '__ob_trap const int'
```

The canonical type was always right, so `x` really is writable -- we
just printed it as const, which is the opposite of the truth.

`getOverflowBehaviorType()` hoisted qualifiers out for the canonical
type but stored the underlying type verbatim in the sugar node, so
`const __ob_trap int` became `OBT{const int}` with nothing qualified at
the `QualType` level. `getUnqualifiedType()` checks the canonical type
to decide there's something to strip, then strips it by desugaring one
step at a time. `OverflowBehaviorType` isn't sugar, so that walk
dead-ends on it and the qualifiers never come off.

    [29 lines not shown]
DeltaFile
+79-0clang/test/Sema/overflow-behavior-qualifiers.c
+36-4clang/docs/OverflowBehaviorTypes.md
+22-2clang/lib/AST/Type.cpp
+5-2clang/include/clang/AST/TypeBase.h
+3-3clang/test/SemaCXX/sugar-common-types.cpp
+2-1clang/lib/AST/ASTContext.cpp
+147-122 files not shown
+149-148 files

LLVM/project 8491ff8clang/test/CodeGen exception-model-flag.c, clang/test/CodeGen/WebAssembly exception-model-flag.c

clang: Fix exception model flag tests if webassembly isn't build

The wasm and emscripten RUN lines require the WebAssembly backend due to the
use of -mllvm -wasm-enable-eh, until that flag is fully replaced with the
new exception model flag.

Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
DeltaFile
+16-0clang/test/CodeGen/WebAssembly/exception-model-flag.c
+0-8clang/test/CodeGen/exception-model-flag.c
+16-82 files

LLVM/project 36de8b2llvm/lib/Target/X86 X86ISelLowering.cpp, llvm/test/CodeGen/X86 recip-sqrt-estimate-illegal-scalar-types.ll recip-sqrt-estimate-illegal-types.ll

[X86] Require legal result types for f32 estimates

The single-precision paths in `getRecipEstimate` and `getSqrtEstimate`
match a fixed set of scalar and vector f32 types, then check the
corresponding subtarget features. Those checks do not imply that the
result type is legal. Soft-float makes these result types illegal. Scalar
f32 is also illegal on a 32-bit SSE1 target without SSE2 or x87. The hooks
can then build an X86-specific estimate node with an illegal result type
before type legalization. Type legalization has no rule for that node, so
compilation fails.

Require a legal result type before entering the single-precision estimate
paths. The f16 paths in these hooks already require a legal type. After
this patch, the f32 paths match that behavior. The hooks return no estimate
for an illegal result type, so the original division or square root stays
in the DAG and follows its normal lowering. Estimate code generation for
legal result types is unchanged.

Fixes https://github.com/llvm/llvm-project/issues/217801

Assisted-by: Claude Opus 5, GPT-5.6 Sol.
DeltaFile
+605-0llvm/test/CodeGen/X86/recip-sqrt-estimate-illegal-types.ll
+37-0llvm/test/CodeGen/X86/recip-sqrt-estimate-illegal-scalar-types.ll
+10-9llvm/lib/Target/X86/X86ISelLowering.cpp
+652-93 files

LLVM/project 3714d50llvm/lib/Transforms/Vectorize SLPVectorizer.cpp, llvm/test/Transforms/SLPVectorizer/X86 struct-return-splat-gathered-scalars.ll

[SLP]Fix insert point for struct-call extractvalue entries with multi-block scalars

Emit the vector extractvalue right after the vectorized call it depends
on, so it dominates all uses.

Fixes #223726

Reviewers: 

Pull Request: https://github.com/llvm/llvm-project/pull/223766
DeltaFile
+73-0llvm/test/Transforms/SLPVectorizer/X86/struct-return-splat-gathered-scalars.ll
+12-0llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+85-02 files

LLVM/project d0e5550openmp/docs index.md CommandLineArgumentReference.md, openmp/docs/design Runtimes.md

[OpenMP][docs] Finish MyST migration for OpenMP docs (#222194)

This was prepared with rst2myst plus LLM-assisted cleanup. The main
manual intervention was porting CommandLineArgumentReference.(rst|md) to
the semantic [`option`
directive](https://www.sphinx-doc.org/en/master/usage/domains/standard.html#directive-option),
which causes some rendering differences.

Tracking issue: #201242
See the [migration guide] for more information. 

[migration guide]:
https://llvm.org/docs/SphinxQuickstartTemplate.html#markdown-migration-guidelines
This is a stacked PR based on #222191, which is a standalone commit that
renames *.rst -> *.md before this PR lands for history preservation
purposes.

Please spot check my work and approve if it looks good. You can use the
HTML links below to confirm it renders properly.

    [179 lines not shown]
DeltaFile
+760-835openmp/docs/design/Runtimes.md
+155-177openmp/docs/SupportAndFAQ.md
+186-138openmp/docs/CommandLineArgumentReference.md
+104-109openmp/docs/index.md
+83-93openmp/docs/openacc/OpenMPExtensions.md
+61-64openmp/docs/remarks/OptimizationRemarks.md
+1,349-1,41629 files not shown
+1,976-2,09835 files

LLVM/project 73b9d53openmp/docs CommandLineArgumentReference.rst CommandLineArgumentReference.md, openmp/docs/design Runtimes.rst Runtimes.md

[OpenMP][docs] Rename reStructuredText files to Markdown (#222191)

Tracking issue: #201242
See the [migration guide] for more information. 

[migration guide]:
https://llvm.org/docs/SphinxQuickstartTemplate.html#markdown-migration-guidelines

This is the initial straight rename commit. It will probably break the
docs build, but it has to be a separate PR for blame preservation
purposes.

Validation:

- Confirmed this commit contains exactly 34 `.rst` to `.md` renames and
no content changes.
- The complete stacked migration is validated in the follow-up PR.
DeltaFile
+0-1,680openmp/docs/design/Runtimes.rst
+1,680-0openmp/docs/design/Runtimes.md
+0-332openmp/docs/SupportAndFAQ.rst
+332-0openmp/docs/SupportAndFAQ.md
+0-186openmp/docs/CommandLineArgumentReference.rst
+186-0openmp/docs/CommandLineArgumentReference.md
+2,198-2,19862 files not shown
+3,838-3,83868 files

LLVM/project 0c8394dutils/bazel MODULE.bazel MODULE.bazel.lock, utils/bazel/llvm-project-overlay/llvm config.bzl

[bazel] Use new rules_cc API to determine musl targeting (#223549)

This avoids requiring hermetic-llvm in the public BUILD file API.
Downstream users need to update to this version of rules_cc
DeltaFile
+131-22utils/bazel/MODULE.bazel.lock
+2-2utils/bazel/llvm-project-overlay/llvm/config.bzl
+2-2utils/bazel/MODULE.bazel
+135-263 files

LLVM/project 5cafb66llvm/cmake/modules AddLLVM.cmake

[CMake] Factor check- target deps to reduce build.ninja size by 45%

Many LLVM developers are not aware, but our lit CMake logic creates a
check-* target for every eligible subdirectory inside a lit test suite.
There are thousands of these targets; in the benchmark configuration:

```
❯ ninja -C build -t targets all | grep '^check-' | wc -l
2667
```

Chris Bieneman originally added this feature in March 2015. The original
change suppressed these targets for Xcode and Visual Studio because the
target clutter hurt IDE usability; rL344555 later generalized that
behavior behind LLVM_ENABLE_IDE.

When using the Ninja generator, each of these check-${proj}-${subdir}
targets repeats its suite's transitive test dependencies, like so:


    [52 lines not shown]
DeltaFile
+62-12llvm/cmake/modules/AddLLVM.cmake
+62-121 files

LLVM/project 75fa547llvm/cmake config-ix.cmake, llvm/include/llvm/Config config.h.cmake

[CMake] Remove unused configuration probes

Several config-ix checks either have no consumer or can be performed directly
by the source that needs the feature. Remove six compiler invocations from a
typical Linux configure:

* HAVE_PTHREAD_MUTEX_LOCK has been unused since LLVM switched its mutex
  implementation to std::recursive_mutex in 2019.
* The Linux magic-header results have never been propagated to config.h, so
  CMake builds already use Path.inc's fallback constants.
* FE_ALL_EXCEPT and FE_INEXACT can be tested directly after including cfenv.
* The Valgrind and CrashReporter headers can be detected with __has_include in
  their only consuming translation units.

Also remove the obsolete definitions from the GN and Bazel configurations.

In a fresh minimal LLVM configure, CMake profiling attributed 2067.1 ms to 45
config-ix probes before this change and 1846.9 ms to 39 probes after it.


    [6 lines not shown]
DeltaFile
+0-17utils/bazel/llvm_configs/config.h.cmake
+0-17utils/bazel/llvm-project-overlay/llvm/include/llvm/Config/config.h
+0-17llvm/include/llvm/Config/config.h.cmake
+0-15llvm/cmake/config-ix.cmake
+6-8llvm/lib/Support/Valgrind.cpp
+4-9utils/bazel/llvm-project-overlay/llvm/config.bzl
+10-834 files not shown
+16-10410 files

LLVM/project b19fbd2offload/include device.h, offload/libompaccsupport PluginManager.cpp device.cpp

[offload][omp] Move OpenMP KLE to libomptarget

Move preparations related to OpenMP KLE and
dynamicCGroupMem fallback out of the plugins and
into libomptarget.

Resructure Device::launch as it grew too large.
DeltaFile
+290-60offload/libompaccsupport/device.cpp
+2-144offload/plugins-nextgen/common/src/PluginInterface.cpp
+5-50offload/plugins-nextgen/common/include/PluginInterface.h
+1-1offload/plugins-nextgen/common/src/RecordReplay.cpp
+1-0offload/libompaccsupport/PluginManager.cpp
+1-0offload/include/device.h
+300-2556 files

LLVM/project db6aed4llvm/lib/CodeGen/SelectionDAG DAGCombiner.cpp, llvm/lib/Target/X86 X86ISelLowering.cpp

[DAG][X86] Do not narrow trunc(select) to a type undesirable for SELECT

DAGCombiner rewrites trunc(select c, a, b) as select c, (trunc a), (trunc b)
whenever truncating is free. On X86 that fires for i8, and where CMOV is
available there is no 8-bit form of it, so LowerSELECT widens the narrow select
back to i32 through ANY_EXTENDs, which lower to MOVZX. The narrowing then only
buys a byte ALU chain plus a MOVZX for each operand that became an i8 op:

  orb     $64, %al        orl     $64, %eax
  movzbl  %al, %eax       cmovneq %rcx, %rax
  cmovnel %ecx, %eax

Gate the fold on isTypeDesirableForOp(ISD::SELECT, VT) and let X86 report i8 as
undesirable when it can use CMOV. Without CMOV the select lowers to a branch
instead, where i8 operands are fine, so narrowing stays enabled there. The hook
defaults to isTypeLegal(VT), so guarded by isTypeLegal it is a no-op for every
target that does not override it. A select of two constants stays exempt: it
introduces no truncate of a computed value, so the narrow form is never worse.

Assisted-by: Claude Code
DeltaFile
+68-55llvm/test/CodeGen/X86/bit-manip-i128.ll
+15-20llvm/test/CodeGen/X86/trunc-select-narrowing.ll
+10-11llvm/test/CodeGen/X86/freeze.ll
+8-8llvm/test/CodeGen/X86/lea-opt2.ll
+8-1llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+8-0llvm/lib/Target/X86/X86ISelLowering.cpp
+117-952 files not shown
+121-998 files

LLVM/project e694143llvm/test/CodeGen/X86 trunc-select-narrowing.ll

[X86][NFC] Pre-commit tests for trunc(select) narrowing

DAGCombiner narrows trunc(select c, a, b) to the truncated type. On X86 that
gives an i8 select, which is widened back to i32 wherever CMOV is available,
so the narrowing only adds a byte ALU chain and a MOVZX.

Assisted-by: Claude Code
DeltaFile
+239-0llvm/test/CodeGen/X86/trunc-select-narrowing.ll
+239-01 files

LLVM/project b623a0cclang/lib/CIR/CodeGen CIRGenExprConstant.cpp, clang/lib/CIR/Lowering/DirectToLLVM LowerToLLVM.cpp

[CIR] Support pointer-to-int global initializers (#220643)

This allows CIR to emit global initializers where a constant address is
cast to an integer.

This fixes compound literals like `unsigned long addr = (unsigned
long)(int[]){1, 2, 3}` and also handles global variable, array element
and function addresses cast to integers.

Fixes #216618
DeltaFile
+24-11clang/lib/CIR/CodeGen/CIRGenExprConstant.cpp
+22-0clang/test/CIR/CodeGen/global-address-to-int.c
+5-8clang/lib/CIR/Lowering/DirectToLLVM/LowerToLLVM.cpp
+6-0clang/test/CIR/CodeGen/compound_literal.c
+57-194 files

LLVM/project f5c30f9llvm/test/TableGen RuntimeLibcallEmitter-variant-beats-exclusion.td, llvm/utils/TableGen/Basic RuntimeLibcallsEmitter.cpp

RuntimeLibcallsEmitter: Let a consumer's own library variant beat its exclusion

A target can pull a shared library via LibraryRef<Lib, [impls]> to drop some
impls, then re-add its own versions through a same-name library variant guarded
on that target. Previously the exclusion's setUnavailable calls were emitted at
the end of setAvailableLibFuncs_<name>, after every variant, so they clobbered
the target's own re-adds.

Defer emitting a variant until after the exclusions when it re-adds an impl its
own consumer excludes (same predicates), so the target's re-add wins while
the exclusion still suppresses every other variant's contribution.

This is yet unused infrastructure for future changes.

Co-authored-by: Claude (Opus 4.8) <noreply at anthropic.com>
DeltaFile
+70-26llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp
+55-0llvm/test/TableGen/RuntimeLibcallEmitter-variant-beats-exclusion.td
+125-262 files

LLVM/project 1c5b470llvm/include/llvm/IR RuntimeLibcallsImpl.td, llvm/test/TableGen RuntimeLibcallEmitter-library-isolated.td

RuntimeLibcallsEmitter: Add isolated LibcallLibrary variant

This is essentially a hack to not break the common core functions shared
by most targets. Most targets have essentially the same base set of
compiler-rt or libc/libm functions, but a few are so radically different
there is nothing in common (e.g., the GPU targets have a handful of functions,
arm64ec changes every single function). This bit will pull these out of the
library merge-by-name system, and emitted as its own special case. This allows
the single name to be universal across targets without duplicating large
tables in the emitted inc file.

Co-authored-by: Claude (Opus 4.8) <noreply at anthropic.com>
DeltaFile
+74-0llvm/test/TableGen/RuntimeLibcallEmitter-library-isolated.td
+17-5llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp
+7-0llvm/include/llvm/IR/RuntimeLibcallsImpl.td
+98-53 files

LLVM/project cd86ae7llvm/test/TableGen RuntimeLibcallEmitter-library-default-cc.td, llvm/utils/TableGen/Basic RuntimeLibcallsEmitter.cpp

RuntimeLibcallsEmitter: Handle calling conv in per-library functions

Pull handling of the default calling convention into the
setAvailableLibFuncs_<name> functions, so the library logic will be
fully contained.

Co-authored-by: Claude (Opus 4.8) <noreply at anthropic.com>
DeltaFile
+80-5llvm/utils/TableGen/Basic/RuntimeLibcallsEmitter.cpp
+50-0llvm/test/TableGen/RuntimeLibcallEmitter-library-default-cc.td
+130-52 files

LLVM/project b2175eaclang/lib/CIR/CodeGen CIRGenExprAggregate.cpp, clang/test/CIR/CodeGen non-type-template-param.cpp

[CIR] Support SubstNonTypeTemplateParmExpr for aggregates (#223603)

Lower `SubstNonTypeTemplateParmExpr` in `AggExprEmitter` by visiting its
replacement expression, matching classic Clang codegen (`CGExprAgg.cpp`)
and existing scalar (#146751), complex (#146755), and lvalue (#182920)
implementations.

The missing aggregate NTTP gap was analyzed with LLM assistance.

Fixes #223533
DeltaFile
+47-27clang/test/CIR/CodeGen/non-type-template-param.cpp
+1-2clang/lib/CIR/CodeGen/CIRGenExprAggregate.cpp
+48-292 files