LLVM/project ff98d79clang/include/clang/AST TypeBase.h TypeProperties.td, clang/lib/AST ASTContext.cpp Type.cpp

[clang] DeducedTypes deduction kind fix and improvement

This is a small refactor of how DeducedType and it's derived types are
represented.

The different deduction kinds are spelled out in an enum, and how this
is tracked is simplified, to allow easier profiling.

How these types are constructed and canonicalized is also brought more
in line with how it works for the other types.

This fixes a crash reported here: https://github.com/llvm/llvm-project/issues/167513#issuecomment-3692962115
DeltaFile
+82-91clang/lib/AST/ASTContext.cpp
+81-38clang/include/clang/AST/TypeBase.h
+48-20clang/lib/AST/Type.cpp
+14-16clang/lib/Sema/TreeTransform.h
+9-18clang/include/clang/AST/TypeProperties.td
+20-4clang/lib/AST/TextNodeDumper.cpp
+254-18714 files not shown
+320-23920 files

LLVM/project 4f2d860clang/include/clang/AST TypeBase.h TypeProperties.td, clang/lib/AST ASTContext.cpp Type.cpp

[clang] DeducedTypes deduction kind fix and improvement

This is a small refactor of how DeducedType and it's derived types are
represented.

The different deduction kinds are spelled out in an enum, and how this
is tracked is simplified, to allow easier profiling.

How these types are constructed and canonicalized is also brought more
in line with how it works for the other types.

This fixes a crash reported here: https://github.com/llvm/llvm-project/issues/167513#issuecomment-3692962115
DeltaFile
+82-91clang/lib/AST/ASTContext.cpp
+81-38clang/include/clang/AST/TypeBase.h
+48-20clang/lib/AST/Type.cpp
+14-16clang/lib/Sema/TreeTransform.h
+9-18clang/include/clang/AST/TypeProperties.td
+20-4clang/lib/AST/TextNodeDumper.cpp
+254-18713 files not shown
+317-23619 files

LLVM/project 696e82dclang/lib/Sema SemaDeclCXX.cpp, clang/test/CodeGenCXX dllexport-inherited-ctor.cpp

