LLVM/project f87250eclang/lib/AST Type.cpp, clang/test/CodeGenHLSL BoolMatrix.hlsl

[Clang] Make matrix type trivially copyable (#193634)

In order to simplify matrix casting and follow the existing pattern HLSL
is doing, the matrix needs to be trivially copyable.
related to: https://github.com/llvm/llvm-project/issues/184471

---------

Co-authored-by: Joao Saffran <jderezende at microsoft.com>
DeltaFile
+8-4clang/test/SemaCXX/type-traits.cpp
+2-6clang/test/CodeGenHLSL/BoolMatrix.hlsl
+3-2clang/lib/AST/Type.cpp
+13-123 files

LLVM/project 46ef11blld/ELF Driver.cpp Config.h, lld/test/ELF reproduce-thin-archive.s

[ELF] Fix --reproduce non-determinism with parallel input loading (#196773)

After #191690, LoadJob::Archive runs in parallel and getArchiveMembers()
calls ctx.tar->append() from the parallel body. TarWriter::append is
unsynchronized. Member order in the tar is also non-deterministic
because parallelFor scheduling determines append order.

Buffer per-job tar entries during the parallel pass and flush them in
the
existing serial post-pass, mirroring the thinBufs / files pattern.
DeltaFile
+15-3lld/test/ELF/reproduce-thin-archive.s
+7-2lld/ELF/Driver.cpp
+1-0lld/ELF/Config.h
+23-53 files

LLVM/project aeeeb6bclang/include/clang/Serialization ASTRecordReader.h, clang/lib/AST ASTContext.cpp Type.cpp

trivial changes
DeltaFile
+20-14clang/lib/Sema/SemaOpenMP.cpp
+18-14clang/lib/AST/ASTContext.cpp
+16-15clang/lib/Sema/SemaTemplate.cpp
+14-11clang/lib/AST/Type.cpp
+14-8clang/lib/AST/ASTDiagnostic.cpp
+11-6clang/include/clang/Serialization/ASTRecordReader.h
+93-6833 files not shown
+202-15239 files

LLVM/project fa303c7clang/include/clang/AST ASTContext.h, clang/lib/AST ASTContext.cpp ItaniumMangle.cpp

[clang] implement CWG2064: ignore value dependence for decltype

The 'decltype' for a value-dependent (but non-type-dependent) should be known,
so this patch makes them non-opaque instead.

This patch also implements what's neceessary to allow overloading
on pure differences in instantiation dependence, making `std::void_t`
usable for SFINAE purposes.

This also readds a few test cases from da98651, which was a previous attempt
at resolving CWG2064.

Fixes #8740
Fixes #61818
Fixes #190388
DeltaFile
+888-161clang/lib/AST/ASTContext.cpp
+328-12clang/test/SemaTemplate/instantiation-dependence.cpp
+176-96clang/lib/AST/ItaniumMangle.cpp
+100-98clang/lib/Sema/SemaCXXScopeSpec.cpp
+62-57clang/lib/AST/Type.cpp
+88-11clang/include/clang/AST/ASTContext.h
+1,642-43567 files not shown
+2,374-77973 files

LLVM/project cabe3faclang/lib/Format BreakableToken.cpp

Revert "[clang-format][NFC] Format with the new formatter" (#196771)

Reverts llvm/llvm-project#196523
DeltaFile
+1-1clang/lib/Format/BreakableToken.cpp
+1-11 files

LLVM/project 6ae9317clang/lib/Format BreakableToken.cpp

Revert "[clang-format][NFC] Format with the new formatter (#196523)"

This reverts commit a058bae4d2e2a3aadf0aa77c8ab2de7b4005efae.
DeltaFile
+1-1clang/lib/Format/BreakableToken.cpp
+1-11 files

LLVM/project 3b4499cclang-tools-extra/clangd CodeComplete.cpp, clang-tools-extra/clangd/test completion-replace.test completion-auto-trigger-replace.test

[clangd] Add InsertReplaceEdit for code completion (#187623)

Handle new insertReplaceSupport capability (defined in LSP 3.16). Add
the new option to the protocol layer and pass it around to the code
completion logic. Update CompletionItem::textEdit to become the union
type as per the LSP specification.

Add a new helper function to the Lexer public API to find the end of an
identifier with full context lexing, to avoid duplicating the logic. Use
the helper both in the Sema flow and in the comment completion flow. Use
a simpler ASCII-only scan in no-Sema mode.

Add LIT tests to verify auto-triggered completions, mid-word
replacement, Unicode, and snippets. Add unit tests to verify
insert/replace ranges with and without Sema, including comments and the
feature-off case.

Update the release notes to document the new capability.


    [4 lines not shown]
DeltaFile
+271-0clang-tools-extra/clangd/test/completion-replace.test
+185-15clang-tools-extra/clangd/unittests/CodeCompleteTests.cpp
+147-36clang-tools-extra/clangd/CodeComplete.cpp
+113-0clang-tools-extra/clangd/test/completion-auto-trigger-replace.test
+68-0clang-tools-extra/clangd/test/completion-snippets-replace.test
+38-0clang/unittests/Lex/LexerTest.cpp
+822-517 files not shown
+907-5813 files

LLVM/project 2dc02d3clang/include/clang/Serialization ASTRecordReader.h, clang/lib/AST ASTContext.cpp Type.cpp

trivial changes
DeltaFile
+20-14clang/lib/Sema/SemaOpenMP.cpp
+18-14clang/lib/AST/ASTContext.cpp
+16-15clang/lib/Sema/SemaTemplate.cpp
+14-11clang/lib/AST/Type.cpp
+14-8clang/lib/AST/ASTDiagnostic.cpp
+11-6clang/include/clang/Serialization/ASTRecordReader.h
+93-6833 files not shown
+202-15239 files

LLVM/project b370becclang/include/clang/AST ASTContext.h, clang/lib/AST ASTContext.cpp ItaniumMangle.cpp

[clang] implement CWG2064: ignore value dependence for decltype

The 'decltype' for a value-dependent (but non-type-dependent) should be known,
so this patch makes them non-opaque instead.

This patch also implements what's neceessary to allow overloading
on pure differences in instantiation dependence, making `std::void_t`
usable for SFINAE purposes.

This also readds a few test cases from da98651, which was a previous attempt
at resolving CWG2064.

Fixes #8740
Fixes #61818
Fixes #190388
DeltaFile
+888-161clang/lib/AST/ASTContext.cpp
+328-12clang/test/SemaTemplate/instantiation-dependence.cpp
+176-96clang/lib/AST/ItaniumMangle.cpp
+100-98clang/lib/Sema/SemaCXXScopeSpec.cpp
+62-57clang/lib/AST/Type.cpp
+88-11clang/include/clang/AST/ASTContext.h
+1,642-43567 files not shown
+2,374-77973 files

LLVM/project e6c316ellvm/docs UserGuides.rst Reference.rst

[Docs] Match body/toctree ordering on Reference and UserGuides (#195542)

The `toctree` section is hidden but used for previous/next breadcrumbs.

This was suggested in
https://github.com/llvm/llvm-project/pull/184440#issuecomment-4351195402
DeltaFile
+63-61llvm/docs/UserGuides.rst
+42-40llvm/docs/Reference.rst
+105-1012 files

LLVM/project 4eedcd8clang/test/SemaCXX GH195416.cpp

[clang][NFC] Actually add the testcase for #195416 (#196759)
DeltaFile
+10-0clang/test/SemaCXX/GH195416.cpp
+10-01 files

LLVM/project 8f97690clang/test/SemaCXX GH195416.cpp

[clang][NFC] Actually add the testcase for #195416
DeltaFile
+10-0clang/test/SemaCXX/GH195416.cpp
+10-01 files

LLVM/project f87e11eclang-tools-extra/clang-tidy/misc IncludeCleanerCheck.cpp IncludeCleanerCheck.h, clang-tools-extra/docs ReleaseNotes.rst

[clang-tidy] add fragment support to `misc-include-cleaner`
DeltaFile
+323-0clang-tools-extra/unittests/clang-tidy/IncludeCleanerTest.cpp
+97-85clang-tools-extra/clang-tidy/misc/IncludeCleanerCheck.cpp
+46-1clang-tools-extra/docs/clang-tidy/checks/misc/include-cleaner.rst
+6-1clang-tools-extra/docs/ReleaseNotes.rst
+6-1clang-tools-extra/clang-tidy/misc/IncludeCleanerCheck.h
+478-885 files

LLVM/project 5d03beellvm/lib/CodeGen/SelectionDAG SelectionDAG.cpp

[DAG] canCreateUndefOrPoison - out of range vector insert/extract element indices only generate poison (#196720)

Matches ValueTracking / GISel implementations - although testing options are limited until DAG has actual uses of UndefPoisonKind::UndefOnly
DeltaFile
+7-4llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
+7-41 files

LLVM/project 274185fclang/include/clang/Sema Template.h, clang/lib/Sema SemaCXXScopeSpec.cpp SemaTemplateInstantiateDecl.cpp

fixup
DeltaFile
+100-126clang/lib/Sema/SemaCXXScopeSpec.cpp
+16-31clang/lib/Sema/SemaTemplateInstantiateDecl.cpp
+15-12clang/test/AST/ast-dump-templates-pattern.cpp
+8-8clang/test/SemaTemplate/instantiate-scope.cpp
+10-0clang/test/SemaTemplate/instantiation-dependence.cpp
+2-4clang/include/clang/Sema/Template.h
+151-1811 files not shown
+156-1827 files

LLVM/project 6e146f0clang-tools-extra/include-cleaner/include/clang-include-cleaner Analysis.h, clang-tools-extra/include-cleaner/lib Analysis.cpp

[include-cleaner][NFC] factor analysis bookkeeping
DeltaFile
+93-37clang-tools-extra/include-cleaner/lib/Analysis.cpp
+31-19clang-tools-extra/include-cleaner/unittests/AnalysisTest.cpp
+23-12clang-tools-extra/include-cleaner/include/clang-include-cleaner/Analysis.h
+17-15clang-tools-extra/include-cleaner/tool/IncludeCleaner.cpp
+164-834 files

LLVM/project ecbd505clang-tools-extra/include-cleaner/include/clang-include-cleaner Analysis.h, clang-tools-extra/include-cleaner/lib Analysis.cpp

[include-cleaner] add fragment header analysis
DeltaFile
+318-7clang-tools-extra/include-cleaner/unittests/AnalysisTest.cpp
+218-58clang-tools-extra/include-cleaner/lib/Analysis.cpp
+29-0clang-tools-extra/include-cleaner/include/clang-include-cleaner/Analysis.h
+1-1clang-tools-extra/include-cleaner/tool/IncludeCleaner.cpp
+566-664 files

LLVM/project 1c59441clang-tools-extra/include-cleaner/include/clang-include-cleaner Analysis.h, clang-tools-extra/include-cleaner/lib Analysis.cpp

[include-cleaner] add fragment dependency comments
DeltaFile
+192-0clang-tools-extra/include-cleaner/unittests/AnalysisTest.cpp
+146-5clang-tools-extra/include-cleaner/lib/Analysis.cpp
+44-1clang-tools-extra/include-cleaner/include/clang-include-cleaner/Analysis.h
+38-5clang-tools-extra/include-cleaner/tool/IncludeCleaner.cpp
+11-1clang-tools-extra/include-cleaner/test/fragments.cpp
+6-0clang-tools-extra/include-cleaner/test/fragments-block-comment.cpp
+437-124 files not shown
+452-1510 files

LLVM/project 738e2e7clang-tools-extra/docs ReleaseNotes.rst, clang-tools-extra/include-cleaner/test fragments-multi.cpp fragments.cpp

[clang-include-cleaner] expose fragment headers in the tool
DeltaFile
+53-14clang-tools-extra/include-cleaner/tool/IncludeCleaner.cpp
+8-0clang-tools-extra/include-cleaner/test/fragments-multi.cpp
+6-0clang-tools-extra/docs/ReleaseNotes.rst
+6-0clang-tools-extra/include-cleaner/test/fragments.cpp
+6-0clang-tools-extra/include-cleaner/test/fragments-spelled-path.cpp
+5-0clang-tools-extra/include-cleaner/test/fragments-nonrecursive.cpp
+84-147 files not shown
+110-1413 files

LLVM/project e785becllvm/test/CodeGen/AArch64 bf16-v8-instructions.ll bf16-v4-instructions.ll, llvm/test/CodeGen/RISCV/rvv fixed-vectors-reduction-fp.ll

Rebase, address comments

Created using spr 1.3.7
DeltaFile
+7,584-740llvm/test/CodeGen/AArch64/bf16-v8-instructions.ll
+6,873-0llvm/test/tools/llvm-mca/AArch64/Cortex/C1Premium-sve-instructions.s
+4,634-367llvm/test/CodeGen/RISCV/rvv/fixed-vectors-reduction-fp.ll
+4,174-657llvm/test/CodeGen/AArch64/bf16-v4-instructions.ll
+2,928-1,388llvm/test/CodeGen/X86/vector-reduce-smin.ll
+2,924-1,389llvm/test/CodeGen/X86/vector-reduce-smax.ll
+29,117-4,5415,248 files not shown
+204,618-66,7255,254 files

LLVM/project 3987d7eclang-tools-extra/include-cleaner/lib Types.cpp TypesInternal.h, clang-tools-extra/include-cleaner/unittests TypesTest.cpp

[include-cleaner][NFC] share main-file location classification
DeltaFile
+33-0clang-tools-extra/include-cleaner/unittests/TypesTest.cpp
+15-0clang-tools-extra/include-cleaner/lib/Types.cpp
+10-0clang-tools-extra/include-cleaner/lib/TypesInternal.h
+2-7clang-tools-extra/include-cleaner/lib/Record.cpp
+60-74 files

LLVM/project 2d896aaclang/test/SemaCXX GH195416.cpp

[clang][NFC] Actually add the testcase for #195416
DeltaFile
+11-0clang/test/SemaCXX/GH195416.cpp
+11-01 files

LLVM/project 84ba57cclang-tools-extra/include-cleaner/include/clang-include-cleaner Record.h, clang-tools-extra/include-cleaner/lib Record.cpp

[include-cleaner][NFC] record macro refs in direct includes
DeltaFile
+69-2clang-tools-extra/include-cleaner/unittests/RecordTest.cpp
+18-8clang-tools-extra/include-cleaner/lib/Record.cpp
+3-2clang-tools-extra/include-cleaner/include/clang-include-cleaner/Record.h
+90-123 files

LLVM/project b9f6e39clang/test/SemaCXX GH195416.cpp

Actually add the failing testcase
DeltaFile
+11-0clang/test/SemaCXX/GH195416.cpp
+11-01 files

LLVM/project 18c2de0clang/lib/Driver/ToolChains AMDGPU.h PS4CPU.cpp

clang: Add BoundArch/OffloadKind argument to getSupportedSanitizers

Currently the AMDGPU HIP and OpenMP toolchains falsely report
all host sanitizers are supported, and then go out of their way
to skip forwarding those to the device compiles. Add an offloading
kind argument so that in the future this can be handled in one
place in the base toolchain.

Co-authored-by: Claude Sonnet 4 <noreply at anthropic.com>
DeltaFile
+11-2clang/lib/Driver/ToolChains/AMDGPU.h
+8-4clang/lib/Driver/ToolChains/PS4CPU.cpp
+6-3clang/lib/Driver/ToolChains/HIPSPV.cpp
+6-2clang/lib/Driver/ToolChains/PS4CPU.h
+5-2clang/lib/Driver/ToolChains/OpenBSD.cpp
+5-2clang/lib/Driver/ToolChains/Cuda.cpp
+41-1540 files not shown
+190-7246 files

LLVM/project 2aec801clang/lib/Driver SanitizerArgs.cpp, clang/lib/Driver/ToolChains AMDGPU.cpp AMDGPU.h

clang: Refactor handling of offload sanitizer arguments

Previously the AMDGPU toolchains hackily handled -fsanitize arguments.
They would lie and report that all host side sanitizers are available,
then TranslateArgs would filter out the device side cases that do not
work, providing diagnostics for the skipped cases. Move that logic
into the base sanitizer argument parsing.

This makes the produced diagnostics more consistent. Previously we
would get repeated warnings when a sanitizer is fully unsupported
by amdgpu, which should now be once for the toolchain. These could
be further improved; we're printing the specific field of -fsanitize
in more cases where it could be skipped. In other cases we have the
opposite problem, where we aren't reporting the exact sanitizer
from the -f flag in the case that depends on a subtarget feature.

This will help fix other broken target specific flag forwarding bugs
in the future.

Co-authored-by: Claude Sonnet 4 <noreply at anthropic.com>
DeltaFile
+56-47clang/lib/Driver/ToolChains/AMDGPU.cpp
+85-11clang/lib/Driver/SanitizerArgs.cpp
+7-75clang/lib/Driver/ToolChains/AMDGPU.h
+21-24clang/lib/Driver/ToolChains/HIPAMD.cpp
+17-21clang/lib/Driver/ToolChains/AMDGPUOpenMP.cpp
+14-14clang/test/Driver/hip-sanitize-options.hip
+200-1928 files not shown
+261-20714 files

LLVM/project 254259bclang/docs ReleaseNotes.rst, clang/lib/Sema SemaDecl.cpp

Revert "Avoid assert in substqualifier (#182707)" (#196755)

This reverts commit e2def106757534b07a2d3ff15ddd48e14b69a66d.
DeltaFile
+0-12clang/test/SemaTemplate/GH176152.cpp
+1-3clang/lib/Sema/SemaDecl.cpp
+0-1clang/docs/ReleaseNotes.rst
+1-163 files

LLVM/project e07d245llvm/include/llvm/Support SourceMgr.h, llvm/lib/MC/MCParser AsmParser.cpp

[MCParser] .incbin: Don't retain the buffer, don't require NUL termination (#196696)

processIncbinFile uses SourceMgr::AddIncludeFile, which

* sets `RequiresNullTerminator=true` and disable `mmap` when the file
size is a multiple of the page size,
* and unnecessarily retains the throwaway buffer in `Buffers`.

Switch to OpenIncludeFile so the buffer is freed when processIncbinFile
returns, and pass RequiresNullTerminator=false. The buffer is consumed
only by emitBytes; the lexer never scans it, so it does not need a
trailing '\0' (different from #154972). Without that requirement,
MemoryBuffer mmaps the file and RSS tracks only the touched pages.

Stress test (1000 .incbin "blob.bin", 0, 16 against a 1 MiB blob):

```
                  Maximum RSS
  Before          1042944 KiB

    [3 lines not shown]
DeltaFile
+7-4llvm/lib/MC/MCParser/AsmParser.cpp
+7-3llvm/lib/Support/SourceMgr.cpp
+2-1llvm/include/llvm/Support/SourceMgr.h
+16-83 files

LLVM/project d47012fclang/include/clang/Analysis/Analyses/LifetimeSafety Origins.h, clang/lib/Analysis/LifetimeSafety FactsGenerator.cpp Origins.cpp

[LifetimeSafety] Track per-field origins for record types
DeltaFile
+314-4clang/test/Sema/warn-lifetime-safety.cpp
+82-43clang/lib/Analysis/LifetimeSafety/FactsGenerator.cpp
+95-8clang/lib/Analysis/LifetimeSafety/Origins.cpp
+67-24clang/include/clang/Analysis/Analyses/LifetimeSafety/Origins.h
+21-12clang/lib/Analysis/LifetimeSafety/LiveOrigins.cpp
+4-6clang/test/Sema/warn-lifetime-safety-dangling-field.cpp
+583-972 files not shown
+587-988 files

LLVM/project 0cb103dllvm/test/Transforms/SLPVectorizer/X86 arith-mul-smulo.ll arith-sub-usubo.ll

[𝘀𝗽𝗿] initial version

Created using spr 1.3.7
DeltaFile
+549-615llvm/test/Transforms/SLPVectorizer/X86/arith-mul-smulo.ll
+449-615llvm/test/Transforms/SLPVectorizer/X86/arith-sub-usubo.ll
+449-615llvm/test/Transforms/SLPVectorizer/X86/arith-add-saddo.ll
+449-615llvm/test/Transforms/SLPVectorizer/X86/arith-add-uaddo.ll
+449-615llvm/test/Transforms/SLPVectorizer/X86/arith-sub-ssubo.ll
+429-615llvm/test/Transforms/SLPVectorizer/X86/arith-mul-umulo.ll
+2,774-3,6904 files not shown
+3,268-3,91310 files