LLVM/project 96eb803llvm/test/CodeGen/Generic bswap.ll, llvm/test/Integer 2007-01-19-TruncSext.ll

[𝘀𝗽𝗿] initial version

Created using spr 1.3.7
DeltaFile
+0-50llvm/test/CodeGen/Generic/bswap.ll
+27-9llvm/test/Transforms/LICM/2003-12-11-SinkingToPHI.ll
+0-3llvm/test/Integer/2007-01-19-TruncSext.ll
+27-623 files

LLVM/project 234b210llvm/utils/TableGen/Basic DirectiveEmitter.cpp

Restore include of Spelling.h
DeltaFile
+1-0llvm/utils/TableGen/Basic/DirectiveEmitter.cpp
+1-01 files

LLVM/project 27bbf2ellvm/lib/Frontend/OpenMP OMP.cpp

Remove old (leftover) version array
DeltaFile
+0-1llvm/lib/Frontend/OpenMP/OMP.cpp
+0-11 files

LLVM/project 2e718bellvm/lib/Target/Mips MipsSERegisterInfo.cpp

Mips: Avoid a use of MachineOperand parents (#220071)

The operand here was only used to get the parent function to
query the subtarget.

Co-authored-by: Claude (Claude-Opus-4.8)
DeltaFile
+5-7llvm/lib/Target/Mips/MipsSERegisterInfo.cpp
+5-71 files

LLVM/project c4cef37llvm/utils/TableGen/Basic DirectiveEmitter.cpp

Apply batched suggestions from code review

Co-authored-by: Alexey Bataev <a.bataev at gmx.com>
DeltaFile
+3-3llvm/utils/TableGen/Basic/DirectiveEmitter.cpp
+3-31 files

LLVM/project 173e6e3llvm/lib/Target/AMDGPU AMDGPU.td

[AMDGPU] Expose 1536-physical-vgprs to the TargetParser

Add Feature1536VGPRs to AMDGPUFrontendVisibleFeatures so the per-GPU
feature bitset carries FEAT_1536_PHYSICAL_VGPRS, and list it in
FrontendOnlyFeatures so it is not serialized into the target-feature
string. This is a prerequisite for querying the VGPR allocation granule
from the TargetParser; there is no functional change.

Change-Id: Icdff14fbe3a734e49f8fe3d933eceb11def686ec
Co-Authored-By: Claude Opus 5 (1M context) <noreply at anthropic.com>
DeltaFile
+1-0llvm/lib/Target/AMDGPU/AMDGPU.td
+1-01 files

LLVM/project d097d2cllvm/include/llvm/TargetParser AMDGPUTargetParser.h, llvm/lib/Target/AMDGPU AMDGPU.td

[AMDGPU] Add getVGPRAllocGranule to TargetParser

Add getVGPRAllocGranule(GPUKind) and getVGPRAllocGranule(SubArchType) so
the VGPR allocation granule can be queried from a GPU name alone, without
an MCSubtargetInfo. This is to aid in resolving
https://github.com/ROCm/llvm-project/issues/3298 : "Comgr should use
target information from upstream TargetParser rather than maintaining
its own".

The wavefront size is a per-kernel mode rather than a property of the
GPU, so it stays an explicit parameter. IsaInfo::getVGPRAllocGranule
keeps its signature and now forwards to the new entry point, leaving the
dynamic VGPR block size - which is likewise not a GPU property - in the
backend. There is no functional change.

Change-Id: I85900e505b3fe6eb837e178cc3f474fe14dcba47
Co-Authored-By: Claude Opus 5 (1M context) <noreply at anthropic.com>
DeltaFile
+28-0llvm/unittests/TargetParser/TargetParserTest.cpp
+16-0llvm/lib/TargetParser/AMDGPUTargetParser.cpp
+3-7llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
+8-0llvm/include/llvm/TargetParser/AMDGPUTargetParser.h
+0-1llvm/lib/Target/AMDGPU/AMDGPU.td
+55-85 files

LLVM/project d4a5fbcllvm/lib/Target/AMDGPU AMDGPU.td, llvm/lib/TargetParser AMDGPUTargetParser.cpp

[AMDGPU] Expose subtarget feature `Feature1536VGPRs` to the TargetParser (#220063)

Co-authored-by: Claude Opus 5 (1M context) <noreply at anthropic.com>
DeltaFile
+4-4llvm/lib/TargetParser/AMDGPUTargetParser.cpp
+1-1llvm/lib/Target/AMDGPU/AMDGPU.td
+5-52 files

LLVM/project 696f97elibcxx/include memory, libcxx/include/__memory shared_ptr.h

[libc++] Add missing noexcept on shared_ptr assignment (#219533)

The Standard declares it as noexcept in [util.smartptr.shared.assign].
Also add a couple of missing tests.
DeltaFile
+3-1libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr_rv.pass.cpp
+3-1libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr_Y_rv.pass.cpp
+3-1libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr_Y.pass.cpp
+3-1libcxx/test/std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/shared_ptr.pass.cpp
+1-1libcxx/include/memory
+1-1libcxx/include/__memory/shared_ptr.h
+14-66 files

LLVM/project edc4667llvm/lib/Target/AMDGPU SIMemoryLegalizer.cpp, llvm/test/CodeGen/AMDGPU av-invalid-scope.ll memory-legalizer-invalid-syncscope.ll

AMDGPU: Lowercase the unsupported fence sync scope diagnostic

Error messages should start with a lowercase letter per the diagnostic
policy.

Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
DeltaFile
+5-5llvm/test/CodeGen/AMDGPU/memory-legalizer-invalid-syncscope.ll
+3-3llvm/lib/Target/AMDGPU/SIMemoryLegalizer.cpp
+2-2llvm/test/CodeGen/AMDGPU/av-invalid-scope.ll
+10-103 files

LLVM/project 63d57f9clang/include/clang/Basic DiagnosticSemaKinds.td, clang/lib/Sema SemaAMDGPU.cpp

clang/AMDGPU: Diagnose invalid fence sync scope

Reject an unrecognized synchronization scope string passed to
__builtin_amdgcn_fence during semantic analysis instead of relying on
the backend to report it during codegen.

Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
DeltaFile
+10-0clang/lib/Sema/SemaAMDGPU.cpp
+2-4clang/test/Sema/builtin-amdgcn-fence-failure.cpp
+2-0clang/include/clang/Basic/DiagnosticSemaKinds.td
+14-43 files

LLVM/project 41e4d96clang/test/AST/HLSL Textures-vector-AST.hlsl Textures-scalar-AST.hlsl, clang/test/CodeGenHLSL/resources Textures-SampleBias.hlsl Textures-SampleCmp.hlsl

[HLSL] Implement TextureCube resource type (#218520)

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

This PR implements the TextureCube type in HLSL. 
It registers a new TextureCube type much like the existing Texture2D,
but excludes methods that do not apply to cube textures. Codegen has
been modified to also support sampling methods that lack an offset
parameter but still have a clamp parameter.

Texture tests have also been modified to add support for TextureCube.
Some tests simply add a new RUN line for TextureCube, while others
needed new check prefixes and macros to accomodate the texels, offsets,
etc.

Assisted by: Claude Opus 5

---


    [2 lines not shown]
DeltaFile
+541-518clang/test/AST/HLSL/Textures-scalar-AST.hlsl
+537-514clang/test/AST/HLSL/Textures-vector-AST.hlsl
+131-77clang/test/CodeGenHLSL/resources/Textures-SampleGrad.hlsl
+119-63clang/test/CodeGenHLSL/resources/Textures-Sample.hlsl
+110-53clang/test/CodeGenHLSL/resources/Textures-SampleCmp.hlsl
+101-44clang/test/CodeGenHLSL/resources/Textures-SampleBias.hlsl
+1,539-1,26923 files not shown
+2,308-1,50829 files

LLVM/project b01d7c4llvm/lib/Target/RISCV RISCVInstrInfoVVLPatterns.td, llvm/test/CodeGen/RISCV/rvv vpmerge-sdnode-bf16.ll vselect-fp.ll

[RISCV] Add patterns to select vmerge.vxm/vim for bf16 and f16 vectors. (#219640)

With zvfhmin/zvfbfmin, vfmv.v.f isn't supported so we can end up with a
bitcast from vmv.v.x.

Assisted-by: Claude
DeltaFile
+192-432llvm/test/CodeGen/RISCV/rvv/vitofp-sdnode.ll
+64-144llvm/test/CodeGen/RISCV/rvv/fixed-vectors-i2fp.ll
+24-48llvm/test/CodeGen/RISCV/rvv/vpmerge-sdnode.ll
+17-38llvm/test/CodeGen/RISCV/rvv/vselect-fp.ll
+12-24llvm/test/CodeGen/RISCV/rvv/vpmerge-sdnode-bf16.ll
+28-0llvm/lib/Target/RISCV/RISCVInstrInfoVVLPatterns.td
+337-6868 files not shown
+402-77214 files

LLVM/project 1f8db39clang/include/clang/Basic DiagnosticSemaKinds.td, clang/lib/Sema SemaAMDGPU.cpp

clang/AMDGPU: Diagnose invalid fence sync scope

Reject an unrecognized synchronization scope string passed to
__builtin_amdgcn_fence during semantic analysis instead of relying on
the backend to report it during codegen.

Co-authored-by: Claude (Claude-Opus-4.8) <noreply at anthropic.com>
DeltaFile
+11-0clang/lib/Sema/SemaAMDGPU.cpp
+2-4clang/test/Sema/builtin-amdgcn-fence-failure.cpp
+2-0clang/include/clang/Basic/DiagnosticSemaKinds.td
+15-43 files

LLVM/project ceb0e18mlir/lib/Conversion/XeVMToLLVM XeVMToLLVM.cpp, mlir/test/Conversion/XeVMToLLVM xevm_fp_conversion_lengths.mlir

[MLIR][XeVM] Support all SPIR-V vector lengths in truncf and extf (#217768)

The fp8 and fp4 conversions only lowered a 16 element vector. Lower
every SPIR-V vector length, 2, 3, 4, 8 and 16, for both formats and for
f16 and bf16 operands, following IGC's SPV_INTEL_fp_conversions
implementation.

Two fp4 values pack into a single byte, and SPIR-V uses a scalar where
it has no one element vector, so the packed side of that conversion is a
scalar. The verifier previously required both operands to be vectors or
both scalars, which rejected it. It now checks that the packed side is
exactly wide enough to hold the values it carries, which both permits
that case and catches mismatched lengths that used to pass.

Also fixes two latent bugs in the shuffle legalization that the new IR
reaches: a null dereference when a shuffle reads a bitcast of a scalar,
and a mask computed by a division that could drop a remainder, which
built an invalid shuffle when the extracted slice did not cover whole
source elements.

    [2 lines not shown]
DeltaFile
+241-131mlir/lib/Conversion/XeVMToLLVM/XeVMToLLVM.cpp
+219-0mlir/test/Conversion/XeVMToLLVM/xevm_fp_conversion_lengths.mlir
+193-0mlir/test/Integration/Dialect/XeVM/GPU/xevm_truncf_extf_roundtrip_fp4_bf16_lengths.mlir
+193-0mlir/test/Integration/Dialect/XeVM/GPU/xevm_truncf_extf_roundtrip_bf16_lengths.mlir
+189-0mlir/test/Integration/Dialect/XeVM/GPU/xevm_truncf_extf_roundtrip_fp4_lengths.mlir
+189-0mlir/test/Integration/Dialect/XeVM/GPU/xevm_truncf_extf_roundtrip_fp8_lengths.mlir
+1,224-1313 files not shown
+1,292-1619 files

LLVM/project f20c67ellvm/lib/Target/BPF BPFMISimplifyPatchable.cpp

BPF: Avoid depending on operand parents in BPFMISimplifyPatchable

Take the containing instruction and the relocation operand index instead
of a MachineOperand pointer. The operand was only used to identify which
source operand it was, so an index suffices and removes the getParent
recovery.

Co-authored-by: Claude (Claude-Opus-4.8)
DeltaFile
+23-24llvm/lib/Target/BPF/BPFMISimplifyPatchable.cpp
+23-241 files

LLVM/project af7309dclang/lib/Headers/hlsl hlsl_detail.h hlsl_alias_intrinsics.h, clang/test/CodeGenHLSL/builtins select.hlsl

[HLSL][LongVec] Add support for select (#219603)

resolves #219592

Some of our pure HLSL intrinsics use the select intrinsic. We can't
convert those intrinsics until select is done first.

Since we need long vectors we can rewrite all the select overloads into
a single template per argument type.

For scalar/scalar, I replaced vector size overloads with a forwarding
template that:
- Deduces N from vector<U, N> Conds
- Converts conditions to vector<boo,N>

For Vector Scalar, Scalar Vector, and Vector Vector we needed a type
identity trait since the first argument is a boolean vector for select.
I use it only around the condition parameter for overloads where N is
already deduced from a vector value operand.
DeltaFile
+16-45clang/lib/Headers/hlsl/hlsl_alias_intrinsics.h
+40-1clang/test/CodeGenHLSL/builtins/select.hlsl
+6-0clang/lib/Headers/hlsl/hlsl_detail.h
+62-463 files

LLVM/project 4333a9dllvm/lib/Target/Mips MipsSERegisterInfo.cpp

Mips: Avoid a use of MachineOperand parents

The operand here was only used to get the parent function to
query the subtarget.

Co-authored-by: Claude (Claude-Opus-4.8)
DeltaFile
+5-7llvm/lib/Target/Mips/MipsSERegisterInfo.cpp
+5-71 files

LLVM/project 236d047clang/lib/Driver/ToolChains UEFI.cpp Solaris.cpp, clang/test/Driver fsanitize-undefined-device-offload.c

[Clang] Enable UBSan for AMDGPU device offload

Summary:
This enables the device UBSan runtime for AMDGPU decides. Primarily this
required modifications to the `addSanitizerRuntime` interface so we can
query the compilation's offload status. Also need to forward it through
the linker wrapper interface. Works on all AMDGPU offload, slight hacks
around the other targets as they do not advertise sanitizer
runtimes properly.

This is linked in via a new `-u __ubsan_device_initialize` hook to pull
in the side library. This is standard behavior and keeps the core logic
mostly unchanged and re-used.
DeltaFile
+50-0clang/test/Driver/fsanitize-undefined-device-offload.c
+32-3clang/lib/Driver/ToolChains/CommonArgs.cpp
+2-2clang/lib/Driver/ToolChains/Hexagon.cpp
+2-1clang/lib/Driver/ToolChains/Clang.cpp
+1-1clang/lib/Driver/ToolChains/UEFI.cpp
+1-1clang/lib/Driver/ToolChains/Solaris.cpp
+88-813 files not shown
+98-1819 files

LLVM/project 31651decompiler-rt/cmake/caches AMDGPU.cmake, compiler-rt/lib CMakeLists.txt

Comments, fix cache, fix failure with Die(), properly ignore i128 for now
DeltaFile
+82-18compiler-rt/lib/ubsan/device/ubsan_device_report.cpp
+21-0compiler-rt/test/ubsan/AMDGPU/overflow-i128.hip
+11-3compiler-rt/lib/ubsan/device/ubsan_device_rpc.cpp
+5-1compiler-rt/lib/ubsan/device/ubsan_device_hsa.cpp
+0-3compiler-rt/lib/CMakeLists.txt
+1-1compiler-rt/cmake/caches/AMDGPU.cmake
+120-266 files

LLVM/project a7d40d9clang/test/CodeGenOpenCL backend-unsupported-warning.ll amdgpu-ieee.cl

clang/AMDGPU: Fix a few tests codegening the dummy target (#220047)

Use a real target triple name
DeltaFile
+6-6clang/test/CodeGenOpenCL/amdgpu-ieee.cl
+2-2clang/test/CodeGenOpenCL/backend-unsupported-warning.ll
+8-82 files

LLVM/project c0ef36fllvm/lib/Target/RISCV RISCVOptWInstrs.cpp

RISCV: Pass instruction and operand index to vectorPseudoHasAllNBitUsers (#219993)

Take the user instruction and operand index directly instead of a
MachineOperand, so the helper no longer relies on getParent.

Co-authored-by: Claude (Claude-Opus-4.8)
DeltaFile
+3-4llvm/lib/Target/RISCV/RISCVOptWInstrs.cpp
+3-41 files

LLVM/project ded2141llvm/lib/Target/AMDGPU AMDGPUSubtarget.h AMDGPUAsmPrinter.cpp, llvm/lib/Target/AMDGPU/Utils AMDGPUBaseInfo.h AMDGPUBaseInfo.cpp

[AMDGPU] Add getLDSAllocGranule to TargetParser

Add getLDSAllocGranule(GPUKind) and getLDSAllocGranule(SubArchType),
returning the LDS allocation granularity in bytes, so it can be queried
from a GPU name alone without an MCSubtargetInfo. This is to aid in
resolving https://github.com/ROCm/llvm-project/issues/3298 : "Comgr
should use target information from upstream TargetParser rather than
maintaining its own".

The granule is a pure function of the maximum addressable LDS size,
which the GPUInfo table already carries, so no TableGen change is
needed.

AMDGPU::getLdsDwGranularity returned the same quantity in dwords and all
three of its callers immediately converted to bytes, so it is removed:
GCNSubtarget initializes its cached LDSAllocationGranularity from the
new entry point, and a getter exposes that to AMDGPUAsmPrinter. There is
no functional change.


    [2 lines not shown]
DeltaFile
+19-0llvm/unittests/TargetParser/TargetParserTest.cpp
+19-0llvm/lib/TargetParser/AMDGPUTargetParser.cpp
+0-14llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
+4-5llvm/lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp
+6-0llvm/lib/Target/AMDGPU/AMDGPUSubtarget.h
+0-5llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h
+48-242 files not shown
+54-268 files

LLVM/project b158b0allvm/lib/Target/SystemZ SystemZXPLINKAsmPrinter.h SystemZXPLINKAsmPrinter.cpp

SystemZ: Avoid using operand parent in AssociatedDataAreaTable::insert (#220054)

Take the MachineFunction directly to reach the target and context
instead of recovering it through the operand's parent.

Co-authored-by: Claude (Claude-Opus-4.8)
DeltaFile
+4-4llvm/lib/Target/SystemZ/SystemZXPLINKAsmPrinter.cpp
+5-2llvm/lib/Target/SystemZ/SystemZXPLINKAsmPrinter.h
+9-62 files

LLVM/project c58b22fllvm/utils/gn/secondary/lldb/source/Plugins/Language/CPlusPlus BUILD.gn, llvm/utils/gn/secondary/llvm/lib/Target/Hexagon BUILD.gn

[gn build] Port commits (#220064)

9783d7c4b53f
aa8a7581de13
ad3c19a89842
cc9111a40f8a
d59fa1ca3426
deebdb554054
f7a44525d799
DeltaFile
+3-5llvm/utils/gn/secondary/llvm/test/BUILD.gn
+1-0llvm/utils/gn/secondary/llvm/unittests/Target/AMDGPU/BUILD.gn
+1-0llvm/utils/gn/secondary/llvm/unittests/Support/BUILD.gn
+1-0llvm/utils/gn/secondary/llvm/unittests/CodeGen/BUILD.gn
+1-0llvm/utils/gn/secondary/llvm/lib/Target/Hexagon/BUILD.gn
+1-0llvm/utils/gn/secondary/lldb/source/Plugins/Language/CPlusPlus/BUILD.gn
+8-52 files not shown
+10-58 files

LLVM/project 3d9891fclang/lib/CIR/CodeGen CIRGenRecordLayoutBuilder.cpp, clang/lib/CIR/Dialect/Transforms CallConvLoweringPass.cpp

[CIR] Record how far a bit-field's declared types reach on x86_64

A bit-field access unit is as wide as the compiler chooses, which can be
narrower than the types declared in it.  The x86_64 ABI reads how far those
declarations reach to tell the bytes after a unit from padding, and CIR had no
way to record it, so the bridge refused any padded record holding a named unit.

CIRGen now records that reach as a zero-length member beside the unit, the
shape a zero-width bit-field uses.  With the fact in the type, the bridge
drops the reject.  It also stops refusing unions like `union { int x : 3; }`,
where no member on its own is as wide as the union.

Assisted-by: Cursor / claude-opus-5
DeltaFile
+250-0clang/test/CIR/CodeGen/call-conv-lowering-x86_64-bitfield-reach.cpp
+64-69clang/lib/CIR/Dialect/Transforms/CallConvLoweringPass.cpp
+80-0clang/test/CIR/Transforms/abi-lowering/x86_64-bitfield-reach.cir
+61-2clang/lib/CIR/CodeGen/CIRGenRecordLayoutBuilder.cpp
+28-24clang/test/CIR/CodeGen/bitfield-init-values.c
+0-51clang/test/CIR/Transforms/abi-lowering/x86_64-aggregate-nyi.cir
+483-14617 files not shown
+624-27223 files

LLVM/project 2359bcellvm/lib/Target/Hexagon HexagonEarlyIfConv.cpp, llvm/test/CodeGen/Hexagon early-if-phi-undef.mir

Hexagon: Fix early if-conversion crash on an undef PHI operand (#216815)

Found by AI while working on something else.

Co-authored-by: Claude (Opus 4.8) <noreply at anthropic.com>
DeltaFile
+44-0llvm/test/CodeGen/Hexagon/early-if-phi-undef.mir
+1-3llvm/lib/Target/Hexagon/HexagonEarlyIfConv.cpp
+45-32 files

LLVM/project a07fe6bllvm/include/llvm/TargetParser AMDGPUTargetParser.h, llvm/lib/Target/AMDGPU AMDGPU.td

[AMDGPU] Add getVGPRAllocGranule to TargetParser

Add getVGPRAllocGranule(GPUKind) and getVGPRAllocGranule(SubArchType) so
the VGPR allocation granule can be queried from a GPU name alone, without
an MCSubtargetInfo. This is to aid in resolving
https://github.com/ROCm/llvm-project/issues/3298 : "Comgr should use
target information from upstream TargetParser rather than maintaining
its own".

The wavefront size is a per-kernel mode rather than a property of the
GPU, so it stays an explicit parameter. IsaInfo::getVGPRAllocGranule
keeps its signature and now forwards to the new entry point, leaving the
dynamic VGPR block size - which is likewise not a GPU property - in the
backend. There is no functional change.

Change-Id: I85900e505b3fe6eb837e178cc3f474fe14dcba47
Co-Authored-By: Claude Opus 5 (1M context) <noreply at anthropic.com>
DeltaFile
+28-0llvm/unittests/TargetParser/TargetParserTest.cpp
+16-0llvm/lib/TargetParser/AMDGPUTargetParser.cpp
+3-7llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
+8-0llvm/include/llvm/TargetParser/AMDGPUTargetParser.h
+1-2llvm/lib/Target/AMDGPU/AMDGPU.td
+56-95 files

LLVM/project 2978681clang/test/SemaOpenCL builtins-amdgcn-error-wave64.cl builtins-amdgcn-wave32-func-attr.cl

clang/AMDGPU: Use -fsyntax-only in some builtin sema tests (#220050)

Avoid codegening in sema tests.
DeltaFile
+5-5clang/test/SemaOpenCL/builtins-amdgcn-wave32-func-attr.cl
+3-3clang/test/SemaOpenCL/builtins-amdgcn-error-wave64.cl
+8-82 files

LLVM/project dfca2d4libcxx/include/__mutex once_flag.h

[libc++] Make once_flag pointer-sized on MinGW (#219895)

This is ABI breaking on MinGW. However, the impact is deemed small
enough that it's acceptable.
DeltaFile
+1-1libcxx/include/__mutex/once_flag.h
+1-11 files