[clang] Skip dllexport of inherited constructors with unsatisfied constraints (#186497)

When a class is marked `__declspec(dllexport)`, Clang eagerly creates
inherited constructors via `findInheritingConstructor` and propagates
the dllexport attribute to all members. This bypasses overload
resolution, which would normally filter out constructors whose requires
clause is not satisfied. As a result, Clang attempted to instantiate
constructor bodies that should never be available, causing spurious
compilation errors.

Add constraint satisfaction checks in `checkClassLevelDLLAttribute` to
match MSVC behavior:

1. Before eagerly creating inherited constructors, verify that the base
constructor's `requires` clause is satisfied. Skip creation otherwise.

2. Before applying dllexport to non-inherited methods of class template
specializations, verify constraint satisfaction. This handles the case
where `dllexport` propagates to a base template specialization whose own

    [9 lines not shown]
DeltaFile
+56-30clang/lib/Sema/SemaDeclCXX.cpp
+78-4clang/test/CodeGenCXX/dllexport-inherited-ctor.cpp
+40-0clang/test/SemaCXX/dllexport-constrained-inherited-ctor.cpp
+174-343 files

LLVM/project 4287cfeclang/include/clang/AST TypeBase.h TypeProperties.td, clang/lib/AST ASTContext.cpp Type.cpp

[clang] DeducedTypes deduction kind fix and improvement

This is a small refactor of how DeducedType and it's derived types are
represented.

The different deduction kinds are spelled out in an enum, and how this
is tracked is simplified, to allow easier profiling.

How these types are constructed and canonicalized is also brought more
in line with how it works for the other types.

This fixes a crash reported here: https://github.com/llvm/llvm-project/issues/167513#issuecomment-3692962115
DeltaFile
+82-91clang/lib/AST/ASTContext.cpp
+81-38clang/include/clang/AST/TypeBase.h
+48-20clang/lib/AST/Type.cpp
+14-16clang/lib/Sema/TreeTransform.h
+9-18clang/include/clang/AST/TypeProperties.td
+20-4clang/lib/AST/TextNodeDumper.cpp
+254-18713 files not shown
+317-23619 files

LLVM/project 655d5e7lld/ELF/Arch RISCV.cpp LoongArch.cpp, lld/test/ELF riscv-relax-synthetic-in-text.s loongarch-relax-synthetic-in-text.s

[lld][ELF] Fix crash when relaxation pass encounters synthetic sections

In LoongArch and RISC-V, the relaxation pass iterates over input sections
within executable output sections. When a linker script places a synthetic
section (e.g., .got) into such an output section, the linker would crash
because synthetic sections do not have the relaxAux field initialized.

The relaxAux data structure is only allocated for non-synthetic sections
in initSymbolAnchors. This patch adds the necessary null checks in the
relaxation loops (relaxOnce and finalizeRelax) to skip sections that
do not require relaxation.

A null check is also added to elf::initSymbolAnchors to ensure the
subsequent sorting of anchors is safe.

Fixes: #184757

Reviewers: MaskRay

Pull Request: https://github.com/llvm/llvm-project/pull/184758
DeltaFile
+33-0lld/test/ELF/riscv-relax-synthetic-in-text.s
+31-0lld/test/ELF/loongarch-relax-synthetic-in-text.s
+8-1lld/ELF/Arch/RISCV.cpp
+4-1lld/ELF/Arch/LoongArch.cpp
+76-24 files

LLVM/project f46a515llvm/lib/Target/LoongArch/MCTargetDesc LoongArchAsmBackend.cpp

[LoongArch] Remove unreachable Value check in fixupLeb128 (#186297)

Value is guaranteed to be zero after the loop:

  for (I = 0; Value; ++I, Value >>= 7)

Therefore the subsequent `if (Value)` condition is always false.
Remove the unreachable code. Reported by PVS-Studio.

Fixed: #170122
DeltaFile
+0-2llvm/lib/Target/LoongArch/MCTargetDesc/LoongArchAsmBackend.cpp
+0-21 files

LLVM/project bb71dd0clang/test/OpenMP target_teams_distribute_parallel_for_simd_schedule_codegen.cpp, libc/AOR_v20.02/math/test/traces sincosf.txt exp.txt

remove pie test

Created using spr 1.3.7
DeltaFile
+53,024-7,001llvm/test/CodeGen/RISCV/rvv/clmulh-sdnode.ll
+0-31,999libc/AOR_v20.02/math/test/traces/sincosf.txt
+15,172-1,553llvm/test/CodeGen/RISCV/rvv/clmul-sdnode.ll
+0-16,000libc/AOR_v20.02/math/test/traces/exp.txt
+7,665-4,743llvm/test/CodeGen/AArch64/clmul-fixed.ll
+5,294-4,814clang/test/OpenMP/target_teams_distribute_parallel_for_simd_schedule_codegen.cpp
+81,155-66,1106,563 files not shown
+478,858-308,2106,569 files

LLVM/project 6e6a46borc-rt/include/orc-rt iterator_range.h, orc-rt/unittests iterator_range-test.cpp CMakeLists.txt

[orc-rt] Add a simple iterator_range class. (#186720)

This will be used to simplify operations on iterator ranges in the ORC
runtime.
DeltaFile
+79-0orc-rt/unittests/iterator_range-test.cpp
+47-0orc-rt/include/orc-rt/iterator_range.h
+1-0orc-rt/unittests/CMakeLists.txt
+127-03 files

LLVM/project 4c5b1c4clang/test/Driver riscv-cpus.c, clang/test/Driver/print-enabled-extensions riscv-sifive-x180.c riscv-sifive-x160.c

[RISCV] Add `sifive-x160` and `sifive-x180` processor definitions (#186264)

This PR adds new processor definitions for two SiFive cores:
- X160
(https://www.sifive.com/document-file/sifive-intelligence-x160-gen2-product-brief):
A RV32 core with Zve32f
- X180
(https://www.sifive.com/document-file/sifive-intelligence-x180-gen2-product-brief):
A RVV-capable RV64 core

Both of them have VLEN=128.

Scheduling model supports will be added in follow-up patches.
DeltaFile
+94-0llvm/lib/Target/RISCV/RISCVProcessors.td
+71-0clang/test/Driver/print-enabled-extensions/riscv-sifive-x180.c
+59-0clang/test/Driver/print-enabled-extensions/riscv-sifive-x160.c
+10-0clang/test/Driver/riscv-cpus.c
+4-0clang/test/Misc/target-invalid-cpu-note/riscv.c
+1-0llvm/docs/ReleaseNotes.md
+239-06 files

LLVM/project 8767bdbllvm/include/llvm/MC MCPseudoProbe.h

[NFC] Delete `MCPseudoProbeDecoder`'s move constructor (#186698)

`MCPseudoProbeDecoder` cannot be copeied/moved due to its address
dependence on the DummyInlineRoot member address. Explicitly delete the move constructor.
DeltaFile
+8-0llvm/include/llvm/MC/MCPseudoProbe.h
+8-01 files

LLVM/project 70cd2acllvm/docs LangRef.rst, llvm/include/llvm/IR Constants.h

Revert "[IR] Add initial support for the byte type" (#186713)

Reverts llvm/llvm-project#178666 to unblock CI.
`CodeGen/X86/byte-constants.ll` is at fault. 
Will look into it and hopefully fix it by tomorrow.
DeltaFile
+17-290llvm/lib/IR/Constants.cpp
+16-177llvm/include/llvm/IR/Constants.h
+9-106llvm/docs/LangRef.rst
+0-101llvm/test/Assembler/byte.ll
+36-37llvm/test/tools/llvm-ir2vec/entities.ll
+0-73llvm/test/Assembler/byte-invalid.ll
+78-78440 files not shown
+168-1,48846 files

LLVM/project b0df9a3orc-rt/unittests SessionTest.cpp SimpleNativeMemoryMapTest.cpp

[orc-rt] Fix unittests after 53a1e056f38. (#186711)

Updates unittests to reflect Service interface changes.
DeltaFile
+9-11orc-rt/unittests/SessionTest.cpp
+12-6orc-rt/unittests/SimpleNativeMemoryMapTest.cpp
+21-172 files

LLVM/project 7aeb01fclang-tools-extra/test/clang-tidy/checkers/Inputs/Headers/std memory, clang-tools-extra/test/clang-tidy/checkers/bugprone use-after-move.cpp

[clang-tidy][NFC] Use universal memory mock for smart ptrs (#186649)
DeltaFile
+170-0clang-tools-extra/test/clang-tidy/checkers/Inputs/Headers/std/memory
+0-45clang-tools-extra/test/clang-tidy/checkers/modernize/Inputs/replace-auto-ptr/memory.h
+1-34clang-tools-extra/test/clang-tidy/checkers/readability/redundant-smartptr-get.cpp
+1-33clang-tools-extra/test/clang-tidy/checkers/modernize/Inputs/smart-ptr/shared_ptr.h
+2-28clang-tools-extra/test/clang-tidy/checkers/bugprone/use-after-move.cpp
+1-28clang-tools-extra/test/clang-tidy/checkers/modernize/Inputs/smart-ptr/unique_ptr.h
+175-16820 files not shown
+204-32726 files

LLVM/project 15a58f6llvm/docs LangRef.rst, llvm/include/llvm/IR Constants.h

Revert "[IR] Add initial support for the byte type (#178666)"

This reverts commit 80f2ef70f592f2e2b4b7d72143e2e5566ff9c36b.
DeltaFile
+17-290llvm/lib/IR/Constants.cpp
+16-177llvm/include/llvm/IR/Constants.h
+9-106llvm/docs/LangRef.rst
+0-101llvm/test/Assembler/byte.ll
+0-73llvm/test/Assembler/byte-invalid.ll
+36-37llvm/test/tools/llvm-ir2vec/entities.ll
+78-78440 files not shown
+168-1,48846 files

LLVM/project f5a5596mlir/include/mlir-c/Dialect LLVM.h, mlir/include/mlir/Dialect/LLVMIR LLVMAttrDefs.td

reduce lit test
DeltaFile
+11-69mlir/test/Target/LLVMIR/llvmir-named-metadata.mlir
+3-3mlir/include/mlir-c/Dialect/LLVM.h
+2-3mlir/lib/CAPI/Dialect/LLVM.cpp
+0-2mlir/python/mlir/dialects/llvm.py
+1-1mlir/include/mlir/Dialect/LLVMIR/LLVMAttrDefs.td
+0-1mlir/lib/Target/LLVMIR/Dialect/LLVMIR/LLVMToLLVMIRTranslation.cpp
+17-796 files

LLVM/project 53a1e05orc-rt/include/orc-rt Session.h Service.h, orc-rt/lib/executor Session.cpp SimpleNativeMemoryMap.cpp

[orc-rt] Don't return Error in Service::OnComplete. (#186708)

The Session can't do anything useful with these errors, it can only
report them. It's cleaner if the Service objects just report the error
directly.
DeltaFile
+3-6orc-rt/lib/executor/Session.cpp
+2-2orc-rt/lib/executor/SimpleNativeMemoryMap.cpp
+1-1orc-rt/include/orc-rt/Session.h
+1-1orc-rt/include/orc-rt/Service.h
+7-104 files

LLVM/project 5a729d8mlir/include/mlir/Dialect/LLVMIR LLVMAttrDefs.td, mlir/lib/Bindings/Python DialectLLVM.cpp

format and document integer limitation
DeltaFile
+76-73mlir/lib/Target/LLVMIR/Dialect/LLVMIR/LLVMToLLVMIRTranslation.cpp
+31-22mlir/test/python/dialects/llvm.py
+22-25mlir/lib/Bindings/Python/DialectLLVM.cpp
+9-12mlir/lib/CAPI/Dialect/LLVM.cpp
+16-1mlir/python/mlir/dialects/llvm.py
+5-4mlir/include/mlir/Dialect/LLVMIR/LLVMAttrDefs.td
+159-1371 files not shown
+160-1387 files

LLVM/project 80f2ef7llvm/docs LangRef.rst, llvm/include/llvm/IR Constants.h

[IR] Add initial support for the byte type (#178666)

Following the [byte type RFC](https://discourse.llvm.org/t/rfc-add-a-new-byte-type-to-llvm-ir/89522)
and the discussions within the [LLVM IR Formal Specification WG](https://discourse.llvm.org/t/rfc-forming-a-working-group-on-formal-specification-for-llvm/89056), this PR introduces initial support for the byte type in LLVM. This PR:
- Adds the byte type to LLVM's type system
- Extends the `bitcast` instruction to accept the byte operands
- Adds parsing tests for all new functionality
- Fixes failing regressions tests (IR2Vec and IRNormalizer)

---------

Co-authored-by: George Mitenkov <georgemitenk0v at gmail.com>
DeltaFile
+290-17llvm/lib/IR/Constants.cpp
+177-16llvm/include/llvm/IR/Constants.h
+106-9llvm/docs/LangRef.rst
+101-0llvm/test/Assembler/byte.ll
+37-36llvm/test/tools/llvm-ir2vec/entities.ll
+72-1llvm/lib/IR/Type.cpp
+783-7940 files not shown
+1,488-16846 files

LLVM/project e172f81mlir/include/mlir/Dialect/LLVMIR LLVMAttrDefs.td, mlir/lib/Bindings/Python DialectLLVM.cpp

format and document integer limitation
DeltaFile
+76-73mlir/lib/Target/LLVMIR/Dialect/LLVMIR/LLVMToLLVMIRTranslation.cpp
+22-25mlir/lib/Bindings/Python/DialectLLVM.cpp
+23-22mlir/test/python/dialects/llvm.py
+9-12mlir/lib/CAPI/Dialect/LLVM.cpp
+16-1mlir/python/mlir/dialects/llvm.py
+4-3mlir/include/mlir/Dialect/LLVMIR/LLVMAttrDefs.td
+150-1366 files

LLVM/project 6858c79clang/lib/CIR/CodeGen CIRGenExprAggregate.cpp CIRGenValue.h, clang/test/CIR/CodeGen aggregate-copy-overlap.cpp no-unique-address.cpp

[CIR] Use data size in emitAggregateCopy for overlapping copies
DeltaFile
+76-0clang/test/CIR/CodeGen/aggregate-copy-overlap.cpp
+16-6clang/lib/CIR/CodeGen/CIRGenExprAggregate.cpp
+5-4clang/test/CIR/CodeGen/no-unique-address.cpp
+1-1clang/lib/CIR/CodeGen/CIRGenValue.h
+98-114 files

LLVM/project b748beamlir/include/mlir-c/Dialect LLVM.h, mlir/lib/Bindings/Python DialectLLVM.cpp

add python bindings test
DeltaFile
+130-0mlir/test/python/dialects/llvm.py
+48-0mlir/lib/Bindings/Python/DialectLLVM.cpp
+18-5mlir/include/mlir-c/Dialect/LLVM.h
+12-0mlir/lib/CAPI/Dialect/LLVM.cpp
+208-54 files

LLVM/project a27ad57clang/lib/CIR/CodeGen CIRGenExprAggregate.cpp CIRGenValue.h, clang/test/CIR/CodeGen aggregate-copy-overlap.cpp no-unique-address.cpp

[CIR] Use data size in emitAggregateCopy for overlapping copies
DeltaFile
+63-0clang/test/CIR/CodeGen/aggregate-copy-overlap.cpp
+16-6clang/lib/CIR/CodeGen/CIRGenExprAggregate.cpp
+5-4clang/test/CIR/CodeGen/no-unique-address.cpp
+1-1clang/lib/CIR/CodeGen/CIRGenValue.h
+85-114 files

LLVM/project 3604119llvm/include/llvm/IR CFG.h, llvm/lib/Frontend/OpenMP OMPIRBuilder.cpp

[IR] Don't allow successors() over block without terminators (#186646)

There's no point constructing a dominator tree or similar on
known-broken IR. Generally, functions should be able to assume that IR
is valid (i.e., passes the verifier). Users of this "feature" were:

- Verifier, fixed by verifying existence of terminators first.
- FuzzMutate, worked around by temporarily inserting terminators.
- OpenMP to run analyses while building the IR, worked around by
temporarily inserting terminators.
- Polly to work with an empty dominator tree, fixed by temporarily
adding an unreachable inst.
- MergeBlockIntoPredecessor, inadvertently, fixed by adding terminator
before updating MemorySSA.
- Some sloppily written unit tests.
DeltaFile
+46-0llvm/test/Transforms/LoopSimplifyCFG/mssa_term.ll
+33-0llvm/unittests/Analysis/MemorySSATest.cpp
+28-0llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp
+8-12llvm/include/llvm/IR/CFG.h
+14-2llvm/lib/FuzzMutate/RandomIRBuilder.cpp
+6-3llvm/lib/IR/Verifier.cpp
+135-176 files not shown
+150-1912 files

LLVM/project df6e557mlir/include/mlir-c/Dialect LLVM.h, mlir/include/mlir/Dialect/LLVMIR LLVMAttrDefs.td

[MLIR][LLVM] add metadata attrs and llvm.named_metadata
DeltaFile
+95-48mlir/lib/Target/LLVMIR/Dialect/LLVMIR/LLVMToLLVMIRTranslation.cpp
+122-1mlir/lib/Bindings/Python/DialectLLVM.cpp
+107-0mlir/test/Target/LLVMIR/llvmir-named-metadata.mlir
+86-2mlir/lib/CAPI/Dialect/LLVM.cpp
+70-0mlir/include/mlir/Dialect/LLVMIR/LLVMAttrDefs.td
+65-0mlir/include/mlir-c/Dialect/LLVM.h
+545-511 files not shown
+585-517 files

LLVM/project de81419llvm/utils/gn/secondary/lldb/test BUILD.gn

[gn] port f002fc0ee8734283
DeltaFile
+2-0llvm/utils/gn/secondary/lldb/test/BUILD.gn
+2-01 files

LLVM/project dc1f7c7llvm/utils/gn/secondary/clang/include/clang/Config BUILD.gn, llvm/utils/gn/secondary/clang/test BUILD.gn

[gn] port 629edaf67844c01db37 (CLANG_USE_XCSELECT)
DeltaFile
+2-0llvm/utils/gn/secondary/clang/include/clang/Config/BUILD.gn
+1-0llvm/utils/gn/secondary/clang/test/BUILD.gn
+3-02 files

LLVM/project 562f519.github/workflows/containers/libc Dockerfile

[libc][Github] Bump clang in libc container to v23 (#186697)

Back to HEAD now that apt.llvm.org is working again for ToT.
DeltaFile
+3-0.github/workflows/containers/libc/Dockerfile
+3-01 files

LLVM/project 906f2b6clang/include/clang/Basic AttrDocs.td

[Clang][Docs] Clarify [[unlikely]] example in compound statement (#186590)

The first code example in the "confusing standard behavior" section
had a comment claiming `[[unlikely]]` makes the branch unlikely,
contradicting a later example showing the same placement being ignored.

Rewords the comment to clarify this is the C++ Standard's
recommendation that Clang does not follow, since the attribute is not on
the substatement.

Continues the work from #126372.

Fixes #126362.
DeltaFile
+4-2clang/include/clang/Basic/AttrDocs.td
+4-21 files

LLVM/project 6f6d7dallvm/utils git-llvm-push git-llvm-push.md

[𝘀𝗽𝗿] initial version

Created using spr 1.3.7
DeltaFile
+37-24llvm/utils/git-llvm-push
+1-0llvm/utils/git-llvm-push.md
+38-242 files

LLVM/project 1a865abllvm/utils git-llvm-push

[𝘀𝗽𝗿] changes to main this commit is based on

Created using spr 1.3.7

[skip ci]
DeltaFile
+20-19llvm/utils/git-llvm-push
+20-191 files