LLVM/project 0d23e3fmlir/include/mlir-c/Dialect Bufferization.h, mlir/include/mlir/Dialect/Affine Passes.td Passes.h

[MLIR] Add missing dialects to C API (#82190)

We are trying to make a wrapper of MLIR for Julia in
https://github.com/JuliaLabs/MLIR.jl, but some dialects are missing in
`libMLIR-C`. This PR adds them.
DeltaFile
+367-114mlir/lib/CAPI/Dialect/CMakeLists.txt
+0-454mlir/include/mlir/Dialect/Affine/Passes.td
+454-0mlir/include/mlir/Dialect/Affine/Transforms/Passes.td
+0-145mlir/include/mlir/Dialect/Affine/Passes.h
+145-0mlir/include/mlir/Dialect/Affine/Transforms/Passes.h
+28-0mlir/include/mlir-c/Dialect/Bufferization.h
+994-713125 files not shown
+2,432-772131 files

LLVM/project 7bbaf2ellvm/lib/Target/AMDGPU GCNSubtarget.h AMDGPUInstructionSelector.cpp, llvm/test/CodeGen/AMDGPU llvm.amdgcn.wave.shuffle.ll

[AMDGPU] Improve llvm.amdgcn.wave.shuffle handling for pre-GFX8 (#174845)

Before, GlobalISel would still return true for lowering the intrinsic
for GFX7 and earlier even though the required ds_bpermute_b32
instruction is not supported. After this change, GlobalISel will
properly report failure to select in this case. Testing is updated
appropriately.

Signed-off-by: Domenic Nutile <domenic.nutile at gmail.com>
DeltaFile
+5-4llvm/test/CodeGen/AMDGPU/llvm.amdgcn.wave.shuffle.ll
+4-0llvm/lib/Target/AMDGPU/GCNSubtarget.h
+3-0llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.cpp
+12-43 files

LLVM/project 31b93d6llvm/lib/Transforms/Vectorize VPlan.h VPlanValue.h

[VPlan] Add specialized VPValue subclasses for different types (NFC) (#172758)

This patch adds VPValue sub-classes for the different cases we currently
have:
 * VPIRValue: A live-in VPValue that wraps an underlying IR value
* VPSymbolicValue: A symbolic VPValue not tied to an underlying value,
e.g. the vector trip count or VF VPValues
 * VPRecipeValue: A VPValue defined by a VPDef/VPRecipeBase.

This has multiple benefits:
 * clearer constructors for each kind of VPValue
* limited scope: for example allows moving VPDef member to VPRecipeValue,
reducing size of other VPValues.
* stricter type checking for member variables (e.g. using VPLiveIn in
the Value -> live-in map in VPlan, or using VPSymbolicValue for symbolic
member VPValues)

There probably are additional opportunities for cleanups as follow-ups.

PR: https://github.com/llvm/llvm-project/pull/172758
DeltaFile
+63-54llvm/lib/Transforms/Vectorize/VPlan.h
+68-40llvm/lib/Transforms/Vectorize/VPlanValue.h
+43-35llvm/lib/Transforms/Vectorize/VPlan.cpp
+22-21llvm/lib/Transforms/Vectorize/VPlanTransforms.cpp
+14-12llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp
+10-15llvm/lib/Transforms/Vectorize/VPlanPatternMatch.h
+220-1779 files not shown
+251-20615 files

LLVM/project bc8fcballvm/lib/IR AutoUpgrade.cpp, llvm/test/Assembler auto_upgrade_nvvm_intrinsics.ll

[NVPTX][AutoUpgrade] Use integer min/max intrinsics instead of icmp, select (#173097)

DeltaFile
+12-24llvm/test/Assembler/auto_upgrade_nvvm_intrinsics.ll
+13-22llvm/lib/IR/AutoUpgrade.cpp
+25-462 files

LLVM/project 6e6996ellvm/test/Transforms/LoopVectorize select-min-max-last-index-epilogue.ll

[LV] Add tests for argmin/argmax with epilogue vectorization. (NFC)

Add additional test coverage for vectorizing argmin/argmax with epilogue
vectorization.
DeltaFile
+370-0llvm/test/Transforms/LoopVectorize/select-min-max-last-index-epilogue.ll
+370-01 files

LLVM/project f6cb5bbllvm/include/llvm/Support KnownFPClass.h, llvm/lib/Analysis ValueTracking.cpp

InstCombine: Handle rounding intrinsics in SimplifyDemandedFPClass
DeltaFile
+46-72llvm/test/Transforms/InstCombine/simplify-demanded-fpclass-rounding-intrinsics.ll
+66-0llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
+28-0llvm/lib/Support/KnownFPClass.cpp
+2-20llvm/lib/Analysis/ValueTracking.cpp
+7-0llvm/include/llvm/Support/KnownFPClass.h
+149-925 files

LLVM/project 89bd12fllvm/test/Transforms/InstCombine simplify-demanded-fpclass-rounding-intrinsics.ll

InstCombine: Add SimplifyDemandedFPClass tests for round

Add tests for the family of rounding intrinsics
DeltaFile
+943-0llvm/test/Transforms/InstCombine/simplify-demanded-fpclass-rounding-intrinsics.ll
+943-01 files

LLVM/project 7541574llvm/lib/Support KnownFPClass.cpp, llvm/test/Transforms/Attributor nofpclass-sqrt.ll

ValueTracking: sqrt never returns subnormal
DeltaFile
+52-52llvm/test/Transforms/Attributor/nofpclass-sqrt.ll
+14-14llvm/unittests/Analysis/ValueTrackingTest.cpp
+2-5llvm/test/Transforms/InstCombine/simplify-demanded-fpclass-sqrt.ll
+1-0llvm/lib/Support/KnownFPClass.cpp
+69-714 files

LLVM/project 5aa7700llvm/include/llvm/Support KnownFPClass.h, llvm/lib/Analysis ValueTracking.cpp

InstCombine: Implement SimplifyDemandedFPClass for sqrt
DeltaFile
+38-0llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
+10-19llvm/lib/Analysis/ValueTracking.cpp
+24-0llvm/lib/Support/KnownFPClass.cpp
+9-14llvm/test/Transforms/InstCombine/simplify-demanded-fpclass-sqrt.ll
+4-0llvm/include/llvm/Support/KnownFPClass.h
+85-335 files

LLVM/project c444020llvm/include/llvm/IR IntrinsicsNVVM.td

[LLVM][NVPTX] Mark ldmatrix/stmatrix intrinsics convergent (#174669)

NVVM ldmatrix and stmatrix intrinsics map to corresponding PTX
instructions that have a .sync.aligned behavior. Mark these intrinsics
as convergent to prevent control flow transformations that can break
these semantics. This is similar to other .sync.aligned intrinsics.
DeltaFile
+3-3llvm/include/llvm/IR/IntrinsicsNVVM.td
+3-31 files

LLVM/project 0b13ae6llvm/lib/Support/Unix Path.inc, llvm/lib/Support/Windows Path.inc

[llvm] Bypass sandbox for `getMainExecutable()` (#174816)

Getting the executable path is a fairly common operation in LLVM tools
that doesn't affect their outputs. Allow calling it under the sandbox.
DeltaFile
+2-0llvm/lib/Support/Unix/Path.inc
+2-0llvm/lib/Support/Windows/Path.inc
+4-02 files

LLVM/project 66df6ccllvm/lib/Target/DirectX DXILIntrinsicExpansion.cpp

[DirectX] Specify NegZero as signed (#174840)

#171456 set `ImplicitTrunc` to false by default. So `NegZero` value was
no longer being created as a signed integer.

This caused a similar crash during `DXILIntrinsicExpansion` as reported
here:
https://github.com/llvm/llvm-project/pull/171456#issuecomment-3718690088.

This change fixes the test case from crashing in the DirectX backend by
manually specifying it as a signed integer.
DeltaFile
+2-1llvm/lib/Target/DirectX/DXILIntrinsicExpansion.cpp
+2-11 files

LLVM/project 92f368clibc/src/__support/wctype/conversion CMakeLists.txt, libc/src/__support/wctype/conversion/random fastrand.h CMakeLists.txt

[libc][wctype] Upstream fastrand from PtrHash-cc prototype to LLVM libc
DeltaFile
+78-0libc/src/__support/wctype/conversion/random/fastrand.h
+7-0libc/src/__support/wctype/conversion/random/CMakeLists.txt
+1-0libc/src/__support/wctype/conversion/CMakeLists.txt
+86-03 files

LLVM/project 87f02dblibc/src/__support/wctype/conversion/utils enumerate.h enumerate.hpp

fix extension
DeltaFile
+70-0libc/src/__support/wctype/conversion/utils/enumerate.h
+0-70libc/src/__support/wctype/conversion/utils/enumerate.hpp
+70-702 files

LLVM/project 91baf48libc/src/__support/wctype/conversion/utils utils.h CMakeLists.txt

[libc][wctype] Upstream common utils header file from PtrHash-cc prototype to LLVM libc
DeltaFile
+212-0libc/src/__support/wctype/conversion/utils/utils.h
+12-0libc/src/__support/wctype/conversion/utils/CMakeLists.txt
+224-02 files

LLVM/project 877c212libc/src/__support/wctype/conversion/utils slice.h

fix nesting
DeltaFile
+7-2libc/src/__support/wctype/conversion/utils/slice.h
+7-21 files

LLVM/project b539127libc/src/__support/wctype/conversion/utils slice.h CMakeLists.txt

[libc][wctype] Upstream custom slice implementation from PtrHash-cc prototype to LLVM libc
DeltaFile
+113-0libc/src/__support/wctype/conversion/utils/slice.h
+12-0libc/src/__support/wctype/conversion/utils/CMakeLists.txt
+125-02 files

LLVM/project eb6c5c4libc/src/__support/wctype/conversion/utils utils.h

fix nesting
DeltaFile
+6-2libc/src/__support/wctype/conversion/utils/utils.h
+6-21 files

LLVM/project d60a030libc/src/__support/wctype/conversion/utils enumerate.hpp

fix nesting
DeltaFile
+6-2libc/src/__support/wctype/conversion/utils/enumerate.hpp
+6-21 files

LLVM/project 2e3daa0libc/src/__support/wctype/conversion/utils enumerate.hpp CMakeLists.txt

[libc][wctype] Upstream enumerate header from PtrHash-cc prototype to LLVM libc
DeltaFile
+66-0libc/src/__support/wctype/conversion/utils/enumerate.hpp
+10-0libc/src/__support/wctype/conversion/utils/CMakeLists.txt
+76-02 files

LLVM/project 5ff4ad9libc/src/__support/wctype/conversion/utils utils.h

include range and chunk utils
DeltaFile
+166-1libc/src/__support/wctype/conversion/utils/utils.h
+166-11 files

LLVM/project ea7f3a3libc/src/__support/wctype/conversion/utils slice.h

format
DeltaFile
+0-1libc/src/__support/wctype/conversion/utils/slice.h
+0-11 files

LLVM/project 2ea4833libc/src/__support/wctype/conversion/utils zip.h

fix nesting
DeltaFile
+6-2libc/src/__support/wctype/conversion/utils/zip.h
+6-21 files

LLVM/project d5ab2a6libc/src/__support/wctype CMakeLists.txt, libc/src/__support/wctype/conversion CMakeLists.txt

[libc][wctype] Upstream zip utility from PtrHash-cc prototype to LLVM libc
DeltaFile
+74-0libc/src/__support/wctype/conversion/utils/zip.h
+7-0libc/src/__support/wctype/conversion/utils/CMakeLists.txt
+2-0libc/src/__support/wctype/CMakeLists.txt
+1-0libc/src/__support/wctype/conversion/CMakeLists.txt
+84-04 files

LLVM/project da231aallvm/test/CodeGen/WebAssembly simd-unsupported.ll

fix regex
DeltaFile
+2-2llvm/test/CodeGen/WebAssembly/simd-unsupported.ll
+2-21 files

LLVM/project fd56531llvm/include/llvm/Support KnownFPClass.h, llvm/lib/Support KnownFPClass.cpp

InstCombine: Handle fadd in SimplifyDemandedFPClass

Note some of the tests currently fail with alive, but not
due to this patch. Namely, when performing the fadd x, 0 -> x
simplification in functions with non-IEEE denormal handling.
The existing instsimplify ignores the denormals-are-zero hazard by
checking cannotBeNegativeZero instead of isKnownNeverLogicalZero.

Also note the self handling doesn't really do anything yet, other
than propagate consistent known-fpclass information until there is
multiple use support.

This also leaves behind the original ValueTracking support, without
switching to the new KnownFPClass:fadd utility. This will be easier
to clean up after the subsequent fsub support patch.
DeltaFile
+60-86llvm/test/Transforms/InstCombine/simplify-demanded-fpclass-fadd.ll
+99-0llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
+42-0llvm/lib/Support/KnownFPClass.cpp
+10-0llvm/include/llvm/Support/KnownFPClass.h
+211-864 files

LLVM/project df9c0fallvm/test/Transforms/InstCombine simplify-demanded-fpclass-fadd.ll

InstCombine: Add baseline tests for fadd SimplifyDemandedFPClass handling
DeltaFile
+1,600-0llvm/test/Transforms/InstCombine/simplify-demanded-fpclass-fadd.ll
+1,600-01 files

LLVM/project 5ccba1bclang/lib/CIR/CodeGen CIRGenBuiltinX86.cpp, clang/test/CIR/CodeGenBuiltins/X86 ssse3-builtins.c avx512bw-builtins.c

[CIR] Upstream CIR codegen for palignr x86 builtins (#173788)

Part of #167752.

This PR upstreams CIR codegen for `palignr` x86 builtins.
DeltaFile
+39-5clang/lib/CIR/CodeGen/CIRGenBuiltinX86.cpp
+33-0clang/test/CIR/CodeGenBuiltins/X86/ssse3-builtins.c
+18-8clang/test/CIR/CodeGenBuiltins/X86/avx512bw-builtins.c
+12-0clang/test/CIR/CodeGenBuiltins/X86/avx2-builtins.c
+102-134 files

LLVM/project 36e7d6cllvm/lib/Analysis ValueTracking.cpp, llvm/test/Transforms/Attributor nofpclass-fdiv.ll nofpclass-frem.ll

ValueTracking: Rule out nan for fdiv self special case

Addresses TODO for signaling nan handling.
DeltaFile
+20-2llvm/lib/Analysis/ValueTracking.cpp
+9-9llvm/test/Transforms/Attributor/nofpclass-fdiv.ll
+9-9llvm/test/Transforms/Attributor/nofpclass-frem.ll
+38-203 files

LLVM/project 214643ellvm/lib/Analysis ValueTracking.cpp, llvm/test/Transforms/Attributor nofpclass-fdiv.ll

ValueTracking: Improve sign bit handling for fdiv

This is the fdiv version of 5020e0ff1494137ff12b4ed7c8fa896f8088b17b for
fmul.
DeltaFile
+14-3llvm/lib/Analysis/ValueTracking.cpp
+3-3llvm/test/Transforms/Attributor/nofpclass-fdiv.ll
+17-62 files