LLVM/project 2853b38libcxx/include/__atomic atomic_ref.h

Revert "Don't use builtins for pointer overloads of fetch_max/min"

Try applying frederick's suggestion instead.
DeltaFile
+8-2libcxx/include/__atomic/atomic_ref.h
+8-21 files

LLVM/project 6190229libcxx/docs/ReleaseNotes 23.rst

Fix release note
DeltaFile
+2-1libcxx/docs/ReleaseNotes/23.rst
+2-11 files

LLVM/project ebd61a9libcxx/include/__atomic atomic_ref.h

Don't use builtins for pointer overloads of fetch_max/min

`__arg * sizeof(_Tp)` makes no sense in that context since __arg is a
pointer.
DeltaFile
+2-8libcxx/include/__atomic/atomic_ref.h
+2-81 files

LLVM/project e26e9ballvm/include/llvm/Analysis Loads.h, llvm/lib/Analysis Loads.cpp

[Loads][NFC] Add isDereferenceablePointer overload taking a size (#203905)

Quite a few places just end up passing `Align(1)` as the alignment.
Instead, provide an overload of `isDereferenceablePointer` taking a size
instead of a `Type*` and use that.
DeltaFile
+10-8llvm/include/llvm/Analysis/Loads.h
+3-3llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
+5-0llvm/lib/Analysis/Loads.cpp
+2-2llvm/lib/Transforms/Scalar/MergeICmps.cpp
+2-2llvm/lib/CodeGen/MachineOperand.cpp
+2-2llvm/lib/Transforms/Scalar/MemCpyOptimizer.cpp
+24-171 files not shown
+25-187 files

LLVM/project 688bc53llvm/lib/Target/SPIRV SPIRVInstructionSelector.cpp, llvm/test/CodeGen/SPIRV/transcoding load-atomic-ptr.ll atomic-load-store-unsupported.ll

[SPIRV] Let atomic load load pointers (#202823)

SPIRV atomic load permits only integer or floats as per SPIRV spec. When
compiling libc there several places in the code where pointers are
atomically loaded causing compilation to break. It can be fixed by using
casting in the libc code but in order to keep the libc code clean it is
preferrable to do it in SPIRV backend. This change will cast pointer
parameter to a pointer to integer of appropriate size and generate
atomic load instruction that uses integers per SPIRV spec. The value
returned by atomic load is casted to an original pointer type

---------

Co-authored-by: Dmitry Sidorov <dsidorov at amd.com>
DeltaFile
+54-5llvm/lib/Target/SPIRV/SPIRVInstructionSelector.cpp
+30-0llvm/test/CodeGen/SPIRV/transcoding/load-atomic-ptr.ll
+11-2llvm/test/CodeGen/SPIRV/transcoding/atomic-load-store-unsupported.ll
+95-73 files

LLVM/project a8bc4bbflang/lib/Lower/OpenMP Clauses.cpp, flang/lib/Parser openmp-parsers.cpp

format
DeltaFile
+1-1flang/lib/Lower/OpenMP/Clauses.cpp
+1-1flang/lib/Parser/openmp-parsers.cpp
+1-1flang/lib/Semantics/openmp-utils.cpp
+3-33 files

LLVM/project 1b51a09clang/lib/AST/ByteCode Interp.cpp Compiler.cpp, clang/test/AST/ByteCode dynamic-cast.cpp

[clang][bytecode] Actually implement `dynamic_cast` (#203489)

Do a full type search if necessary.
DeltaFile
+296-0clang/test/AST/ByteCode/dynamic-cast.cpp
+202-12clang/lib/AST/ByteCode/Interp.cpp
+16-5clang/lib/AST/ByteCode/Compiler.cpp
+3-1clang/lib/AST/ByteCode/Opcodes.td
+2-1clang/lib/AST/ByteCode/Interp.h
+2-0clang/lib/AST/ByteCode/InterpState.h
+521-191 files not shown
+522-197 files

LLVM/project d9f14calibc/src/__support endian_internal.h, libc/src/arpa/inet ntohs.cpp ntohl.cpp

[libc] Add Endian::from_{big,little}_endian (#203895)

This is actually the same function as its to_ counterpart, but it lets
us correctly express the intent.

The functions are already useful for implementing ntoh?, but I'll add
other uses of them soon.
DeltaFile
+10-0libc/src/__support/endian_internal.h
+1-4libc/src/arpa/inet/ntohs.cpp
+1-4libc/src/arpa/inet/ntohl.cpp
+4-0libc/test/src/__support/endian_internal_test.cpp
+16-84 files

LLVM/project ae85100flang/include/flang/Parser parse-tree.h, flang/lib/Lower/OpenMP Clauses.cpp ClauseProcessor.cpp

[flang][OpenMP] Parsing and semantics of locators as part of OmpObject

Allow function call references and reserved locator names as parts of
OmpObject. Function calls and array element accesses have the same syntax,
and the OmpObject parser will parse them as function calls. This is then
corrected (if needed) immediately after the name resolution is complete.

There are no clause-specific semantic checks of proper locators. Existing
code will check if a proper locator is specified on a clause that allows
it.

Lowering of proper locators to MLIR is not implemented, and a TODO
message is emitted.
DeltaFile
+40-9flang/lib/Lower/OpenMP/Clauses.cpp
+41-7flang/lib/Semantics/openmp-utils.cpp
+23-14flang/lib/Parser/openmp-parsers.cpp
+23-5flang/lib/Semantics/check-omp-structure.cpp
+12-11flang/include/flang/Parser/parse-tree.h
+22-0flang/lib/Lower/OpenMP/ClauseProcessor.cpp
+161-4631 files not shown
+319-10937 files

LLVM/project 46770bfmlir/include/mlir/Dialect/Linalg/IR LinalgInterfaces.h, mlir/lib/Bindings/Python DialectLinalg.cpp

[mlir][linalg] Add maps-based inferConvolutionDims overload (#203323)

This PR adds an overload of `inferConvolutionDims` that takes only
indexing maps (input, filter, output), mirroring the maps-based
`inferContractionDims` overload added in #76081, along with the
corresponding C API and python bindings.

Assisted by: Claude-code
DeltaFile
+136-0mlir/unittests/Dialect/Linalg/InferConvolutionDimsTest.cpp
+49-21mlir/lib/Dialect/Linalg/IR/LinalgInterfaces.cpp
+34-22mlir/lib/CAPI/Dialect/Linalg.cpp
+51-0mlir/test/python/dialects/linalg/utils.py
+32-0mlir/lib/Bindings/Python/DialectLinalg.cpp
+12-0mlir/include/mlir/Dialect/Linalg/IR/LinalgInterfaces.h
+314-431 files not shown
+318-437 files

LLVM/project 00671e0llvm/lib/CodeGen/GlobalISel GISelValueTracking.cpp, llvm/test/CodeGen/AArch64/GlobalISel knownbits-insert-vector.mir

[GlobalISel] Add known-bits for G_INSERT_VECTOR_ELT. (#200930)

This adds known-bits for G_INSERT_VECTOR_ELT, mostly a copy of the SDAG equivalent code.
DeltaFile
+99-0llvm/test/CodeGen/AArch64/GlobalISel/knownbits-insert-vector.mir
+31-0llvm/lib/CodeGen/GlobalISel/GISelValueTracking.cpp
+130-02 files

LLVM/project 7bc9882llvm/lib/Transforms/Utils SimplifyLibCalls.cpp, llvm/test/Transforms/InstCombine strcmp-memcmp.ll

[SimplifyLibCalls] Use context instruction strcmp->memcmp transform (#203893)

Pass the context instruction when checking for dereferenceability.
DeltaFile
+30-0llvm/test/Transforms/InstCombine/strcmp-memcmp.ll
+5-4llvm/lib/Transforms/Utils/SimplifyLibCalls.cpp
+35-42 files

LLVM/project 702fedfllvm/lib/Target/AMDGPU AMDGPUCallingConv.td, llvm/lib/Target/AMDGPU/Utils AMDGPUBaseInfo.cpp

review
DeltaFile
+110-22llvm/test/CodeGen/AMDGPU/sret-sgpr.ll
+7-4llvm/test/Analysis/UniformityAnalysis/AMDGPU/kernel-args.ll
+4-4llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.cpp
+2-4llvm/lib/Target/AMDGPU/AMDGPUCallingConv.td
+123-344 files

LLVM/project 28f5731llvm/test/Transforms/LoopVectorize/RISCV strided-accesses.ll

[LV] Pre-commit test case for strided accesses derived from lshr exact. nfc (#203488)
DeltaFile
+339-2llvm/test/Transforms/LoopVectorize/RISCV/strided-accesses.ll
+339-21 files

LLVM/project 6e6c296mlir/include/mlir/Interfaces ControlFlowInterfaces.h, mlir/lib/Dialect/Affine/IR AffineOps.cpp

[mlir] Use explicit op targets for region successors (#203552)

Replace the RegionSuccessor parent sentinel with an explicit Operation *
target. Operation successors now model continuing after that operation,
while region successors continue to point at Region.

Update RegionBranchOpInterface helpers, analyses, and dialect
implementations to use operation successors. This removes the ambiguity
of interpreting parent relative to whichever operation produced the
successor when introducing early-exits.

For downstream integration for this API change:

- `successor.isParent()` -> `successor.isOperation()`
- `RegionSuccessor::parent()` -> RegionSuccessor(op)` ; that means that
you need to have access to the target op. In general it is either
`getOperation()` or `getParentOp()` (depending if you're updating a
method on the `RegionBranchOpInterface` operation or on the terminator.

Assisted-by: Codex
DeltaFile
+30-26mlir/lib/Interfaces/ControlFlowInterfaces.cpp
+36-18mlir/include/mlir/Interfaces/ControlFlowInterfaces.h
+26-26mlir/lib/Dialect/SCF/IR/SCF.cpp
+20-20mlir/test/lib/Dialect/Test/TestOpDefs.cpp
+10-9mlir/lib/Dialect/Affine/IR/AffineOps.cpp
+8-8mlir/lib/Dialect/Transform/IR/TransformOps.cpp
+130-10725 files not shown
+215-18731 files

LLVM/project e295663flang/include/flang/Parser parse-tree.h, flang/lib/Lower/OpenMP Clauses.cpp ClauseProcessor.cpp

[flang][OpenMP] Parsing and semantics of locators as part of OmpObject

Allow function call references and reserved locator names as parts of
OmpObject. Function calls and array element accesses have the same syntax,
and the OmpObject parser will parse them as function calls. This is then
corrected (if needed) immediately after the name resolution is complete.

There are no clause-specific semantic checks of proper locators. Existing
code will check if a proper locator is specified on a clause that allows
it.

Lowering of proper locators to MLIR is not implemented, and a TODO
message is emitted.
DeltaFile
+40-9flang/lib/Lower/OpenMP/Clauses.cpp
+41-7flang/lib/Semantics/openmp-utils.cpp
+23-14flang/lib/Parser/openmp-parsers.cpp
+23-5flang/lib/Semantics/check-omp-structure.cpp
+12-11flang/include/flang/Parser/parse-tree.h
+22-0flang/lib/Lower/OpenMP/ClauseProcessor.cpp
+161-4630 files not shown
+313-10936 files

LLVM/project 989c2a4flang/lib/Semantics expression.cpp

format
DeltaFile
+3-4flang/lib/Semantics/expression.cpp
+3-41 files

LLVM/project e8faac2openmp/runtime/src kmp_adt.h kmp_adt.cpp, openmp/runtime/unittests/ADT TestStringRef.cpp

go away from string_view again
DeltaFile
+27-18openmp/runtime/src/kmp_adt.h
+33-2openmp/runtime/unittests/ADT/TestStringRef.cpp
+4-4openmp/runtime/src/kmp_adt.cpp
+64-243 files

LLVM/project 5388feamlir/include/mlir/Dialect/EmitC/IR EmitC.td, mlir/lib/Conversion/FuncToEmitC FuncToEmitC.cpp

[mlir][emitc] Support member access for values (#203308)

The `emitc.member` op is currently limited to taking lvalues of opaque
types representing structs and returning either lvalues or arrays of its
fields. Accessing members of SSA values of opaque types, therefore,
requires assigning them to an `emitc.variable`, applying `emitc.member`
to it and `emitc.load` to the member's lvalue. For users only wishing to
read members of a struct value, this should be redundant.

This PR extends `emitc.member` to handle struct values directly by
accepting opaque types as argument, as long as the result type is
neither an lvalue nor an array, which imply memory location. This
provides similar semantics to extracting elements out of SSA
tensors/vectors.
DeltaFile
+27-0mlir/lib/Dialect/EmitC/IR/EmitC.cpp
+7-14mlir/test/Target/Cpp/func.mlir
+17-1mlir/test/Dialect/EmitC/invalid_ops.mlir
+4-13mlir/lib/Conversion/FuncToEmitC/FuncToEmitC.cpp
+7-3mlir/lib/Target/Cpp/TranslateToCpp.cpp
+7-3mlir/include/mlir/Dialect/EmitC/IR/EmitC.td
+69-343 files not shown
+76-399 files

LLVM/project 5e2cb97llvm/lib/Target/AMDGPU AMDGPURegBankLegalizeRules.cpp AMDGPULegalizerInfo.cpp, llvm/test/CodeGen/AMDGPU maximumnum.ll minimumnum.ll

AMDGPU/GlobalISel: Legalizer and RegBankLegalize for pk_f64 min_num and max_num
DeltaFile
+60-64llvm/test/CodeGen/AMDGPU/maximumnum.ll
+60-64llvm/test/CodeGen/AMDGPU/minimumnum.ll
+17-2llvm/lib/Target/AMDGPU/AMDGPURegBankLegalizeRules.cpp
+8-1llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
+145-1314 files

LLVM/project 5fb08f4libc/src/netinet in6addr_loopback.h in6addr_any.h, libc/test/src/netinet in_test.cpp

[libc] Add the in6addr_{any,loopback} variables (#203579)

The existence of the variables is required by POSIX.

Assisted by Gemini.
DeltaFile
+26-0libc/src/netinet/in6addr_loopback.h
+26-0libc/src/netinet/in6addr_any.h
+25-0libc/src/netinet/in6addr_loopback.cpp
+25-0libc/src/netinet/CMakeLists.txt
+24-0libc/src/netinet/in6addr_any.cpp
+14-0libc/test/src/netinet/in_test.cpp
+140-06 files not shown
+160-112 files

LLVM/project 7dc09d0llvm/include/llvm/Support CHERICapabilityFormat.h, llvm/lib/Support CHERICapabilityFormat.cpp CMakeLists.txt

[CHERI] Add a Support utility for determining alignment requirements of CHERI capabilities. (#197402)

On CHERI systems with compressed bounds representations (which is all of
them that anyone cares about today), one of the tradeoffs to achieve
that compression is a requirement for larger allocations to be more
highly aligned. This impacts both code generation and linking in places
where globals need to be aligned and/or padded based on this
requirement. The specific alignment requirements vary by capability
format.

Co-authored-by: Alex Richardson <alexrichardson at google.com>
DeltaFile
+91-0llvm/unittests/Support/CHERICapabilityFormatTest.cpp
+77-0llvm/lib/Support/CHERICapabilityFormat.cpp
+53-0llvm/include/llvm/Support/CHERICapabilityFormat.h
+1-0llvm/unittests/Support/CMakeLists.txt
+1-0llvm/lib/Support/CMakeLists.txt
+223-05 files

LLVM/project 9ce06fdllvm/lib/Target/AMDGPU SIInsertWaitcnts.cpp, llvm/test/CodeGen/AMDGPU expert_scheduling_gfx1250.mir

[AMDGPU] Track LDS DMA VGPR source reads in expert scheduling (#203292)

LDS DMA instructions are marked as VALU but we need to treat them as
FLAT instructions for expert mode waitcnt insertion. This meant we were
missing a `vm_vsrc` wait for WAR and RAW on input registers of the LDS
DMA instruction.

I added lit tests for other memory ops as well to catch future
regressions.
DeltaFile
+103-0llvm/test/CodeGen/AMDGPU/expert_scheduling_gfx1250.mir
+4-2llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp
+107-22 files

LLVM/project 136ac86llvm/lib/Target/AMDGPU AMDGPURegBankLegalizeRules.cpp, llvm/test/CodeGen/AMDGPU fcanonicalize.ll

AMDGPU/GlobalISel: RegBankLegalize rules for pk_f64 fcanonicalize (#203870)
DeltaFile
+464-793llvm/test/CodeGen/AMDGPU/fcanonicalize.ll
+6-1llvm/lib/Target/AMDGPU/AMDGPURegBankLegalizeRules.cpp
+470-7942 files

LLVM/project 97a77eaflang/include/flang/Semantics expression.h, flang/lib/Semantics expression.cpp

[flang] Extract misparsed function reference check into function

Function calls and array element acceses have the same syntax, and some
array element accesses may be misparsed as calls. The ExprChecker will
identify and correct such cases in expressions, but they may also occur
outside of expressions (e.g. OpenMP directives and clauses).

To avoid code duplication extract the check into a new function
`IsMisparsedFunctionReference`.
DeltaFile
+38-32flang/lib/Semantics/expression.cpp
+3-0flang/include/flang/Semantics/expression.h
+41-322 files

LLVM/project 6d2f3ddcross-project-tests/debuginfo-tests/dexter/dex/debugger/DebuggerControllers ScriptDebuggerController.py, cross-project-tests/debuginfo-tests/dexter/dex/evaluation StateMatch.py RunMatch.py

[Dexter] Add condition check to state nodes

This patch enables the ability for state nodes to check conditions, meaning
they will be active only if the condition is met.

Condition evaluation is somewhat language specific; we directly check
whether the value of the evaluated expression is "true" (case-insensitive),
which works for the languages we actually use Dexter with, but may require
generalizing in future.

We also cache conditions as they are evaluated; each time we step, we clear
all cached conditions for the current frame and any expired frames, but we
keep the cached conditions for any frames rootwards from the current frame;
this prevents us from unexpectedly exiting out of a callee frame because of
debug info not surviving a stack unwind; if the early exit is desired, an
!and{at_frame_idx, condition} under the lower frame may suffice.
DeltaFile
+45-10cross-project-tests/debuginfo-tests/dexter/dex/evaluation/StateMatch.py
+53-0cross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/conditions.cpp
+9-1cross-project-tests/debuginfo-tests/dexter/dex/debugger/DebuggerControllers/ScriptDebuggerController.py
+6-1cross-project-tests/debuginfo-tests/dexter/dex/evaluation/RunMatch.py
+6-1cross-project-tests/debuginfo-tests/dexter/dex/evaluation/ExpectWriter.py
+1-1cross-project-tests/debuginfo-tests/dexter/dex/test_script/Nodes.py
+120-146 files

LLVM/project 294b362cross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/debugging watch_scope.cpp

format
DeltaFile
+2-1cross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/debugging/watch_scope.cpp
+2-11 files

LLVM/project f18c37ccross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/evaluation eval_address.cpp

format
DeltaFile
+5-3cross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/evaluation/eval_address.cpp
+5-31 files

LLVM/project e028624cross-project-tests/debuginfo-tests/dexter/dex/evaluation StateMatch.py

darker
DeltaFile
+2-0cross-project-tests/debuginfo-tests/dexter/dex/evaluation/StateMatch.py
+2-01 files

LLVM/project d93d089cross-project-tests/debuginfo-tests/dexter/dex/evaluation ExpectMatch.py RunMatch.py, cross-project-tests/debuginfo-tests/dexter/dex/test_script Nodes.py

[Dexter] Add !address node

Adds a node type for Dexter that allows checking abstract labels instead of
concrete addresses. Each address node has a label and optional offset, and
the first time during evaluation that a given address label is matched
against a valid pointer value, the address label will be assigned a value
that matches the seen address (adjusting for any offset). From that point,
the resolved address value will be used for the remainder of the test
evaluation.
DeltaFile
+100-29cross-project-tests/debuginfo-tests/dexter/dex/evaluation/ExpectMatch.py
+64-0cross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/evaluation/eval_address.cpp
+46-0cross-project-tests/debuginfo-tests/dexter/dex/test_script/Nodes.py
+26-0cross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/parser/invalid-address.test
+15-6cross-project-tests/debuginfo-tests/dexter/dex/evaluation/RunMatch.py
+15-0cross-project-tests/debuginfo-tests/dexter/feature_tests/scripts/parser/parse-address.test
+266-356 files