Skip to content

[X86] regenerate fcopysign test checks (#183710)#5

Closed
ampandey-1995 wants to merge 1 commit into
mainfrom
users/ampandey-1995/amdgpu-asan-interceptors
Closed

[X86] regenerate fcopysign test checks (#183710)#5
ampandey-1995 wants to merge 1 commit into
mainfrom
users/ampandey-1995/amdgpu-asan-interceptors

Conversation

@ampandey-1995
Copy link
Copy Markdown
Owner

[X86] regenerate fcopysign test checks (llvm#183710)

Fix vpternlog comments

[AMDGPU] Support i8/i16 GEP indices when promoting allocas to vectors (llvm#175489)

Allow promote alloca to vector to form a vector element index from
i8/i16
GEPs when the dynamic offset is known to be element size aligned.

Example:

%alloca = alloca <3 x float>, addrspace(5)
%idx = select i1 %idx_select, i32 0, i32 4
%p = getelementptr inbounds i8, ptr addrspace(5) %alloca, i32 %idx

Or:

%alloca = alloca <3 x float>, addrspace(5)
%idx = select i1 %idx_select, i32 0, i32 2
%p = getelementptr inbounds i16, ptr addrspace(5) %alloca, i32 %idx

[lldb][test] Re-enable TestDyldLaunchLinux.py for Linux/Arm (llvm#181221)

The test was disabled in c55e021, but it now passes, with both remote
and local runs.

[MemorySSA] Make getBlockDefs and getBlockAccesses return a non-const list (NFC)

As per discussion at llvm#181709 (comment),
users may already get a non-const MemoryAccess pointer via
getMemoryAccess for a given instruction. Drop the restriction
on directly iterate over them by modifying public getBlockDefs/
getBlockAccesses APIs to return a mutable list, thus dropping the
now obsolete distinction with getWritableBlockDefs and
getWritableBlockAccesses helpers.

[AMDGPU] Remove unused CmpLGOp instruction (llvm#180195)

The instruction was accidentally added, remove it.
Rename OrN2Op to OrN2Opc for consistency with other names

[SCEV] Always return true for isKnownToBeAPowerOfTwo for SCEVVScale (llvm#183693)

After llvm#183080 vscale is always a power of two, so we don't need to check
for the vscale_range attribute.

[mlir][affine] Fix crash in linearize_index fold when basis is ub.poison (llvm#183650)

foldCstValueToCstAttrBasis iterates the folded dynamic basis values
and erases any operand whose folded attribute is non-null (i.e., was
constant- folded). When an operand folds to ub.PoisonAttr, the
attribute is non-null so the operand was erased from the dynamic operand
list. However, getConstantIntValue on the corresponding OpFoldResult
in mixedBasis returns std::nullopt for poison (it is not an integer
constant), so the position was left as ShapedType::kDynamic in the
returned static basis.

This left the op in an inconsistent state: the static basis claimed one
more dynamic entry than actually existed. A subsequent call to
getMixedBasis() triggered the assertion inside getMixedValues.

Fix by skipping poison attributes in the erasure loop, treating them
like non-constant values. This keeps the dynamic operand and its
matching kDynamic entry in the static basis consistent.

Fixes llvm#179265

[VPlan] Remove non-power-of-2 scalable VF comment. NFC (llvm#183719)

No longer holds after llvm#183080

[mlir][dataflow] Fix crash in IntegerRangeAnalysis with non-constant loop bounds (llvm#183660)

When visiting non-control-flow arguments of a LoopLikeOpInterface op,
IntegerRangeAnalysis assumed that getLoopLowerBounds(),
getLoopUpperBounds(), and getLoopSteps() always return non-null values
when getLoopInductionVars() is non-null. This assumption is incorrect:
for example, AffineForOp returns nullopt from getLoopUpperBounds() when
the upper bound is not a constant affine expression (e.g., a dynamic
index from a tensor.dim).

Fix this by checking whether the bound optionals are engaged before
dereferencing them and falling back to the generic analysis if any bound
is unavailable.

Fixes llvm#180312

[flang] Use CHECK-DAG to check constants (NFC) (llvm#183687)

It is part of llvm#180556, as a
separate NFC PR

[LangRef] Clarify in vscale_range that vscale is a power-of-two without the attribute (llvm#183689)

Previously vscale_range used to add the constraint that vscale is a
power-of-two, but after llvm#183080 it's already a power-of-two to begin
with.

This clarifies the sentence about assumptions when there is no attribute

[Clang] support C23 constexpr struct member access in constant expressions (llvm#182770)

Fixes llvm#178349


This patch resolves an issue where accessing C23 constexpr struct
members using the dot operator was not recognized as a constant
expression.

According to C23 spec:

6.6p7:

An identifier that is:
— an enumeration constant,
— a predefined constant, or
— declared with storage-class specifier constexpr and has an object
type,
is a named constant, as is a postfix expression that applies the .
member access operator to a named
constant of structure or union type, even recursively. For enumeration
and predefined constants,
their value and type are defined in the respective clauses; for
constexpr objects, such a named
constant is a constant expression with the type and value of the
declared object.

§ 6.6p13:

A structure or union constant is a named constant or compound literal
constant with structure or
union type, respectively

§ 6.6p15:

Starting from a structure or union constant, the member-access .
operator may be used to form a
named constant or compound literal constant as described previously in
this subclause

[NFC][SPIRV] Remove dead code from SPIRVPostLegalizer.cpp (llvm#183585)

Both visit functions are unused in the file and outside of it.

[VPlan] Add nuw to unrolled canonical IVs (llvm#183716)

After llvm#183080, the canonical IV (not the increment!) can't overflow. So
now canonical IVs that are unrolled will have steps that don't overflow,
so we can add the nuw flag.

This allows us to tighten the VPlanVerifier isKnownMonotonic check by
restricting it to adds with nuw.

[LLVM][ExecutionEngine] Add vector ConstantInt/FP support to getConstantValue(). (llvm#182538)

Unify vector constant handling via calls to getAggregateElement rather
than handling each constant type separately.

[flang][OpenMP] Add is_range<R> trait to detect classes with begin/end, NFC (llvm#183615)

[analyzer] Fix crash in MallocChecker when a function has both ownership_returns and ownership_takes (llvm#183583)

When a function was annotated with both ownership_returns and
ownership_takes (or ownership_holds), MallocChecker::evalCall would
fall into the freeing-only branch (isFreeingOwnershipAttrCall) and call
checkOwnershipAttr without first calling MallocBindRetVal. That meant no
heap symbol had been conjured for the return value, so
checkOwnershipAttr later dereferenced a null/invalid symbol and crashed.

Fix: merge the two dispatch branches so that MallocBindRetVal is always
called first whenever ownership_returns is present, regardless of
whether the function also carries ownership_takes/ownership_holds.

The crash was introduced in llvm#106081
339282d.
Released in clang-20, and crashing ever since.

Fixes llvm#183344.

Assisted-By: claude

[X86] Fold XOR of two vgf2p8affineqb instructions with same input (llvm#179900)

This patch implements an optimization to fold XOR of two
vgf2p8affineqb instructions operating on the same input.
This optimization:
Reduces instruction count from 3 to 2
Eliminates one vgf2p8affineqb instruction
Added combineXorWithTwoGF2P8AFFINEQB function in X86ISelLowering.cpp
Uses sd_match pattern matching for consistency with existing code
Checks that both operations have single use to avoid code bloat
Verifies both operations use the same input
Handles commutative XOR patterns automatically

[gn] port 3490d28

[LLVM][Runtimes] Add 'llvm-gpu-loader' to dependency list (llvm#183601)

Summary:
This is used to run the unit tests in libc / libc++. It must exist in
the build directory's binary path, but without this dependnecy we may
not build it before running the runtimes build. This should ensure that
it's present, and only if we have tests enabled.

[AMDGPU][Scheduler] Add GCNRegPressure-based methods to GCNRPTarget (llvm#182853)

This adds a few methods to GCNRPTarget that can estimate/perform RP
savings based on GCNRegPressure instead of a single Register,
opening the door to model/incorporate more complex savings made up of
multiple registers of potentially different classes. The scheduler's
rematerialization stage now uses this new API.

Although there are no test changes this is not really NFC since register
pressure savings in the rematerialization stage are now computed through
GCNRegPressure instead of the stage itself. If anything this makes
them more consistent with the rest of the RP-tracking infrastructure.

[MIR] Error on signed integer in getUnsigned (llvm#183171)

Previously we effectively took the absolute value of the APSInt, instead
diagnose the unexpected negative value.

Change-Id: I4efe961e7b29fdf1d5f97df12f8139aac12c9219

[NFC][SPIRV] Fix compile warnings (llvm#183725)

Fix compile warnings in SPIR-V

llvm-project/llvm/lib/Target/SPIRV/SPIRVInstructionSelector.cpp:2882:26: warning: enumerated and non-enumerated type in conditional expression [-Wextra]
 2882 |         return IsFloatTy ? SPIRV::OpGroupNonUniformFMax : IntOp;
      |                ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
llvm-project/llvm/lib/Target/SPIRV/SPIRVInstructionSelector.cpp: In lambda function:
llvm-project/llvm/lib/Target/SPIRV/SPIRVInstructionSelector.cpp:2897:26: warning: enumerated and non-enumerated type in conditional expression [-Wextra]
 2897 |         return IsFloatTy ? SPIRV::OpGroupNonUniformFMin : IntOp;
      |                ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

[AMDGPU][Scheduler] Fix compilation fail in EXPENSIVE_CHECKS (llvm#183745)

Bug introduced by llvm#182853 (Remat is now a pointer).

[MLIR] Fix OpenACC parser crash with opaque pointers (llvm#183521)

Fixes llvm#181453
Fixes llvm#181589

[MLIR][Vector] Enhance shape_cast unrolling support in case the target shape is [1, 1, ..1] (llvm#183436)

This PR fixes a minor issue in shape_cast unrolling: when all target
dimensions are unit-sized, it no longer removes all leading unit
dimensions.

[SelectionDAG] Fix CLMULR/CLMULH expansion (llvm#183537)

For v8i8 on AArch64, expandCLMUL picked the zext path (ExtVT=v8i16) since ZERO_EXTEND/SRL were legal, but CLMUL on v8i16 is not, resulting in a bit-by-bit expansion (~42 insns). Prefer the bitreverse path when CLMUL is legal on VT but not ExtVT.

v8i8 CLMULR: 42 → 4 instructions.

Fixes llvm#182780

[mlir][Python] Drop Python <=3.9 compatibility path (llvm#183416)

According to PR llvm#163499, minimum Python version for mlir-py is now 3.10,
we no longer need patches for py<=3.9.

This change aligns with the Python version bump policy discussed
here.

[mlir][tensor] Fix crash in tensor.from_elements fold with non-scalar element types (llvm#183659)

The fold for tensor.from_elements attempted to always produce a
DenseElementsAttr by calling DenseElementsAttr::get(type, elements).
However, DenseElementsAttr::get only handles basic scalar element types
(integer, index, float, complex) directly. For other element types such
as vector types, it expects StringAttr (raw bytes) for each element,
which folded constants won't provide — triggering an assertion.

Fix this by guarding the fold: only attempt the DenseElementsAttr fold
when the tensor element type is integer, index, float, or complex.

Fixes llvm#180459

[mlir][transforms] Fix crash in remove-dead-values when function has non-call users (llvm#183655)

processFuncOp asserts that all symbol uses of a function are
CallOpInterface operations. This is violated when a function is
referenced by a non-call operation such as spirv.EntryPoint, which
uses the function symbol for metadata purposes without calling it.

Fix this by replacing the assertion with an early return: if any user of
the function symbol is not a CallOpInterface, skip the function
entirely. This is safe because the pass cannot determine the semantics
of arbitrary non-call references, so it should leave such functions
alone.

Fixes llvm#180416

[lldb][Process/FreeBSDKernelCore] Implement DoWriteMemory() (llvm#183553)

Implement ProcessFreeBSDKernelCore::DoWriteMemory() to write data on
kernel crash dump or /dev/mem. Due to safety reasons (e.g. writing
wrong value on /dev/mem can trigger kernel panic), this feature is
only enabled when plugin.process.freebsd-kernel-core.read-only is set
to false (true by default).

Since 85a1fe6 (llvm#183237) was reverted as it was prematurely merged, I'm
committing changes again with corrections here.


Signed-off-by: Minsoo Choo minsoochoo0122@proton.me

[SPIRV][NFCI] Use unordered data structures for SPIR-V extensions (llvm#183567)

Review follow-up from llvm#183325
No reason for these data structures to be ordered.

Minor annoyance when trying to use DenseMap because of the C++ code
for enums generated by TableGen, but not too bad.

Signed-off-by: Nick Sarnie nick.sarnie@intel.com

[clang][DebugInfo] Rename _vtable$ to __clang_vtable (llvm#183617)

Discussion is a follow-up from
llvm#182762 (comment)
(where we're discussing how LLDB could make use of this symbol for
vtable detection).

_vtable$ is not a reserved identifier in C or C++. In order for
debuggers to reliably use this symbol without accidentally reaching into
user-identifiers, this patch renames it such that it is reserved. The
naming follows the style of the recently added __clang_trap_msg
debug-info symbol.

[SLP][NFC] Precommit test for zext reorder with duplicate shifts (llvm#183748)

This is a pre-commit test for
llvm#183627,

[SystemZ] Add indirect reference bit XATTR REFERENCE(INDIRECT) for indirect symbol handling support (llvm#183441)

This is the first of three patches aimed to support indirect symbol
handling for the SystemZ backend. This PR introduces a GOFF:ERAttr to
represent indirect references, handles indirect symbols within
setSymbolAttribute() by setting the indirect reference bit, and also
updates the HLASM streamer to emit XATTR REFERENCE(INDIRECT) and
various other combinations.

[mlir][vector] Rename ReduceMultiDimReductionRank -> FlattenMultiReduction (NFC) (llvm#183721)

The updated name better captures what the pattern does and matches the
coresponding populat* hook,
populateVectorMultiReductionFlatteningPatterns, that only contains
this pattern.

[pdb] Fix libc++ strict-weak-ordering assertion failures from gsiRecordCmp (llvm#183749)

Builds using libc++ hardening was hitting asserts like

libc++ Hardening assertion
!__comp(*(__first + __a), *(__first + __b)) failed:
Your comparator is not a valid strict-weak ordering

printf-debugging revealed that symbols like "?ST@@3ja" were not
comparing equal with themselves. It turns out the comparison was done
with

return S1.compare_insensitive(S2.data());

and even when &S1 == &S2, S1 and S2.data() may not refer to identical
strings, since data() may not have a null terminator where the StringRef
locally ends.

This fixes the ordering, simplifies the code, and makes it a little
faster :)

Fixes: llvm#163755

[mlir] Enable specifying bytecode producer in mlir-opt. (llvm#182846)

[VPlan] Remove manual region removal when simplifying for VF and UF. (llvm#181252)

Replace manual region dissolution code in
simplifyBranchConditionForVFAndUF with using general
removeBranchOnConst. simplifyBranchConditionForVFAndUF now just creates
a (BranchOnCond true) or updates BranchOnTwoConds.

The loop then gets automatically removed by running removeBranchOnConst.

This removes a bunch of special logic to handle header phi replacements
and CFG updates. With the new code, there's no restriction on what kind
of header phi recipes the loop contains.

Note that VPEVLBasedIVRecipe needs to be marked as readnone. This is
technically unrelated, but I could not find an independent test that
would be impacted.

The code to deal with epilogue resume values now needs updating, because
we may simplify a reduction directly to the start value.

PR: llvm#181252

[ThinLTO] Reduce the number of renaming due to promotions (llvm#178587)

Currently for thin-lto, the imported static global values (functions,
variables, etc) will be promoted/renamed from e.g., foo() to
foo.llvm.(). Such a renaming caused difficulties in live patching
since function name is changed ([1]).

It is possible that some global value names have to be promoted to avoid
name collision and linker failure. But in practice, majority of name
promotions can be avoided.

In [2], the suggestion is that thin-lto pre-link decides whether
a particular global value needs name promotion or not. If yes, later on
in thinBackend() the name will be promoted.

I compiled a particular linux kernel version (latest bpf-next tree)
and found 1216 global values with suffix .llvm.. With this patch,
the number of promoted functions is 2, 98% reduction from the
original kernel build.

If some native objects are not participating with LTO, name promotions
have to be done to avoid potential linker issues. So the current
implementation cannot be on by default. But in certain cases, e.g., linux kernel
build, people can enable lld flag --lto-whole-program-visibility to reduce the
number of functions like foo.llvm.().

For ThinLTOCodeGenerator.cpp which is used by llvm-lto tool and a
few other rare cases, reducing the number of renaming due to promotion,
is not implemented as lld flag '-lto-whole-program-visibility' is not supported
in ThinLTOCodeGenerator.cpp for now. In summary, this pull request
only supports llvm-lto2 style workflow.

[1] https://lpc.events/event/19/contributions/2212
[2] https://discourse.llvm.org/t/rfc-avoid-functions-like-foo-llvm-for-kernel-live-patch/89400

Revert "[SPIRV][NFCI] Use unordered data structures for SPIR-V extensions" (llvm#183774)

Reverts llvm#183567

UBSan failure.

[lldb-dap] Improve test performance for 'cancel' request. (llvm#183632)

Update the test to more cleanly handle making a 'blocking' call using a
custom command instead of python time.sleep, which we cannot easily
interrupt.

This should improve the overall performance of the tests, locally they
took around 30s and now finish in around 6s.

[clang-scan-deps] Add test for symlink-aliased module map PCM reuse across incremental scans (llvm#183328)

Add a test that verifies symlink aliases to a module map directory
produce the same PCM across incremental scans.

[SPIR-V] Fix non-deterministic compiler output for debug type pointer (llvm#182773)

Fixes: llvm#123791

[clang][modules] Prevent deadlock in module cache (llvm#182722)

When there's a dependency cycle between modules, the dependency scanner
may encounter a deadlock. This was caused by not respecting the lock
timeout. But even with the timeout implemented, leaving
unsafeMaybeUnlock() unimplemented means trying to take a lock after a
timeout would still fail and prevent making progress. This PR implements
this API in a way to avoid UB on std::mutex (when it's unlocked by
someone else than the owner). Lastly, this PR makes sure that
unsafeUnlock() ends the wait of existing threads, so that they don't
need to hit the full timeout amount.

This PR also implements -fimplicit-modules-lock-timeout=<seconds> that
allows tweaking the default 90-second lock timeout, and adds #pragma clang __debug sleep that makes it easier to achieve desired execution
ordering.

rdar://170738600

[flang][NFC] Converted five tests from old lowering to new lowering (part 22) (llvm#183681)

Tests converted from test/Lower: intentout-deallocate.f90
Tests converted from test/Lower/Intrinsics: abs.f90, achar.f90,
acospi.f90, adjustl.f90

[libsycl] Add sycl::context stub (llvm#182826)

Part 1 of changes needed for USM alloc/dealloc impl.

This is part of the SYCL support upstreaming effort. The relevant RFCs
can be found here:

https://discourse.llvm.org/t/rfc-add-full-support-for-the-sycl-programming-model/74080
https://discourse.llvm.org/t/rfc-sycl-runtime-upstreaming/74479


Signed-off-by: Tikhomirova, Kseniya kseniya.tikhomirova@intel.com

[flang] Implement -grecord-command-line for Flang (llvm#181686)

Enable Flang to match Clang behavior for command-line recording in DWARF
producer strings when using -grecord-command-line.

Signed-off-by: Yangyu Chen cyy@cyyself.name

[ASan] Enable Internalization for 'asanrtl.bc' in Driver (llvm#182825)

Just like other bitcode libs such as ockl.bc ocml.bc, link asanrtl.bc
with '-mlink-builtin-bitcode' in the driver when GPU ASan is enabled.

[mlir][vector] Fix crashes in MaskOp::fold and CanonializeEmptyMaskOp (llvm#183781)

Two related crashes were fixed in vector.mask handling:

  1. MaskOp::fold() crashes with a null pointer dereference when the mask
    is all-true and the mask body has no maskable operation (only a
    vector.yield). getMaskableOp() returns nullptr in this case, and the
    fold was calling nullptr->dropAllUses(). Fixed by returning failure()
    when there is no maskable op, deferring to the canonicalizer.

  2. CanonializeEmptyMaskOp creates an invalid arith.select when the mask
    type is a vector (e.g., vector<1xi1>) but the result type is a scalar
    (e.g., i32). arith.select with a vector condition requires the value
    types to be vectors of the same shape. Fixed by bailing out when any
    result type doesn't match the mask shape.

Regression tests are added for both cases.

Fixes llvm#177833

[lldb] Add arithmetic binary addition to DIL (llvm#177208)

[RISCV] Use getCopyFromReg in unit test to match comment. NFC (llvm#183199)

Using physical register 0, aka NoRegister, also just looked suspicious.

Revert "[ThinLTO] Reduce the number of renaming due to promotions (llvm#178587)" (llvm#183782)

There is a conflict with existing code. See
llvm#178587
Revert and resolve the conflict and then will submit later.

[MTE] [HWASan] support more complicated lifetimes

This allows us to support more lifetimes, and also gets rid of
the quadratic call to isPotentiallyReachable.

Reviewers: pcc, usama54321

Reviewed By: pcc

Pull Request: llvm#182425

[bazel] Enable parse_headers for llvm/BUILD.bazel (llvm#183680)

Instead of excluding the whole package, push any existing parse_headers
failures to individual targets. In some cases we can avoid suppressing a
target by adding a few missing deps.

[SystemZ] Emit external aliases required for indirect symbol handling support (llvm#183442)

This is the second of three patches aimed to support indirect symbol
handling for the SystemZ backend. An external name is added for both MC
sections and symbols and makes the relevant printers and writers utilize
the external name when present. Furthermore, the ALIAS HLASM instruction
is emitted after every XATTR instruction.

Depends on llvm#183441.

[LoopInfo] Preserve profile information in makeLoopInvariant (llvm#174171)

When hoisting loop invariant instructions, we can preserve profile
metadata because it depends solely on the condition (which is loop
invariant) rather than where we are in the control flow graph.

[NFC][POWER] add Pre-Commit test case for Inefficient std::bit_floor(x) (llvm#183363)

add a pre-commit test case for Inefficient asm of std::bit_floor(x) for
powerpc.

[flang-rt] Enable more runtime functions for the GPU target (llvm#183649)

Summary:
This enables primarily stop.cpp and descriptor.cpp. Requires a
little bit of wrangling to get it to compile. Unlike the CUDA build,
this build uses an in-tree libc++ configured for the GPU. This is
configured without thread support, environment, or filesystem, and it is
not POSIX at all. So, no mutexes, pthreads, or get/setenv.

I tested stop, but i don't know if it's actually legal to exit from
OpenMP offloading.

Reapply "[ValueTracking] Propagate sign information out of loop" (llvm#182512)

LLVM converts sqrt libcall to intrinsic call if the argument is within
the range(greater than or equal to 0.0). In this case the compiler is
not able to deduce the non-negativity on its own. Extended ValueTracking
to understand such loops.

Have created new ABI's for matching Intrinsics with three operands
(those existed only for 2 operands)
matchSimpleTernaryIntrinsicRecurrence and matchThreeInputRecurrence.

Fixes llvm#174813

[flang] [flang-rt] Addition of the Fortran 2023 TOKENIZE intrinsic. (llvm#181030)

This implements the TOKENIZE intrinsic per the Fortran 2023 Standard.

TOKENIZE is a more complicated addition to the flang intrinsics, as it
is the first subroutine that has multiple unique footprints. Intrinsic
functions have already addressed this challenge, however subroutines and
functions are processed slightly differently and the function code was
not a good 1:1 solution for the subroutines. To solve this the function
code was used as an example to create error buffering within the
intrinsics Process and select the most appropriate error message for a
given subroutine footprint.

A simple FIR compile test was added to show the proper compilation of
each case. A thorough negative path test has also been added, ensuring
that all possible errors are reported as expected.

Testing prior to commit:

= check-flang ==========================================

Testing Time: 139.51s

Total Discovered Tests: 4153
  Unsupported      :   77 (1.85%)
  Passed           : 4065 (97.88%)
  Expectedly Failed:   11 (0.26%)


FLANG Container Test completed 2 minutes (160 s).

Total Time: 2 minutes (160 s)
Completed : Wed Feb 11 04:05:50 PM CST 2026

= check-flang-rt ==========================================

Testing Time: 1.55s

Total Discovered Tests: 258
  Passed: 258 (100.00%)


FLANG Container Test completed 0 minutes (55 s).

Total Time: 0 minutes (56 s)
Completed : Wed Feb 11 04:08:32 PM CST 2026

= llvm-test-suite ==========================================

Testing Time: 1886.64s

Total Discovered Tests: 6926
  Passed: 6926 (100.00%)


CCE SLES Container debug compile completed 31 minutes (1895 s).
CCE SLES Container debug install completed in 0 minutes (0 s).

Total Time: 31 minutes (1895 s)
Completed : Wed Feb 11 05:46:52 PM CST 2026

Additionally, (FYI) an executable test has been written and will be
added to the llvm-test-suite under a separate PR.


Co-authored-by: Kevin Wyatt kwyatt@hpe.com

[lldb-dap] Adjust VariableReferenceStorage lifetime management. (llvm#183176)

Adjusting VariableReferenceStorage to only need to track permanent vs
temporary storage by making VariableStore the common base class.

Moved the subclasses of VariableStore into the Variables.cpp file,
since they're no long referenced externally.

Expanding on the tests by adding an updated core dump with variables in
the argument scope we can use to validate variable storage.

[mlir][LLVM] Let decomposeValue/composeValue handle aggregates (llvm#183405)

This commit updates the LLVM::decomposeValue and LLVM::composeValue
methods to handle aggregate types - LLVM arrays and structs, and to have
different behaviors on dealing with types like pointers that can't be
bitcast to fixed-size integers. This allows the "any type" on
gpu.subgroup_broadcast to be more comprehensive - you can broadcast a
memref to a subgroup by decomposing it, for example.

(This branched off of getting an LLM to implement
ValueuboundsOpInterface on subgroup_broadcast, having it add handling
for the dimensions of shaped types, and realizing that there's no
fundamental reason you can't broadcast a memref or the like)


Co-authored-by: Claude Opus 4.6 noreply@anthropic.com

[WebAssembly] Incorporate SCCs into WebAssemblyFixIrreducibleControlFlow (llvm#181755)

Rather than mapping out full "reachability" between blocks in a region
to find loops and using LoopBlocks to find the bodies of said loops,
use SCCs (strongly-connected components) to provide this information.

This brings in LLVM's generic SCCIterator (which uses Tarjan's
algorithm) as the implementation for sorting the basic blocks of the CFG
into their SCCs.

This PR greatly reduces the compile-time footprint of the pass, making
memory use and time taken negliable where it might have previously
caused stalls and OOM before (e.g. llvm#47793,
usagi-coffee/tree-sitter-abl#114)


Supersedes llvm#179722

Fixes llvm#47793
Fixes llvm#165041 (probably)

Thanks to @jkbz64 for the initial investigations (w/ AI; see llvm#179722)
into why this pass was slow and memory consuming and showing that SCCs
were the key.

Also thanks to the Cheerp compiler project for bringing SCCIterator to
light in this context (blog
post
,
implementation).

[OpenMP] Enable internalization of 'ockl.bc' for OpenMP (llvm#183685)

Fix linking of 'ockl.bc' for OpenMP by switching from
-mlink-bitcode-file to -mlink-builtin-bitcode

[SlotIndexes] Further pack indices to improve spill placement time (llvm#182640)

This patch makes it so that renumbering indices when inserting
instructions into the SlotIndexes analysis renumbers the entire list if
the list is otherwise densely packed. This fixes a case we saw on
AArch64 with a lot of spills where every single spill instruction
insertion required a renumbering of most of the instructions in a large
function, making the operation approximately quadratic.

This is not NFC as heuristics depend on the SlotIndex numbers, although
this should mostly be a wash as LRs should be extended ~equally.

[clang][ssaf] Add JSONFormat support for TUSummaryEncoding

This PR adds JSONFormat support for reading and writing
TUSummaryEncoding. The implementation exploits similarities in the
structures of TUSummary and TUSummaryEncoding by reusing existing
JSONFormat support for TUSummary. Duplication of tests has been
avoided by parameterizing the test fixture that runs all relevant
read/write tests against TUSummary, for TUSummaryEncoding. This
ensures that the two serialization paths remain in lockstep.

[SLP] Reject duplicate shift amounts in matchesShlZExt reorder path (llvm#183627)

In the reordered RHS path of matchesShlZExt, the code never checked that
each shift amount (0, Stride, 2×Stride, …) appears at most once. When
the same shift appeared in multiple lanes, it still filled Order,
producing a non-permutation (e.g. Order = [0,0,0,1]). That led to bad
shuffle masks and miscompilation (e.g. shuffles with poison).

The patch adds an explicit duplicate check: before setting Order[Idx] =
Pos, it ensures Pos has not been seen before, using a SmallBitVector
SeenPositions(VF). If a position is seen twice, the function returns
false and the optimization is not applied.

[SystemZ] Emit external aliases for indirect function descriptors in the ADA section (llvm#183443)

This is the last of the three patches aimed to support indirect symbol
handling for the SystemZ backend.

An external alias is emitted for indirect function descriptors within
the ADA section, rather than a temporary alias, while also setting all
of the appropriate symbol attributes that are needed for the HLASM
streamer to emit the correct XATTR and ALIAS instructions for the
indirect symbols.

Moreover, this patch updates the
CodeGen/SystemZ/zos-ada-relocations.ll test as the ADA section is
currently the only user of indirect symbols on z/OS.

Depends on llvm#183442.

[InstCombine] Replace alloca with undef size with poison instead of null (llvm#182919)

InstCombine previously replaced an alloca instruction with a null
pointer when the array size operand was undef. While this replacement
may be legal, it still caused invalid IR in cases where the original
alloca was used by @llvm.lifetime intrinsics.

The spec requires that the pointer operand of @llvm.lifetime.* must be
either:

  • a pointer to an alloca instruction, or
  • a poison value.

Replacing the pointer with null violated this requirement and triggered
verifier errors.

These new changes update InstCombine so that in this scenario the alloca
is replaced with poison instead of null.

[Clang][ItaniumMangle] Fix recursive mangling for lambda init-captures (llvm#182667)

[Clang][ItaniumMangle] Fix recursive mangling for lambda init-captures

Mangle computation for lambda signatures can recurse when a call
operator type
references an init-capture (for example via decltype(init-capture)). In
these
cases, mangling can re-enter the init-capture declaration and cycle back
through
operator() mangling.

Make lambda context publication explicit and independent from numbering
state,
then use that context uniformly during mangling:

  • Publish lambda ContextDecl in Sema::handleLambdaNumbering() before
    numbering, so dependent type mangling can resolve the lambda context
    without
    recursing through the call operator.
  • Introduce CXXRecordDecl::setLambdaContextDecl() and remove
    ContextDecl
    from CXXRecordDecl::LambdaNumbering.
  • Update ASTImporter to import/set lambda context separately from
    numbering.
  • In Itanium mangling, derive init-capture handling from context
    computation:
    • map local-lambda init-captures to the enclosing local context in
      getEffectiveDeclContext()
    • support init-capture variables in getClosurePrefix()
    • keep mangleLocalName() generic and rely on the computed context

Add mangling regression coverage in mangle-lambdas.cpp, including:

[CIR] Implement TryOp flattening (llvm#183591)

This updates the FlattenCFG pass to add flattening for cir::TryOp in
cases where the TryOp contains catch or unwind handlers.

Substantial amounts of this PR were created using agentic AI tools, but
I have carefully reviewed the code, comments, and tests and made changes
as needed. I've left intermediate commits in the initial PR if you'd
like to see the progression.

[clang-format] Fix SpaceBeforeParens with explicit template instantiations (llvm#183183)

This fixes explicit template instantiated functions not having spaces
added/removed based on the value of SpaceBeforeParens.

Attribution Note - I have been authorized to contribute this change on
behalf of my company: ArenaNet LLC

[Driver][SYCL] Add tests for -Xarch_ option forwarding to SYCL JIT compilation. (llvm#178025)

This change adds test coverage to verify that options passed via
-Xarch_<arch> <option> are correctly forwarded to SYCL JIT
compilations.

[flang] Fix explanatory messages for generic resolution error (llvm#183565)

The compiler emits messages to explain why each of a generic procedure's
specific procedures is not a match for a given set of actual arguments.
In the case of specific procedures with PASS arguments in derived type
procedure bindings or procedure components, these explanatory messages
are often bogus, because the re-analysis didn't adjust the actual
arguments to account for the PASS argument. Fix.

[clang] stop error recovery in SFINAE for narrowing in converted constant expressions (llvm#183614)

A narrowing conversion in a converted constant expression should produce
an invalid expression so that [temp.deduct.general]p7 is satisfied, by
stopping substitution at this point.

This regression was introduced in llvm#164703, and this will be backported
to clang-22, so no release notes.

Fixes llvm#167709

[libc][math] Refactor bf16sub family to header-only (llvm#182115)

Refactors the bf16sub math family to be header-only.

Closes llvm#182114

Target Functions:

  • bf16sub
  • bf16subf
  • bf16subf128

[alpha.webkit.NoDeleteChecker] Check if each field is trivially destructive (llvm#183711)

This PR fixes the bug that NoDeleteChecker and trivial function analysis
were not detecting any non-trivial destruction of class member
variables.

When evaluating a delete expression or calling a destructor directly for
triviality, check if each field in the class and its base classes is
trivially destructive.

[AMDGPU] Handle GFX1250 hazards between WMMA and VOPD (llvm#183573)

Hazards between WMMA and VALU were handled in llvm#149865 but this only
worked for regular VOP* VALU encodings, not for VOPD.

Fixes: llvm#183546

[ASan] Document limitations of container overflow checks (llvm#183590)

Mention that partially poisoning stack objects can
lead to false positives and negatives.

See llvm#182720.


Co-authored-by: Saleem Abdulrasool compnerd@compnerd.org

Revert "[Metal][HLSL] Add support for dumping reflection" (llvm#183818)

Reverts llvm#181258

env PATH="" will prevent finding any binary run by env.

[clang] fix crash when casting a parenthesized unresolved template-id (llvm#183633)

this fix uses ignoreparens() in checkplaceholderexpr to prevent a crash
when an unresolved template-id is wrapped in parentheses. fixes llvm#183505

[clang][modulemap] Lazily load module maps by header name (llvm#181916)

After header search has found a header it looks for module maps that
cover that header. This patch uses the parsed representation of module
maps to do this search instead of relying on FileEntryRef lookups after
stating headers in module maps.

This behavior is currently gated behind the
-fmodules-lazy-load-module-maps -cc1 flag.

[mlir][cf] Fix crash in simplifyBrToBlockWithSinglePred when branch operand is a block argument of its successor (llvm#183797)

When simplifyBrToBlockWithSinglePred merges a block into its sole
predecessor, it calls inlineBlockBefore which replaces each block
argument with the corresponding value passed by the branch. If one of
those values is itself a block argument of the successor block, the call
replaceAllUsesWith(arg, arg) is a no-op. Any uses of that argument
outside the block (e.g. in a downstream block) are therefore not
replaced, and when the successor block is erased the argument is
destroyed while those uses are still live, triggering the assertion
use_empty() && "Cannot destroy a value that still has uses\!" in
IRObjectWithUseList::~IRObjectWithUseList.

Guard against this by returning early when any branch operand is a block
argument owned by the destination block.

Fixes llvm#126213

[BOLT][AArch64] Add a unittest for compare-and-branch inversion. (llvm#181177)

Checks that isReversibleBranch() returns false

  • when the immediate value is 63 and needs +1 adjustment
  • when the immediate value is 0 and needs -1 adjustment

Checks that reverseBranchCondition() adjusts

  • the opcode
  • the immediate operand if necessary (+/-1)
  • the register operands if necessary (swap)

[WebAseembly] Fix -Wunused-variable in llvm#181755

This variable ends up being unused in builds without assertions. Mark it
[[maybe_unused]] per the coding standards.

[NFC] [HWASan] add test for duplicated lifetime end

Reviewers:

Pull Request: llvm#183807

[NFC] [MTE] add test for duplicated lifetime end

Reviewers:

Pull Request: llvm#183808

Revert "[VPlan] Remove manual region removal when simplifying for VF and UF. (llvm#181252)"

This reverts commit 9c53215.

Appears to cause crashes with ordered reductions, revert while I
investigate

[mlir][LLVM] Let decomposeValue/composeVale pad out larger types (llvm#183825)

Currently, as pointed out in the reviews for llvm#183405, decomposeValues
and composeValues should be able to emit zexts and truncations for cases
like i48 and vector<3xi16> becoming i32s but currently that's an assert.
This commit fixes that limitation.

Co-authored-by: Claude Opus 4.6 noreply@anthropic.com

[Offload] Remove unused data type (llvm#183840)

[VPlan] Support unrolling/cloning masked VPInstructions.

Account for masked VPInstruction when verifying the operands in the
constructor. Fixes a crash when trying to unroll VPlans for predicated
early exits.

[mlir][arith] Add exact to index_cast{,ui} (llvm#183395)

The exact flag with the following semantics

If the exact attribute is present, it is assumed that the index type
width
is such that the conversion does not lose information. When this
assumption
is violated, the result is poison.

can be added to index_cast and index_castui operations. This unlocks
the following lowerings:

  • index_cast (signed) exact -> trunc nsw
  • index_castui (unsigned) exact -> trunc nuw
  • index_castui nneg exact -> trunc nuw nsw

Changes:

  • Adds ArithExactFlagInterface.
  • Updates Arith_IntBinaryOpWithExactFlag to use ArithExactFlagInterface
  • Update IndexCastOp and IndexCastUIOp to declare
    ArithExactFlagInterface
  • Update canonicalization patterns
  • Update roundtrip, lowering, and canonicalization tests.

[lldb] Add synthetic support to formatter_bytecode.py (llvm#183804)

Updates formatter_bytecode.py to support compilation and disassembly for
synthetic formatters, in other words support for multiple functions
(signatures).

This includes a number of other changes:

  • String parsing and encoding have bugs fixed
  • CLI args are updated, primarily to support an output file
  • Added uleb encoding/decoding support

This work is a prelude the ongoing work of a Python to formatter
bytecode compiler. The python compiler to emit assembly, and this module
(formatter_bytecode) will compile it into binary bytecode.

[lldb] Add skip shared build to more API tests

Fixing test failures on my local desktop with incremental
building.

[libc++] Forward find* algorithms to find_if (llvm#179938)

This propagates any optimizations to the whole family of find
functions.

Fix BuiltinTypeMethodBuilder uninitialized pointer (llvm#183814)

From this
comment

on PR llvm#176058, static analysis was flagging TemplateParams as not
initialized on all paths. This change fixes it by initializing to
nullptr at declaration.

[NFC] Fix use-after-free: track TargetLibraryAnalysis in BasicAAResult invalidation (llvm#183852)

BasicAAResult holds a reference to TargetLibraryInfo but its
invalidate() function did not check TargetLibraryAnalysis. When the
pass manager destroyed and re-created TLI (e.g. during CGSCC
invalidation or FAM.clear()), BasicAAResult survived with a dangling
TLI reference.

This was exposed by llvm#157495 which added aliasErrno(), the first code
path that dereferences TLI from BasicAAResult during the CGSCC
pipeline, causing a AV when compiling Rust's core library on Arm64
Windows.

This change adds TargetLibraryAnalysis to the invalidation check so
BasicAAResult is properly invalidated when its TLI reference becomes
stale.

[lldb] Change the way the shlib directory helper is set (llvm#183637)

This PR changes the way we set the shlib directory helper. Instead of
setting it while initializing the Host plugin, we register it when
initializing the Python plugin. The motivation is that the current
approach is incompatible with the dynamically linked script
interpreters, as they will not have been loaded at the time the Host
plugin is initialized.

The downside of the new approach is that we set the helper after having
initialized the Host plugin, which theoretically introduces a small
window where someone could query the helper before it has been set.
Fortunately the window is pretty small and limited to when we're
initializing plugins, but it's less "pure" than what we had previously.
That said, I think it balances out with removing the plugin include.

[cmake] Disable -Wdangling-pointer on GCC 12+ (llvm#183593)

GCC 12 started warning on the RAII DAGUpdateListener pattern in
SelectionDAG.h (storing this in the constructor). It's a false
positive -- suppress it the same way we handle -Wno-dangling-reference
(GCC 13+) and -Wno-stringop-overread (GCC 11+).

[CIR] Fix dominance problems with values defined in cleanup scopes (llvm#183810)

We currently encounter dominance verification errors when a value is
defined inside a cleanup scope but used outside the scope. This occurs
when forceCleanup() is used to exit a cleanup scope while a variable is
holding a value that was created in the scope body. Classic codegen
solved this problem by passing a list of values to spill and reload to
forceCleanup(). This change implements that same solution for CIR.

I have also aligned the ScalarExprEmitter::VisitExprWithCleanups
implementation with that of classic codegen, eliminating an extra
lexical scope. This causes temporary allocas to be created at the next
higher existing lexical scope, but I think that's OK since they would be
hoisted there anyway by a later pass.

[mlir][GPU] Add ValueBoundsOphinterface to gpu.subgroup_broadcast (llvm#183848)

This commit adds an ValueBoundsOpInterface to gpu.subgroup_broadcast,
matching its integer range interface implementation, so that affine
analysis can peek through subgroup broadcast ops.

[Hexagon] Define HVX_IEEE_FP when -mhvx-ieee-fp is enabled (llvm#183829)

Add a HVX_IEEE_FP define when the compiler is invoked with
-mhvx-ieee-fp flag

[CMake] Propagate dependencies to OBJECT libraries in add_llvm_library (llvm#183541)

Previously, transitively inherited calls to
target_include_directories(foo SYSTEM ...) were being squashed into a
flat list of includes, effectively stripping off -isystem and
unintentionally forwarding warnings from such dependencies.

To correctly propagate SYSTEM dependencies, use
target_link_libraries to forward the parent target's link dependencies
to the OBJECT library (similar to the _static flow below). Unlike a
flat target_include_directories, this lets CMake resolve transitive
SYSTEM include directories through the proper dependency chain.

Note that target_link_libraries on an OBJECT library propagates all
usage requirements, not just includes. This also brings in transitive
INTERFACE_COMPILE_DEFINITIONS, INTERFACE_COMPILE_OPTIONS, and
INTERFACE_COMPILE_FEATURES. This is arguably more correct, as the
OBJECT library compiles the same sources and should see the same flags.

The existing target_include_directories call is retained for include
directories set directly on the target (not through link dependencies).
CMake deduplicates include directories that appear through both paths.
Compile definitions and options may technically appear twice (once via
the OBJECT library, once via the consuming target), but duplicate -D
and flag entries should be harmless in practice.

Also fix clang_target_link_libraries and mlir_target_link_libraries
to forward the link type (PUBLIC/PRIVATE/INTERFACE) to obj.* targets.
Previously the type keyword was silently dropped, resulting in
plain-signature target_link_libraries calls. This is now required
because the new keyword-signature call in llvm_add_library would
otherwise conflict (CMake requires all calls on a target to use the same
signature).

[lldb] Fix sys.path manipulation failure in formatter_bytecode.py (llvm#183868)

Fix bug in llvm#183804.

[SLP]Fix operand reordering when estimating profitability of operands

Need to swap operand for a single instruction, not for the the same lane
of the first and second instruction in the list

[CIR][NFC] Move some builtin tests to the CodeGenBuitins folder (llvm#183607)

This moves a few tests that were created in the wrong location. Also
changes the names of some test files to maintain consistency.

[AMDGPU][SIInsertWaitcnts] Move VCCZ workaround code out of the way (llvm#182619)

This is a cleanup patch that moves the VCCZ specific workaround code
from SIInsertWaitcnts::insertWaitcntInBlock() to a separate class and
refactors it a bit to make it easier to read.
The end result is a simpler insertWaitcntInBlock().

Should be NFC.

Revert "[WebAssembly] Incorporate SCCs into WebAssemblyFixIrreducibleControlFlow (llvm#181755)" (llvm#183872)

This reverts commit c05e323.

Changes failed Emscripten tests.

[AMDGPU] Remove extra pipes from load-saddr-offset-imm.ll (llvm#183874)

This test uses opt to run instcombin and then pipes that into llc which
has its output piped into FileCheck. Before this patch, the test also
piped in the source file into llc as well, which caused issues with a
downstream test executor that executes the lines in bash. However, these
extra pipes don't make sense anyways, so remove them.

[libc][math] Refactor floor family to header-only (llvm#182194)

Refactors the floor math family to be header-only.

Closes llvm#182193

Target Functions:

  • floor
  • floorbf16
  • floorf
  • floorf128
  • floorf16
  • floorl

[libc][math][c23] implement C23 acospif math function (llvm#183661)

Implementing C23 acospi math function for single-precision with the
header-only approach that is followed since llvm#147386

Clang: Deprecate float support from __builtin_elementwise_max (llvm#180885)

Now we have
__builtin_elementwise_maxnum
__builtin_elementwise_maximum
__builtin_elementwise_maximumnum

[VPlan] Don't adjust trip count for DataAndControlFlowWithoutRuntimeCheck (llvm#183729)

Previously, the canonical IV increment may have overflowed to a non-zero
value due to vscale being a non power-of-two. So we used to emit a
runtime check for this.

If you didn't want the runtime check,
DataAndControlFlowWithoutRuntimeCheck skipped it and instead tweaked the
trip count so it wouldn't overflow.

However llvm#144963 stopped the check from ever being emitted because vscale
is always a power-of-two on AArch64 and RISC-V, so it never overflowed
to a non-zero value. And in llvm#183292 the code to emit the check was
removed. But we never restored the trip count back to normal when the
target's vscale was a power-of-two.

Now that vscale is always a power-of-two, this PR avoids adjusting it. A
follow up NFC can then remove DataAndControlFlowWithoutRuntimeCheck.

[CIR] Infrastructure and MemorySpaceAttrInterface for Address Spaces (llvm#179073)

Related: llvm#175871,
llvm#179278,
llvm#160386

  • Introducing the LangAddressSpace enum with offload address space kinds
    (offload_private, offload_local, offload_global, offload_constant,
    offload_generic) and the LangAddressSpaceAttr attribute.

  • Generalizes CIR AS attributes as MemorySpaceAttrInterface and Attaches
    it to PointerType. Includes test coverage for valid IR roundtrips and
    invalid address space parsing.

This starts a series of patches with the purpose of bringing complete
address spaces support features for CIR. Most of the test coverage is
provided in subsequent patches further down the stack. note that most of
these patches are based on: llvm/clangir#1986

[CIR] Use -verify on clang/test/CIR/CodeGenHLSL/matrix-element-expr-load.hlsl (llvm#182817)

Update clang/test/CIR/CodeGenHLSL/matrix-element-expr-load.hlsl to use
-verify with expected CIR NYI diagnostics.

[CodeGen] Allow -enable-ext-tsp-block-placement and -apply-ext-tsp-for-size passed together (llvm#183642)

Currently, the asserts fires when both UseExtTspForPerf and
UseExtTspForSize are true on a given function.

Ideally, we should allow -enable-ext-tsp-block-placement and
-apply-ext-tsp-for-size passed together, meaning run the block
placement for performance on hot functions, while run the placement for
size on cold functions.

The diff makes UseExtTspForPerf and UseExtTspForSize mutually
exclusive per-function: functions with the OptForSize attribute use
ext-tsp block placement for size, while the others use ext-tsp block
placement for perf.

Co-authored-by: Sharon Xu sharonxu@fb.com

[clang-tidy] Teach misc-unused-using-decls that exported using-decls aren't unused (llvm#183638)

Fixes llvm#162619.

AArch64: Replace @plt/%gotpcrel in data directives with %pltpcrel %gotpcrel (llvm#155776)

Similar to llvm#132569 for RISC-V, replace the unofficial @plt and
@gotpcrel relocation specifiers, currently only used by clang
-fexperimental-relative-c++-abi-vtables, with %pltpcrel %gotpcrel. The
syntax is not used in humand-written assembly code, and is not supported
by GNU assembler.

Also replace the recent @funcinit with %funcinit(x).

[AMDGPU] Fix piggybacking after commute in AMDGPULowerVGPREncoding (llvm#183778)

After successfully commuting an instruction to be compatible with the
current VGPR MSB mode, update CurrentMode with the commuted
instruction's mode requirements. This locks in the mode bits the
commuted instruction relies on, preventing later instructions from
piggybacking and corrupting those bits.

Without this fix, a subsequent instruction needing a different mode
could piggyback onto the preceding s_set_vgpr_msb and change mode bits
that the commuted instruction depends on. For example, a nullopt src1
position (treated as 0) could be overwritten to a different value,
causing incorrect register encoding for the commuted instruction.

The fix still allows compatible piggybacking - instructions that only
add new mode bits without changing existing ones can still piggyback.

[Driver] Add -Wa,--reloc-section-sym= to control section symbol conversion (llvm#183472)

Wire the llvm-mc --reloc-section-sym={all,internal,none} option through
the clang driver (-Wa,--reloc-section-sym=) and cc1as
(--reloc-section-sym=). The option is only valid for ELF targets.

GNU Assembler will add the option as well.

[lldb/test] Skip TestDelayInitDependency on remote platforms (llvm#183885)

This test exercises macOS-specific linker functionality (-delay_library)
and uses a hardcoded local working directory for the launch info. It
should not run against a remote platform where neither condition holds.

Signed-off-by: Med Ismail Bennani ismail@bennani.ma

InstCombine: Stop applying nofpclass from use nofpclass attribute (llvm#183835)

Functionally reverts a80d432, with new
test.
This should be applied somewhere, but this is the wrong place.

Fixes regression reported after llvm#182444

RISCVMCAsmInfo: Remove redundant UseAtForSpecifier = false. NFC (llvm#183890)

UseAtForSpecifier defaults to false in MCAsmInfo, and RISCVMCAsmInfo
never calls initializeAtSpecifiers (which sets it to true).

[LV] Add tail-folding & required scalar epilogue tests for IG narrowing.

Add additional tests to cover missing code paths when narrowing
interleave groups:

  • tail-folding
  • interleave-groups that require a scalar iteration.

[llvm][DebugInfo] Bump DWARFContext maximum DWARF version (llvm#183838)

In order to start testing DWARFv6 feature support we need to bump this
version for tooling to work.

This does not mean we officially support DWARFv6. It just enables us
testing the features gradually.

[llvm][DebugInfo] Bump DWARFDebugLine maximum DWARF version (llvm#183841)

Bumps .debug_line maximum supported version to DWARFv6.

This does not mean we officially support DWARFv6. It just enables us
testing the features gradually.

[llvm][DebugInfo] Bump DWARFListTable maximum DWARF version (llvm#183859)

Bumps .debug_rnglists maximum supported version to DWARFv6.

This does not mean we officially support DWARFv6. It just enables us
testing the features gradually.

Added unit-test since there was no prior test in the entire LLVM
test-suite that checked this.

[ARM][MVE] Add SLI and SRI recognition. (llvm#183471)

This uses the newly added code from llvm#182051 to optimize to MVE sli and
sri. The only major difference is the legal types supported, but we also
lower intrinsics via VSLIIMM/VSLIIMM, so that only one tablegen pattern
is needed.

[CMake][LLVM] Disable PCH on Clang for file with custom flags too (llvm#183813)

Precompiled headers are already skipped when building ConstantFolding.cpp with MSVC, they cause problems with Clang too so disable it there the same way.

[llvm-mc][dwarf] Bump supported version to DWARF 6 (llvm#183779)

Depends on:

Bumps the supported version to 6. Unit header layout hasn't changed
between versions AFAIK, so re-used the DWARF5 FileCheck in the test.
This by no means claims full DWARFv6 support, but is handy for testing
DWARFv6 features while full support is being gradually implemented.

[mlir][tensor] Fix crash in expand_shape fold with dynamic result type (llvm#183785)

foldReshapeOp (in ReshapeOpsUtils.h) and FoldReshapeWithConstant
(in TensorOps.cpp) both tried to create a new DenseElementsAttr
constant when folding a reshape op whose operand is a constant. Neither
checked that the result type was statically shaped before doing so, but
DenseElementsAttr::reshape() and
DenseElementsAttr::getFromRawBuffer() both assert hasStaticShape().

Guard both fold paths with a hasStaticShape() check so they return
early when the result type contains a dynamic dimension.

Fixes llvm#177845

[mlir][test-ir-visitors] Fix noSkipBlockErasure crash with block args used across blocks (llvm#183828)

The noSkipBlockErasure callback in TestVisitors.cpp dropped uses of op
results within the same region before erasing a block, but did not drop
uses of the block's own arguments (e.g. function entry block arguments).
When the block was subsequently erased its block arguments were
destroyed while their use-lists were still non-empty, triggering the
assertion in IRObjectWithUseList::~IRObjectWithUseList().

Fix this by also iterating over the block's arguments and dropping any
uses that belong to the same parent region. This mirrors the existing
logic for op result uses and makes the block-erasure walk handle IRs
where function arguments are consumed by ops in sibling blocks.

Also replace block->front().getParentRegion() with
block->getParent() for robustness (avoids UB when the block has no
ops).

Add a regression test based on the reproducer from
llvm#182996.

Fixes llvm#182996

Restore llvm#125407, Make covmap tolerant of nested Decisions (llvm#183073)

Change(s):

  • Suppress range errors in CounterExpr

[mlir] Fix crash in testNoSkipErasureCallbacks on empty blocks (llvm#183757)

The noSkipBlockErasure callback in testNoSkipErasureCallbacks called
block->front().getParentRegion() to get the parent region of a block.
This dereferences the ilist sentinel node when the block has no
operations, triggering an assertion failure.

Use block->getParent() instead, which directly returns the region
containing the block without requiring any operations to be present.

Fixes llvm#183511

[mlir][affine] Fix crash in linearize_index fold when multi-index is ub.poison (llvm#183816)

AffineLinearizeIndexOp::fold guarded the constant-folding path with
llvm::is_contained(adaptor.getMultiIndex(), nullptr), which only
catches operands that have not been evaluated at all. When an operand
folds to ub.PoisonAttr, the attribute is non-null so the guard passed,
and the subsequent cast<IntegerAttr>(indexAttr) call crashed with an
assertion failure.

Fix by replacing the null-only check with one that requires every
multi-index attribute to be a concrete IntegerAttr, returning
nullptr for any other attribute (including null and PoisonAttr).

Fixes llvm#178204

[AArch64][PAC] Emit !dbg locations in *_vfpthunk_ functions (llvm#179688)

The usage of pointers to member functions with Pointer Authentication
requires generation of *_vfpthunk_ functions. These thunk functions
can be later inlined and optimized by replacing the indirect call
instruction with a direct one and then inlining that function call.

In absence of !dbg metadata attached to the original call instruction,
such inlining ultimately results in an assertion "!dbg attachment points
at wrong subprogram for function" in the assertions-enabled builds. By
manually executing opt with -verify-each option on the LLVM IR
produced by the frontend, an actual issue can be observed: "inlinable
function call in a function with debug info must have a !dbg location"
after the replacement of indirect call instruction with the direct one
takes place.

This commit fixes the issue by attaching artificial !dbg locations to
the original call instruction (as well as most other instructions in
*_vfpthunk_ function) the same way it is done for other
compiler-generated helper functions.

[AArch64] Add fcvt-i256 test cases. NFC

[LV] Remove duplicated IV expression sinking tests. (NFC)

Remove duplicated tests already covered by
llvm/test/Transforms/LoopVectorize/find-last-iv-sinkable-expr.ll.

[VPlan] Materialize UF after unrolling (NFCI).

Move materialization of the symbolic UF directly to unrollByUF. At this
point, unrolling materializes the decision and it is natural to also
materialize the symbolic UF here.

[mlir][IR] Generalize DenseElementsAttr to custom element types (llvm#183891)

DenseElementsAttr supports only a hard-coded list of element types:
int, index, float, complex. This commit generalizes the
DenseElementsAttr infrastructure: it now supports arbitrary element
types, as long as they implement the new DenseElementTypeInterface.

The DenseElementTypeInterface has the following helper functions:

  • getDenseElementBitSize: Query the size of an element in bits. (When
    storing an element in memory, each element is padded to a full byte.
    This is an existing limitation of the DenseElementsAttr; with an
    exception for i1.)
  • convertToAttribute: Attribute factory / deserializer. Converts bytes
    into an MLIR attribute. The attribute provides the assembly format /
    printer for a single element.
  • convertFromAttribute: Serializer. Converts an MLIR attribute into
    bytes.

Note: convertToAttribute / convertFromAttribute are mainly for
writing test cases. For performance reasons, DenseElementsAttr users
should work with raw bytes / elements and avoid any API that
materializes MLIR attributes. However, MLIR attributes typically have
human-readable parsers/printers, making them suitable for lit tests and
debugging.

This PR introduces an additional assembly format for
DenseElementsAttrs. There are now two formats. (The existing one is
kept for compatibility reasons.)

  • Literal-first (existing): dense<[1, 2, 3]> : tensor<3xi32>
  • Type-first (new): dense<tensor<3xi32> : [1 : i32, 2 : i32, 3 : i32]>

The new syntax is needed to disambiguate between "literal" (e.g., 1)
and attribute (e.g., 1 : i32) when parsing the first token. In the
literal-first syntax, we only parse literals. In the type-first syntax,
we only parse attributes.

The existing int, index, float, complex types also implement the
DenseElementTypeInterface. This allows us to implement
DenseElementsAttr::get and AttributeElementIterator::operator* in a
generic way.

RFC:

https://discourse.llvm.org/t/rfc-allow-custom-element-types-in-denseelementattr/89656

This is a re-upload of llvm#179122.

Precommit tests: strictfp rounding vector f16 intrinsics (llvm#183699)

[mlir][VectorToLLVM] Fix crash in VectorInsertOpConversion with dynamic index (llvm#183783)

VectorInsertOpConversion crashes with an assertion failure when
inserting a sub-vector at a dynamic position into a multi-dimensional
vector. The pattern calls getAsIntegers() on the position, which asserts
that all fold results are compile-time constant attributes.

The existing guard (checking llvm::IsaPred) only covered the
case where a scalar is inserted into the innermost dimension (the
extractvalue path). The guard was missing for the insertvalue path when
inserting a sub-vector at a dynamic position into a nested aggregate.

Fix: add the same guard before the llvm.insertvalue creation to return
failure() gracefully when any position index is dynamic, matching the
behavior of VectorExtractOpConversion.

Fixes llvm#177829

[CMake] Use keyword signature in two additional callsites (llvm#183889)

Fix-forward for llvm#183541.
Two callsites to target_link_libraries were not migrated to the
keyword signature.

Signed-off-by: Itay Bookstein itay.bookstein@nextsilicon.com

Revert "[mlir][IR] Generalize DenseElementsAttr to custom element types" (llvm#183917)

Reverts llvm#183891

Reverting a second time. The build bot failure seems to be
non-deterministic.

[X86] known-pow2.ll - add tests showing failure to handle ISD::EXTRACT_VECTOR_ELT nodes (llvm#183918)

[AMDGPU] Enable shift64 hazard recognition for gfx9 (llvm#183839)

Enable shift64 hazard recognition for gfx9 cores.


Signed-off-by: John Lu John.Lu@amd.com

[CIR] Implement ImplicitValueInitExpr for ComplexType (llvm#183836)

Implement ImplicitValueInitExpr for ComplexType

[AMDGPU] Assert non-array alloca does have a size (llvm#183834)

Refs
https://github.com/llvm/llvm-project/pull/179523/changes#r2851952141

[ARM] Lower strictfp vector fp16 rounding operations similar to default mode (llvm#183700)

Previously the strictfp rounding nodes were lowered using unrolling to
scalar operations, which has negative impact on performance. Partially
this issue was fixed in llvm#180480, this change continues that work and
implements optimized lowering for v4f16 and v8f16.

[lldb][Process/FreeBSDKernelCore] Add ppc64le support (llvm#180669)

This is LLDB versio

Add initial AddressSanitizer support for AMDGPU by intercepting HSA APIs
used for host-side initialization and CPU↔GPU memory operations
(allocation, copies, IPC, vmem, and other related queries).

This support is guarded by `SANITIZER_AMDGPU`, which enables inclusion of
the ROCm HSA and COMgr headers required to build the interceptors.
@ampandey-1995
Copy link
Copy Markdown
Owner Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@ampandey-1995 ampandey-1995 deleted the users/ampandey-1995/amdgpu-asan-interceptors branch April 15, 2026 11:26
ampandey-1995 pushed a commit that referenced this pull request Apr 22, 2026
…bols add' (llvm#188377)

Context: 
lldb might crash when running to a debuggee crashing state and do a
target symbols add command.
Backtrace: 
```
 #0 0x000055ca6790dc65 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) /home/hyubo/osmeta/external/llvm-project/llvm/lib/Support/Unix/Signals.inc:848:11
 #1 0x000055ca6790e434 PrintStackTraceSignalHandler(void*) /home/hyubo/osmeta/external/llvm-project/llvm/lib/Support/Unix/Signals.inc:931:1
 #2 0x000055ca6790b839 llvm::sys::RunSignalHandlers() /home/hyubo/osmeta/external/llvm-project/llvm/lib/Support/Signals.cpp:104:5
 #3 0x000055ca6790ff6b SignalHandler(int, siginfo_t*, void*) /home/hyubo/osmeta/external/llvm-project/llvm/lib/Support/Unix/Signals.inc:430:38
 #4 0x00007fe9e5e44560 __restore_rt /home/engshare/third-party2/glibc/2.34/src/glibc-2.34/signal/../sysdeps/unix/sysv/linux/libc_sigaction.c:13:0
 #5 0x00007fe9e5f25649 syscall /home/engshare/third-party2/glibc/2.34/src/glibc-2.34/misc/../sysdeps/unix/sysv/linux/x86_64/syscall.S:38:0
 #6 0x00007fe9ec649170 SignalHandler(int, siginfo_t*, void*) /home/hyubo/osmeta/external/llvm-project/llvm/lib/Support/Unix/Signals.inc:429:7
 #7 0x00007fe9e5e44560 __restore_rt /home/engshare/third-party2/glibc/2.34/src/glibc-2.34/signal/../sysdeps/unix/sysv/linux/libc_sigaction.c:13:0
 #8 0x00007fe9ebb77bf0 lldb_private::operator<(lldb_private::StackID const&, lldb_private::StackID const&) /home/hyubo/osmeta/external/llvm-project/lldb/source/Target/StackID.cpp:99:16
 llvm#9 0x00007fe9ebb6863d CompareStackID(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&) /home/hyubo/osmeta/external/llvm-project/lldb/source/Target/StackFrameList.cpp:683:3
llvm#10 0x00007fe9ebb6d049 bool __gnu_cxx::__ops::_Iter_comp_val<bool (*)(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&)>::operator()<__gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, lldb_private::StackID const>(__gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, lldb_private::StackID const&) /mnt/gvfs/third-party2/libgcc/d1129753c8361ac8e9453c0f4291337a4507ebe6/11.x/platform010/5684a5a/include/c++/11.x/bits/predefined_ops.h:196:4
llvm#11 0x00007fe9ebb6cefe __gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>> std::__lower_bound<__gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, lldb_private::StackID, __gnu_cxx::__ops::_Iter_comp_val<bool (*)(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&)>>(__gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, __gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, lldb_private::StackID const&, __gnu_cxx::__ops::_Iter_comp_val<bool (*)(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&)>) /mnt/gvfs/third-party2/libgcc/d1129753c8361ac8e9453c0f4291337a4507ebe6/11.x/platform010/5684a5a/include/c++/11.x/bits/stl_algobase.h:1464:8
llvm#12 0x00007fe9ebb6cdfc __gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>> std::lower_bound<__gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, lldb_private::StackID, bool (*)(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&)>(__gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, __gnu_cxx::__normal_iterator<std::shared_ptr<lldb_private::StackFrame>*, std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>>, lldb_private::StackID const&, bool (*)(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&)) /mnt/gvfs/third-party2/libgcc/d1129753c8361ac8e9453c0f4291337a4507ebe6/11.x/platform010/5684a5a/include/c++/11.x/bits/stl_algo.h:2062:14
llvm#13 0x00007fe9ebb685fa auto llvm::lower_bound<std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>&, lldb_private::StackID const&, bool (*)(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&)>(std::vector<std::shared_ptr<lldb_private::StackFrame>, std::allocator<std::shared_ptr<lldb_private::StackFrame>>>&, lldb_private::StackID const&, bool (*)(std::shared_ptr<lldb_private::StackFrame> const&, lldb_private::StackID const&)) /home/hyubo/osmeta/external/llvm-project/llvm/include/llvm/ADT/STLExtras.h:2001:10
llvm#14 0x00007fe9ebb68441 lldb_private::StackFrameList::GetFrameWithStackID(lldb_private::StackID const&) /home/hyubo/osmeta/external/llvm-project/lldb/source/Target/StackFrameList.cpp:697:11
llvm#15 0x00007fe9ebbee395 lldb_private::Thread::GetFrameWithStackID(lldb_private::StackID const&) /home/hyubo/osmeta/external/llvm-project/lldb/include/lldb/Target/Thread.h:459:7
llvm#16 0x00007fe9ebac7cf7 lldb_private::ExecutionContextRef::GetFrameSP() const /home/hyubo/osmeta/external/llvm-project/lldb/source/Target/ExecutionContext.cpp:643:25
llvm#17 0x00007fe9ebac80e1 lldb_private::GetStoppedExecutionContext(lldb_private::ExecutionContextRef const*) /home/hyubo/osmeta/external/llvm-project/lldb/source/Target/ExecutionContext.cpp:164:34
llvm#18 0x00007fe9eb8903fa lldb_private::Statusline::Redraw(std::optional<lldb_private::ExecutionContextRef>) /home/hyubo/osmeta/external/llvm-project/lldb/source/Core/Statusline.cpp:139:7
llvm#19 0x00007fe9eb7ac8be lldb_private::Debugger::RedrawStatusline(std::optional<lldb_private::ExecutionContextRef>) /home/hyubo/osmeta/external/llvm-project/lldb/source/Core/Debugger.cpp:1233:3
llvm#20 0x00007fe9eb804d1e lldb_private::IOHandlerEditline::RedrawCallback() /home/hyubo/osmeta/external/llvm-project/lldb/source/Core/IOHandler.cpp:446:3
llvm#21 0x00007fe9eb80aa81 lldb_private::IOHandlerEditline::IOHandlerEditline(lldb_private::Debugger&, lldb_private::IOHandler::Type, std::shared_ptr<lldb_private::File> const&, std::shared_ptr<lldb_private::LockableStreamFile> const&, std::shared_ptr<lldb_private::LockableStreamFile> const&, unsigned int, char const*, llvm::StringRef, llvm::StringRef, bool, bool, unsigned int, lldb_private::IOHandlerDelegate&)::$_2::operator()() const /home/hyubo/osmeta/external/llvm-project/lldb/source/Core/IOHandler.cpp:262:73
llvm#22 0x00007fe9eb80aa5d void llvm::detail::UniqueFunctionBase<void>::CallImpl<lldb_private::IOHandlerEditline::IOHandlerEditline(lldb_private::Debugger&, lldb_private::IOHandler::Type, std::shared_ptr<lldb_private::File> const&, std::shared_ptr<lldb_private::LockableStreamFile> const&, std::shared_ptr<lldb_private::LockableStreamFile> const&, unsigned int, char const*, llvm::StringRef, llvm::StringRef, bool, bool, unsigned int, lldb_private::IOHandlerDelegate&)::$_2>(void*) /home/hyubo/osmeta/external/llvm-project/llvm/include/llvm/ADT/FunctionExtras.h:213:5
llvm#23 0x00007fe9eb93bfbf llvm::unique_function<void ()>::operator()() /home/hyubo/osmeta/external/llvm-project/llvm/include/llvm/ADT/FunctionExtras.h:365:5
llvm#24 0x00007fe9eb93bb80 lldb_private::Editline::GetCharacter(wchar_t*) /home/hyubo/osmeta/external/llvm-project/lldb/source/Host/common/Editline.cpp:0:5
llvm#25 0x00007fe9eb941a18 lldb_private::Editline::ConfigureEditor(bool)::$_0::operator()(editline*, wchar_t*) const /home/hyubo/osmeta/external/llvm-project/lldb/source/Host/common/Editline.cpp:1287:5
llvm#26 0x00007fe9eb9419e2 lldb_private::Editline::ConfigureEditor(bool)::$_0::__invoke(editline*, wchar_t*) /home/hyubo/osmeta/external/llvm-project/lldb/source/Host/common/Editline.cpp:1286:27
llvm#27 0x00007fe9f3384e26 el_getc /home/engshare/third-party2/libedit/3.1/src/libedit/src/read.c:439:14
llvm#28 0x00007fe9f3384e26 el_getc /home/engshare/third-party2/libedit/3.1/src/libedit/src/read.c:400:1
llvm#29 0x00007fe9f3384f90 read_getcmd /home/engshare/third-party2/libedit/3.1/src/libedit/src/read.c:247:14
llvm#30 0x00007fe9f3384f90 el_gets /home/engshare/third-party2/libedit/3.1/src/libedit/src/read.c:586:14
llvm#31 0x00007fe9eb9409f3 lldb_private::Editline::GetLine(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, bool&) /home/hyubo/osmeta/external/llvm-project/lldb/source/Host/common/Editline.cpp:1636:16
llvm#32 0x00007fe9eb8044d7 lldb_private::IOHandlerEditline::GetLine(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, bool&) /home/hyubo/osmeta/external/llvm-project/lldb/source/Core/IOHandler.cpp:339:5
llvm#33 0x00007fe9eb805609 lldb_private::IOHandlerEditline::Run() /home/hyubo/osmeta/external/llvm-project/lldb/source/Core/IOHandler.cpp:600:11
llvm#34 0x00007fe9eb7b214c lldb_private::Debugger::RunIOHandlers() /home/hyubo/osmeta/external/llvm-project/lldb/source/Core/Debugger.cpp:1280:16
llvm#35 0x00007fe9eb98f00f lldb_private::CommandInterpreter::RunCommandInterpreter(lldb_private::CommandInterpreterRunOptions&) /home/hyubo/osmeta/external/llvm-project/lldb/source/Interpreter/CommandInterpreter.cpp:3620:16
llvm#36 0x00007fe9eb4f0e09 lldb::SBDebugger::RunCommandInterpreter(bool, bool) /home/hyubo/osmeta/external/llvm-project/lldb/source/API/SBDebugger.cpp:1234:42
llvm#37 0x000055ca6788d6b0 Driver::MainLoop() /home/hyubo/osmeta/external/llvm-project/lldb/tools/driver/Driver.cpp:677:3
llvm#38 0x000055ca6788e226 main /home/hyubo/osmeta/external/llvm-project/lldb/tools/driver/Driver.cpp:887:17
llvm#39 0x00007fe9e5e2c657 __libc_start_call_main /home/engshare/third-party2/glibc/2.34/src/glibc-2.34/csu/../sysdeps/nptl/libc_start_call_main.h:58:16
llvm#40 0x00007fe9e5e2c718 call_init /home/engshare/third-party2/glibc/2.34/src/glibc-2.34/csu/../csu/libc-start.c:128:20
llvm#41 0x00007fe9e5e2c718 __libc_start_main@GLIBC_2.2.5 /home/engshare/third-party2/glibc/2.34/src/glibc-2.34/csu/../csu/libc-start.c:379:5
llvm#42 0x000055ca67889a11 _start /home/engshare/third-party2/glibc/2.34/src/glibc-2.34/csu/../sysdeps/x86_64/start.S:118:0
Segmentation fault (core dumped)
```

When `target symbols add` is run, `Symtab::AddSymbol()` can reallocate
the underlying `std::vector<Symbol>` and resize it, invalidating all
existing Symbol* pointers. While `Process::Flush()` clears stale stack
frames, the statusline caches its own `ExecutionContextRef` containing a
`StackID` with a `SymbolContextScope*` (which can be a `Symbol*`). This
cached reference is not cleared by `Process::Flush()`, so the next
statusline redraw accesses a dangling pointer and crashes.

Fix this by adding `Statusline::Flush()` which clears the cached frame,
`Debugger::Flush()` which forwards to it under the statusline mutex, and
calling `Debugger::Flush()` from `Process::Flush()` so that all flush
paths (symbol add, exec, module load) also invalidate the statusline's
stale state.

After this fix, lldb is not crashing anymore, new symbols from a symbol
file are correctly loaded

---------

Co-authored-by: George Hu <georgehuyubo@gmail.com>
ampandey-1995 pushed a commit that referenced this pull request May 4, 2026
…input" (llvm#195551)

Reverts llvm#190863 due to buildbot breakage e.g.,
https://lab.llvm.org/buildbot/#/builders/52/builds/16951

```
Failed Tests (1):
  LLVM :: tools/llvm-profgen/filter-build-id.test
```
```
==llvm-profgen==3809550==ERROR: AddressSanitizer: container-overflow on address 0x6e80441e1762 at pc 0x6216c3f2cdce bp 0x7fff3c3ddf60 sp 0x7fff3c3dd710
READ of size 8 at 0x6e80441e1762 thread T0
    #0 0x6216c3f2cdcd in MemcmpInterceptorCommon(void*, int (*)(void const*, void const*, unsigned long), void const*, void const*, unsigned long) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/compiler-rt/lib/asan/../sanitizer_common/sanitizer_common_interceptors.inc:848:7
    #1 0x6216c3f2d25c in bcmp /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/compiler-rt/lib/asan/../sanitizer_common/sanitizer_common_interceptors.inc:894:10
    #2 0x6216c400b836 in operator== /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/include/llvm/ADT/StringRef.h:914:10
    #3 0x6216c400b836 in operator!= /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/include/llvm/ADT/StringRef.h:917:69
    #4 0x6216c400b836 in llvm::sampleprof::PerfScriptReader::extractCallstack(llvm::sampleprof::TraceStream&, llvm::SmallVectorImpl<unsigned long>&) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:801:36
    #5 0x6216c400d37a in llvm::sampleprof::HybridPerfReader::parseSample(llvm::sampleprof::TraceStream&, unsigned long) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:881:8
    #6 0x6216c40150d8 in parseSample /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1118:3
    #7 0x6216c40150d8 in llvm::sampleprof::PerfScriptReader::parseEventOrSample(llvm::sampleprof::TraceStream&) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1201:5
    #8 0x6216c401539a in llvm::sampleprof::PerfScriptReader::parseAndAggregateTrace() /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1210:5
    llvm#9 0x6216c4018c88 in llvm::sampleprof::PerfScriptReader::parsePerfTraces() /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1457:3
    llvm#10 0x6216c3ff2c7a in main /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/llvm-profgen.cpp:229:19
    llvm#11 0x72404502a8c0  (/usr/lib/x86_64-linux-gnu/libc.so.6+0x2a8c0) (BuildId: ae327f26c123ea1374623c41e676a4bf00e5c1cb)
    llvm#12 0x72404502a9d7 in __libc_start_main (/usr/lib/x86_64-linux-gnu/libc.so.6+0x2a9d7) (BuildId: ae327f26c123ea1374623c41e676a4bf00e5c1cb)
    llvm#13 0x6216c3f0f3d4 in _start (/home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm_build_asan/bin/llvm-profgen+0x2f083d4)
0x6e80441e1762 is located 18 bytes inside of 48-byte region [0x6e80441e1750,0x6e80441e1780)
allocated by thread T0 here:
    #0 0x6216c3feab0d in operator new(unsigned long) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/compiler-rt/lib/asan/asan_new_delete.cpp:109:35
    #1 0x724045511c07 in __libcpp_allocate<char> /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/libcxx/include/__new/allocate.h:42:28
    #2 0x724045511c07 in allocate /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/libcxx/include/__memory/allocator.h:92:14
    #3 0x724045511c07 in allocate_at_least /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/libcxx/include/__memory/allocator.h:99:13
    #4 0x724045511c07 in allocate_at_least<std::__1::allocator<char> > /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/libcxx/include/__memory/allocator_traits.h:340:22
    #5 0x724045511c07 in __allocate_at_least<std::__1::allocator<char> > /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/libcxx/include/__memory/allocate_at_least.h:36:16
    #6 0x724045511c07 in __allocate_long_buffer /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/libcxx/include/string:2259:21
    #7 0x724045511c07 in std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>::__grow_by(unsigned long, unsigned long, unsigned long, unsigned long, unsigned long, unsigned long) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/libcxx/include/string:2769:25
    #8 0x6216c401d90a in __grow_by_without_replace /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/libcxx_install_asan/include/c++/v1/string:2795:3
    llvm#9 0x6216c401d90a in std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>& std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>::append[abi:sqn230000]<char const*, 0>(char const*, char const*) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/libcxx_install_asan/include/c++/v1/string:1431:9
    llvm#10 0x6216c401d1a6 in std::__1::basic_istream<char, std::__1::char_traits<char>>& std::__1::getline[abi:sqn230000]<char, std::__1::char_traits<char>, std::__1::allocator<char>>(std::__1::basic_istream<char, std::__1::char_traits<char>>&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>&, char) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/libcxx_install_asan/include/c++/v1/istream:1309:15
    llvm#11 0x6216c4014a76 in getline<char, std::__1::char_traits<char>, std::__1::allocator<char> > /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/libcxx_install_asan/include/c++/v1/istream:1343:10
    llvm#12 0x6216c4014a76 in advance /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.h:52:10
    llvm#13 0x6216c4014a76 in llvm::sampleprof::PerfScriptReader::parseAggregatedCount(llvm::sampleprof::TraceStream&) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1110:13
    llvm#14 0x6216c4015095 in parseSample /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1116:20
    llvm#15 0x6216c4015095 in llvm::sampleprof::PerfScriptReader::parseEventOrSample(llvm::sampleprof::TraceStream&) /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1201:5
    llvm#16 0x6216c401539a in llvm::sampleprof::PerfScriptReader::parseAndAggregateTrace() /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1210:5
    llvm#17 0x6216c4018c88 in llvm::sampleprof::PerfScriptReader::parsePerfTraces() /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/PerfReader.cpp:1457:3
    llvm#18 0x6216c3ff2c7a in main /home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm-project/llvm/tools/llvm-profgen/llvm-profgen.cpp:229:19
    llvm#19 0x72404502a8c0  (/usr/lib/x86_64-linux-gnu/libc.so.6+0x2a8c0) (BuildId: ae327f26c123ea1374623c41e676a4bf00e5c1cb)
    llvm#20 0x72404502a9d7 in __libc_start_main (/usr/lib/x86_64-linux-gnu/libc.so.6+0x2a9d7) (BuildId: ae327f26c123ea1374623c41e676a4bf00e5c1cb)
    llvm#21 0x6216c3f0f3d4 in _start (/home/b/sanitizer-x86_64-linux-bootstrap-asan/build/llvm_build_asan/bin/llvm-profgen+0x2f083d4)
```
ampandey-1995 pushed a commit that referenced this pull request May 21, 2026
llvm#183506 revealed a pre-existing
use-after-scope in createInstrInfo (MSan bot:
https://lab.llvm.org/buildbot/#/builders/164/builds/21562 [*]).

This patch fixes the issue by changing the stack-allocated
AArch64Subtarget (which goes out of scope once createInstrInfo()
returns) into heap-allocated, allowing it to be safely stored in the
returned AArch64InstrInfo.

-----

[*] WARNING: MemorySanitizer: use-of-uninitialized-value
#0 0x55555666fabd in
llvm::AArch64InstrInfo::getInstSizeInBytes(llvm::MachineInstr const&)
const
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/lib/Target/AArch64/AArch64InstrInfo.cpp:247:5
...

/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/unittests/Target/AArch64/InstSizes.cpp:85:3
llvm#9 0x555556508559 in InstSizes_MOVaddrTagged_Test::TestBody()
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/unittests/Target/AArch64/InstSizes.cpp:301:3
...

  Member fields were destroyed
#0 0x555556498a1d in __sanitizer_dtor_callback_fields
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/compiler-rt/lib/msan/msan_interceptors.cpp:1074:5
#1 0x5555564fbda6 in ~Triple
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/include/llvm/TargetParser/Triple.h:348:12
#2 0x5555564fbda6 in ~Triple
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/include/llvm/TargetParser/Triple.h:47:7
#3 0x5555564fbda6 in llvm::AArch64Subtarget::~AArch64Subtarget()
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/lib/Target/AArch64/AArch64Subtarget.h:38:7
#4 0x555556503396 in (anonymous
namespace)::createInstrInfo(llvm::TargetMachine*)
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/unittests/Target/AArch64/InstSizes.cpp:38:1
#5 0x5555565084cb in InstSizes_MOVaddrTagged_Test::TestBody()
/home/b/sanitizer-x86_64-linux-bootstrap-msan/build/llvm-project/llvm/unittests/Target/AArch64/InstSizes.cpp:299:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment