LLVM/project 58ee64eclang/lib/Driver/ToolChains OHOS.cpp Fuchsia.cpp, clang/test/Driver fuchsia.c ohos.c

[Driver] Uniform handling of invalid rtlib across drivers (#198219)

This is mostly an NFC except for a different diagnostic being emitted.
The goal is to unify validation and handling of invalid rtlib value
across different drivers to simplify supporting more -rtlib= values in
the future.
DeltaFile
+4-4clang/lib/Driver/ToolChains/OHOS.cpp
+4-4clang/lib/Driver/ToolChains/Fuchsia.cpp
+1-1clang/lib/Driver/ToolChains/Darwin.cpp
+1-1clang/test/Driver/fuchsia.c
+1-1clang/test/Driver/ohos.c
+11-115 files

LLVM/project 9886c72llvm/include/llvm/Analysis FunctionPropertiesAnalysis.h, llvm/include/llvm/IR FunctionProperties.def

Add noreturn call count to FunctionPropertiesAnalysis pass (#198322)

Adding this metric to visualize how many noreturn functions there are
with the idea of analyzing their relationship with unreachable
instructions
DeltaFile
+4-0llvm/lib/Analysis/FunctionPropertiesAnalysis.cpp
+1-0llvm/include/llvm/Analysis/FunctionPropertiesAnalysis.h
+1-0llvm/include/llvm/IR/FunctionProperties.def
+6-03 files

LLVM/project 1d4c14bclang/include/clang/AST ASTContext.h, clang/include/clang/Basic Builtins.td

Revert "Add clang warning if fp exception functions are called without approp…"

This reverts commit 5f2bedca745d5efa1955369cfe352bcd09be4633.
DeltaFile
+0-68clang/test/Sema/fenv-access.c
+0-55clang/include/clang/Basic/Builtins.td
+0-51clang/test/Sema/builtin-fenv.c
+0-36clang/lib/Serialization/ASTReader.cpp
+0-35clang/test/Sema/fenv-access-implicit.c
+1-34clang/include/clang/AST/ASTContext.h
+1-27914 files not shown
+2-42420 files

LLVM/project 823be5ellvm/lib/Support UnicodeNameToCodepointGenerated.cpp, llvm/test/CodeGen/AMDGPU/GlobalISel legalize-load-local.mir

rebase

Created using spr 1.3.7
DeltaFile
+23,873-20,923llvm/lib/Support/UnicodeNameToCodepointGenerated.cpp
+8,633-8,584llvm/test/CodeGen/Thumb2/mve-clmul.ll
+1,243-8,768llvm/test/CodeGen/X86/vector-replicaton-i1-mask.ll
+0-4,752llvm/test/tools/llvm-mca/RISCV/SiFiveP800/vlseg-vsseg.s
+4,549-0llvm/test/tools/llvm-mca/RISCV/SiFiveP800/rvv/arithmetic.test
+3,706-328llvm/test/CodeGen/AMDGPU/GlobalISel/legalize-load-local.mir
+42,004-43,3552,168 files not shown
+133,338-93,5472,174 files

LLVM/project c93c17bclang/include/clang/DependencyScanning ModuleDepCollector.h, clang/lib/DependencyScanning ModuleDepCollector.cpp

[clang][deps] Move `ModuleDepCollectorPP` to .cpp file (#197964)

This PR moves the `ModuleDepCollectorPP` type into the .cpp file. It's
an implementation detail that the header doesn't need to expose.
DeltaFile
+54-45clang/lib/DependencyScanning/ModuleDepCollector.cpp
+2-33clang/include/clang/DependencyScanning/ModuleDepCollector.h
+56-782 files

LLVM/project f4ee477llvm/test/Transforms/HotColdSplit issue-197982.ll

[NFC][CodeExtractor] simplify test for #197986 (#198011)
DeltaFile
+16-63llvm/test/Transforms/HotColdSplit/issue-197982.ll
+16-631 files

LLVM/project dd199b4llvm/lib/Target/AMDGPU AMDGPULegalizerInfo.cpp

[AMDGPU][GlobalISel] Remove dependency on legal ruleset (#197371)

This fills in always legal rules, to remove the dependency on the legacy
ruleset. This is not guaranteed to be all the rules, just the ones that
appear in tests.
DeltaFile
+7-0llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
+7-01 files

LLVM/project 633d731llvm/test/TableGen aarch64-apple-tuning-features.td

[llvm] Re-format aarch64-apple-tuning-features.td. NFC (#197777)

It's much easier to review diffs with each feature on its own line. Also
add an -implicit-check-not so we don't miss any CPUs going forward.
DeltaFile
+274-23llvm/test/TableGen/aarch64-apple-tuning-features.td
+274-231 files

LLVM/project cab2fdallvm/lib/Target/SPIRV SPIRVLegalizerInfo.cpp SPIRVUtils.h, llvm/test/CodeGen/SPIRV/GlobalISel fn-ptr-addrspacecast.ll

[SPIRV] Allow casting between CodeSectionINTEL and Generic storage classes (#197556)

In the previous versions of the SPV_INTEL_function_pointers
[spec](https://github.com/intel/llvm/blob/sycl/sycl/doc/design/spirv-extensions/SPV_INTEL_function_pointers.asciidoc),
casts between the CodeSectionINTEL storage class (used for function
pointers) and the Generic storage class were illegal.

The spec was updated a few months ago, and the new version allows the
cast, specifying `CodeSectionIntel` as one of the overloaded storage
classes that can be represented by Generic, alongside `WorkGroup`, etc.
I also confirmed with a spec author that one of the intentions of the
spec updates was to allow the cast.

Update the SPIR-V backend to allow the cast. This is basically required
to use function pointers in real world use cases.

---------

Signed-off-by: Nick Sarnie <nick.sarnie at intel.com>
DeltaFile
+23-3llvm/test/CodeGen/SPIRV/GlobalISel/fn-ptr-addrspacecast.ll
+0-3llvm/lib/Target/SPIRV/SPIRVLegalizerInfo.cpp
+1-0llvm/lib/Target/SPIRV/SPIRVUtils.h
+24-63 files

LLVM/project f33e9e4libc/hdr float_macros.h limits_macros.h

[libc][NFC] Fix #endif comments in hdr/ proxy headers (#198313)

The #endif closing the LIBC_FULL_BUILD guard used the CMake variable
name LLVM_LIBC_FULL_BUILD in its comment rather than the preprocessor
macro LIBC_FULL_BUILD that the #ifdef above references. These are
distinct: LLVM_LIBC_FULL_BUILD is the CMake option; LIBC_FULL_BUILD is
the C macro defined via -DLIBC_FULL_BUILD when that option is ON.

Fixed 113 files under libc/hdr/ with a mechanical substitution.

Assisted-by: Automated tooling, human reviewed.
DeltaFile
+1-1libc/hdr/float_macros.h
+1-1libc/hdr/limits_macros.h
+1-1libc/hdr/link_macros.h
+1-1libc/hdr/locale_macros.h
+1-1libc/hdr/math_function_macros.h
+1-1libc/hdr/math_macros.h
+6-6107 files not shown
+113-113113 files

LLVM/project 1c8c500llvm/lib/Target/AMDGPU AMDGPURegBankLegalizeHelper.cpp AMDGPURegBankLegalizeRules.cpp, llvm/test/CodeGen/AMDGPU ctpop.ll ctpop16.ll

[AMDGPU][GISel] Add Register Bank Legalization rules for G_CTPOP. (#197510)
DeltaFile
+1,631-154llvm/test/CodeGen/AMDGPU/ctpop.ll
+746-0llvm/test/CodeGen/AMDGPU/ctpop16.ll
+207-3llvm/test/CodeGen/AMDGPU/ctpop64.ll
+11-0llvm/lib/Target/AMDGPU/AMDGPURegBankLegalizeHelper.cpp
+6-0llvm/lib/Target/AMDGPU/AMDGPURegBankLegalizeRules.cpp
+2-3llvm/test/CodeGen/AMDGPU/GlobalISel/regbankselect-ctpop.mir
+2,603-1601 files not shown
+2,604-1607 files

LLVM/project 176134cllvm/test/CodeGen/AArch64 aarch64-isel-umin.ll

[AArch64] Regenerate aarch64-isel-umin.ll. NFC (#198337)
DeltaFile
+54-116llvm/test/CodeGen/AArch64/aarch64-isel-umin.ll
+54-1161 files

LLVM/project cf80e0ellvm/test/Transforms/SLPVectorizer/X86 scalarize-ctlz.ll arith-fp-inseltpoison.ll

[SLP] Preserve profitable trees when subtree trimming would reduce to buildvector-only

In calculateTreeCostAndTrimNonProfitable, the subtree trim loop returns
Invalid when trimming node Idx==1 under an InsertElement root would
leave only a buildvector, to avoid infinite vectorization attempts.
This is too aggressive when the original untrimmed tree is already
profitable (Cost < -SLPCostThreshold). In that case, undo any partial
trims and return the original cost instead of rejecting the tree.

Original Pull Request: https://github.com/llvm/llvm-project/pull/197763

Recommit after unrelated revert in https://github.com/llvm/llvm-project/pull/198265

Reviewers: 

Pull Request: https://github.com/llvm/llvm-project/pull/198336
DeltaFile
+48-29llvm/test/Transforms/SLPVectorizer/X86/scalarize-ctlz.ll
+19-32llvm/test/Transforms/SLPVectorizer/X86/arith-fp-inseltpoison.ll
+19-32llvm/test/Transforms/SLPVectorizer/X86/arith-fp.ll
+9-10llvm/test/Transforms/SLPVectorizer/X86/deleted-instructions-clear.ll
+7-10llvm/test/Transforms/SLPVectorizer/X86/alternate-int-inseltpoison.ll
+7-10llvm/test/Transforms/SLPVectorizer/X86/alternate-int.ll
+109-1234 files not shown
+138-14010 files

LLVM/project dce3bc2.ci compute_projects_test.py compute_projects.py

[CI] Run libc tests on clang changes (#198295)

The libc tests are relatively lightweight, and given we build libc with
a just built clang, it's very easy for clang changes to cause issues in
libc, especially with -Werror. For example, #187860 broke libc due to
adding a new warning that libc was not clean on.
DeltaFile
+6-4.ci/compute_projects_test.py
+1-1.ci/compute_projects.py
+7-52 files

LLVM/project 4c76d40libsycl/src/detail queue_impl.cpp

apply new liboffload kernel launch API

Signed-off-by: Tikhomirova, Kseniya <kseniya.tikhomirova at intel.com>
DeltaFile
+4-7libsycl/src/detail/queue_impl.cpp
+4-71 files

LLVM/project 20165e1llvm/lib/Transforms/Vectorize SLPVectorizer.cpp, llvm/test/Transforms/SLPVectorizer/X86 reused-extract-scalar-lanes.ll

[SLP] Prefer VF-matching scalar-set match in gather-shuffle lookup

In isGatherShuffledSingleRegisterEntry, the perfect-match search accepted
an entry that isSame(TE->Scalars) regardless of the entry's vector factor.
isSame can succeed via ReuseShuffleIndices on an entry whose actual VF is
smaller than TE->Scalars.size(); the subsequent mask construction then
copies TE->getCommonMask() indices that overrun the chosen source's lanes,
producing wrong shufflevector masks and a more-poisonous result than the
scalar code.

Fixes #197765

Reviewers: 

Pull Request: https://github.com/llvm/llvm-project/pull/198334
DeltaFile
+3-1llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+1-3llvm/test/Transforms/SLPVectorizer/X86/reused-extract-scalar-lanes.ll
+4-42 files

LLVM/project 2e93539llvm/lib/Transforms/Vectorize SLPVectorizer.cpp, llvm/test/Transforms/SLPVectorizer/X86 reused-extract-scalar-lanes.ll

[𝘀𝗽𝗿] initial version

Created using spr 1.3.7
DeltaFile
+3-1llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+1-3llvm/test/Transforms/SLPVectorizer/X86/reused-extract-scalar-lanes.ll
+4-42 files

LLVM/project 8ec281bllvm/lib/IR Intrinsics.cpp, llvm/test/CodeGen/AArch64 sve-bad-intrinsics.ll

[LLVM] Precise error message for intrinsic signature verification (1/n) (#196802)

Generate more precise error message when intrinsic signature
verification fails. Keep track of the current position/component of the
intrinsic signature being checked and print a more descriptive error
message which includes the position/element of the signature that failed
and the reason it failed.

Note that not all cases in `matchIntrinsicType` generate errors, so have
a temporary fallback to keep generating a generic error message in those
cases. This fallback will be eventually removed.

Added a C++ unit test for testing intrinsic struct return type that is
either an identified struct or a packed struct, as these cases cannot be
created from a .ll file directly (since autoupgrade in the parser fixes
them up).
DeltaFile
+291-0llvm/test/Verifier/intrinsic-bad-arg-type1.ll
+171-47llvm/lib/IR/Intrinsics.cpp
+36-0llvm/unittests/IR/VerifierTest.cpp
+2-2llvm/test/CodeGen/AArch64/sve-bad-intrinsics.ll
+1-1llvm/test/CodeGen/WinEH/wineh-intrinsics-invalid.ll
+501-505 files

LLVM/project f63b8eellvm/lib/Target/X86 X86ISelLowering.cpp, llvm/test/CodeGen/X86 pr196804.ll

[SelectionDAG] Fix miscompile in known-0/1 setcc fold with XOR (#196804) (#197767)

When simplifySetCC folds `(xor X, C) != 0` (where the XOR result is
known 0/1) into `TRUNCATE(XOR X, C)`, later DAG combines can incorrectly
fold the XOR back into its source operand, losing the NOT semantics.
This causes the x86 backend to test the original value instead of the
XOR result, inverting the condition and producing wrong code.

Fix by folding `(xor X, C) ==/!= N1` directly into `setcc(X, N1^C,
cond)` instead of returning TRUNCATE(XOR). The SETCC form is canonical
and immune to the problematic DAG combine.

Fixes #196804.
DeltaFile
+26-0llvm/test/CodeGen/X86/pr196804.ll
+3-1llvm/lib/Target/X86/X86ISelLowering.cpp
+29-12 files

LLVM/project e88d1b7clang/docs TypeSanitizer.rst

[Docs] Fix and update TySan docs (#198331)
DeltaFile
+3-3clang/docs/TypeSanitizer.rst
+3-31 files

LLVM/project 9c11571lldb/source/Commands CommandObjectBreakpoint.cpp CommandObjectTarget.cpp

Revert "[lldb] Make CommandObject::GetTarget filter out the dummy target (#198026)" (#198325)

This reverts commit d90baa054dfc7d9f53148e4739effbf9fd7ac27a.

Fails in CI in `TestMultipleBinaryCorefile.py` when running `image list
-g` in `test_corefile_binaries_dsymforuuid` because `TargetModulesList`
currently asserts we have a target even with the `-g` flag set.

Original PR https://github.com/llvm/llvm-project/pull/198026
DeltaFile
+150-162lldb/source/Commands/CommandObjectBreakpoint.cpp
+114-143lldb/source/Commands/CommandObjectTarget.cpp
+48-55lldb/source/Commands/CommandObjectWatchpoint.cpp
+46-49lldb/source/Commands/CommandObjectSource.cpp
+23-20lldb/source/Commands/CommandObjectProcess.cpp
+18-24lldb/source/Commands/CommandObjectFrame.cpp
+399-45314 files not shown
+492-57920 files

LLVM/project e9a46b9llvm/lib/Transforms/Vectorize LoopVectorize.cpp

[VPlan] Skip verification for intermediate VPlan transforms (#198321)

Fix #198274
DeltaFile
+7-7llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
+7-71 files

LLVM/project 3e30430llvm/lib/Target/RISCV RISCVInstrInfoP.td RISCVInstrInfo.td, llvm/test/CodeGen/RISCV rvp-simd-64.ll

[RISCV][P-ext] Add patterns for padd.dbs/dhs/dws. (#198227)
DeltaFile
+6-12llvm/test/CodeGen/RISCV/rvp-simd-64.ll
+14-1llvm/lib/Target/RISCV/RISCVInstrInfoP.td
+0-5llvm/lib/Target/RISCV/RISCVInstrInfo.td
+20-183 files

LLVM/project 4d5839fclang-tools-extra/clang-doc Representation.h

[clang-doc][nfc] Reformat and revise comment block
DeltaFile
+35-22clang-tools-extra/clang-doc/Representation.h
+35-221 files

LLVM/project ea64c90clang-tools-extra/clang-doc Serialize.cpp Serialize.h

[clang-doc] Removed OwnedPtr alias

The alias served a purpose during migration, but now conveys the wrong
semantics, as the memory these pointers reference is interned inside
a local arena, and doesn't convey any sort of ownership.
DeltaFile
+40-38clang-tools-extra/clang-doc/Serialize.cpp
+29-42clang-tools-extra/clang-doc/Serialize.h
+17-18clang-tools-extra/clang-doc/Representation.cpp
+3-22clang-tools-extra/clang-doc/Representation.h
+8-8clang-tools-extra/clang-doc/JSONGenerator.cpp
+8-6clang-tools-extra/clang-doc/Generators.h
+105-13411 files not shown
+148-17717 files

LLVM/project 8348dcaclang-tools-extra/clang-doc BitcodeReader.cpp

Fix typo in variable name
DeltaFile
+2-2clang-tools-extra/clang-doc/BitcodeReader.cpp
+2-21 files

LLVM/project 6a74a7fclang-tools-extra/clang-doc Serialize.cpp BitcodeReader.cpp, clang-tools-extra/clang-doc/benchmarks ClangDocBenchmark.cpp

[clang-doc] Use distinct APIs for fixed arena allocation sites

Typically, code either always emits data into the TransientArena or the
PersistentArena. Use more explicit APIs to convey the intent directly
instead of relying on parameters or defaults. We were not always
consistent about this.
DeltaFile
+13-14clang-tools-extra/clang-doc/Serialize.cpp
+6-7clang-tools-extra/clang-doc/benchmarks/ClangDocBenchmark.cpp
+6-5clang-tools-extra/clang-doc/BitcodeReader.cpp
+4-5clang-tools-extra/clang-doc/Representation.cpp
+7-1clang-tools-extra/clang-doc/Representation.h
+36-325 files

LLVM/project 30bc65fllvm/lib/Target/AArch64 AArch64AsmPrinter.cpp AArch64InstrInfo.td, llvm/lib/Target/AArch64/AsmParser AArch64AsmParser.cpp

[PAC][ELF] Support R_AARCH64_AUTH_TLSDESC_CALL relocation

The R_AARCH64_AUTH_TLSDESC_CALL is introduced to allow linker relaxation of
AUTH TLSDESC call sequences for non-preemptible undefined weak symbols.

The lld patch introducing the relaxation: #194636

Corresponding ARM docs PR: https://github.com/ARM-software/abi-aa/pull/395
DeltaFile
+11-6llvm/lib/Target/AArch64/AsmParser/AArch64AsmParser.cpp
+12-3llvm/lib/Target/AArch64/AArch64AsmPrinter.cpp
+10-5llvm/test/CodeGen/AArch64/ptrauth-arm64-tls-dynamics.ll
+9-0llvm/lib/Target/AArch64/MCTargetDesc/AArch64MCCodeEmitter.cpp
+8-0llvm/lib/Target/AArch64/AArch64InstrInfo.td
+3-0llvm/test/MC/AArch64/directives-case_insensitive.s
+53-141 files not shown
+54-147 files

LLVM/project 21d1e21llvm/utils/FileCheck FileCheck.cpp

Replace MarkerRange::truncate with new constructor

`truncate` was ok before this patch, but now it is unclear what
happens if the original `MarkerRange` had `ShowExclusive==true`.  In
that case, it seems like maybe we should end up with a range marking
the characters before and after the one character, but instead we
always end up with a single marker at just the one character.
Currently, `truncate` is never called for that case, but it is better
to keep the API clear for the future.  Constructing an entirely new
`MarkerRange` makes it clearer to me that it knows nothing about the
old `MarkerRange`'s `ShowExclusive`.  If needed later, we can add a
`ShowExclusive` parameter to the new constructor.
DeltaFile
+4-3llvm/utils/FileCheck/FileCheck.cpp
+4-31 files

LLVM/project 79a0c1dlld/ELF RelocScan.h, lld/ELF/Arch AArch64.cpp

Support R_AARCH64_AUTH_TLSDESC_CALL
DeltaFile
+20-53lld/ELF/Arch/AArch64.cpp
+9-6lld/test/ELF/aarch64-tlsdesc-pauth.s
+3-1lld/ELF/RelocScan.h
+1-1lld/test/ELF/aarch64-reloc-pauth-undef-weak-pie.s
+1-1lld/test/ELF/aarch64-reloc-pauth-undef-weak-dso.s
+1-1lld/test/ELF/aarch64-reloc-pauth-undef-weak.s
+35-636 files