LLVM/project 74c8891lldb/source/Plugins/InstrumentationRuntime/TSan InstrumentationRuntimeTSan.cpp, lldb/test/API/functionalities/tsan/thread_leak TestTsanThreadLeak.py

Revert "[lldb] Fix TSan report on Linux (#179115)"

This reverts commit cc7292056683f592c33055bb6456d509201654ec.

This patch causes two tests to unexpectedly pass:
1. lldb-api.functionalities/tsan/cpp_global_location/TestTsanCPPGlobalLocation.py
2. lldb-api.functionalities/tsan/global_location/TestTsanGlobalLocation.py

Reverting to fix premerge. Not fixing forward so someone who is familiar
with LLDB can take a look and make sure those tests now should pass.
DeltaFile
+2-14lldb/source/Plugins/InstrumentationRuntime/TSan/InstrumentationRuntimeTSan.cpp
+4-0lldb/test/API/functionalities/tsan/thread_numbers/TestTsanThreadNumbers.py
+4-0lldb/test/API/functionalities/tsan/thread_leak/TestTsanThreadLeak.py
+10-143 files

LLVM/project 80677dcclang/lib/CIR/CodeGen CIRGenBuiltinAArch64.cpp, clang/lib/CIR/Lowering/DirectToLLVM LowerToLLVM.cpp

[CIR][NEON] Add lowering support for `vceqzd_s64` (#179779)

Rather than creating a dedicated ClangIR test file, the original test file for
this intrinsic is effectively reused:

  * clang/test/CodeGen/AArch64/neon-intrinsics.c

“Effectively” meaning that the corresponding test is moved (rather than
literally reused) to a new file within the original AArch64 builtins test
directory:

  * clang/test/CodeGen/AArch64/neon/intrinsics.c

This is necessary to avoid lowering unsupported examples from intrinsics.c with
`-fclangir`. The new file will eventually replace the original one once all
builtins from it can be lowered via ClangIR.

To facilitate test re-use, new LIT "feature" is added so that CIR tests can be
run conditionally, e.g. the following will only run when `CLANG_ENABLE_CIR` is

    [8 lines not shown]
DeltaFile
+44-1clang/lib/CIR/CodeGen/CIRGenBuiltinAArch64.cpp
+33-0clang/test/CodeGen/AArch64/neon/intrinsics.c
+0-11clang/test/CodeGen/AArch64/neon-intrinsics.c
+8-3clang/lib/CodeGen/TargetBuiltins/ARM.cpp
+2-0clang/test/lit.cfg.py
+1-0clang/lib/CIR/Lowering/DirectToLLVM/LowerToLLVM.cpp
+88-151 files not shown
+89-157 files

LLVM/project 48f5342utils/bazel/llvm-project-overlay/mlir BUILD.bazel build_defs.bzl

[bazel] Slight polish after ef68a53.
DeltaFile
+6-15utils/bazel/llvm-project-overlay/mlir/BUILD.bazel
+2-2utils/bazel/llvm-project-overlay/mlir/build_defs.bzl
+8-172 files

LLVM/project 1d5884dlldb/test/API/tools/lldb-dap/breakpoint-events TestDAP_breakpointEvents.py foo.cpp

[lldb-dap] Fix the breakpoint events test. (#180518)

Previously the test was written in a way that may be flaky, fixed with
the following changes.
- The breakpoint are placed on functions and set during the
configuration stage of the protocol.
 - Add the rpath to the test binary.
 - Check we also hit the breakpoint we set directly using lldb.
DeltaFile
+91-61lldb/test/API/tools/lldb-dap/breakpoint-events/TestDAP_breakpointEvents.py
+2-2lldb/test/API/tools/lldb-dap/breakpoint-events/foo.cpp
+1-0lldb/test/API/tools/lldb-dap/breakpoint-events/Makefile
+94-633 files

LLVM/project 06e86c3flang/lib/Semantics resolve-directives.cpp, flang/test/Semantics/OpenMP local-variables.f90 local-variables-1.f90

[flang][OpenMP] Improve locality check when determining DSA

Follow-up to https://github.com/llvm/llvm-project/pull/178739.

The locality check assumed that immediately after the initial symbol
resolution (i.e. prior to the OpenMP code in resolve-directives.cpp),
the scope that owns a given symbol is the scope which owns the symbol's
storage. Turns out that this isn't necessarily true as illustrated by
the included testcase, roughly something like:
```
program main
  integer :: j        ! host j (storage-owning)
  contains
  subroutine f
    !$omp parallel    ! scope that owns j, but j is host-associated
    do j = ...
    end do
    !$omp end parallel
  end

    [18 lines not shown]
DeltaFile
+0-95flang/test/Semantics/OpenMP/local-variables.f90
+95-0flang/test/Semantics/OpenMP/local-variables-1.f90
+52-0flang/test/Semantics/OpenMP/local-variables-2.f90
+39-2flang/lib/Semantics/resolve-directives.cpp
+186-974 files

LLVM/project be711a0lldb/source/Host/windows ProcessLauncherWindows.cpp

[lldb][windows] remove unneeded DeleteProcThreadAttributeList call (#180579)

Remove an unneeded call to `DeleteProcThreadAttributeList`, which is
already done in the `ProcThreadAttributeList` destructor.
DeltaFile
+0-3lldb/source/Host/windows/ProcessLauncherWindows.cpp
+0-31 files

LLVM/project cd47ae9compiler-rt/test/profile instrprof-binary-correlate.c, llvm/include/llvm/ProfileData InstrProfCorrelator.h

[Profile] Enable binary profile correlation for Mach-O binaries (#179937)

The existing ELF/COFF correlation code mostly "just works" on Mach-O
files, with one gotcha: on disk, the pointers in `__llvm_covdata` are
stored in an encoded format due to dyld fixup chains. (In memory, they
would normally be fixed up at load time in a running binary, but the
correlator only looks at the on-disk values.)

LLVM's Mach-O reader knows how to decode the format, so this patch walks
the fixup table to create a set of mappings that the correlator can use
to resolve the values.

rdar://168259786
DeltaFile
+34-4llvm/lib/ProfileData/InstrProfCorrelator.cpp
+6-1llvm/include/llvm/ProfileData/InstrProfCorrelator.h
+1-1compiler-rt/test/profile/instrprof-binary-correlate.c
+41-63 files

LLVM/project 1bfa717llvm/lib/Target/Sparc SparcTargetTransformInfo.h SparcTargetTransformInfo.cpp, llvm/test/Transforms/LoopIdiom/Sparc popcnt.ll lit.local.cfg

[SPARC] Add TTI implementation for getPopcntSupport (#178843)

This is to inform the middle-end transform passes about the capabilities
of the codegen backend.

This should solve the issue where popcount loops not gets converted
properly to `popc`, even if it's available
(https://github.com/llvm/llvm-project/issues/171969).
DeltaFile
+325-0llvm/test/Transforms/LoopIdiom/Sparc/popcnt.ll
+50-0llvm/lib/Target/Sparc/SparcTargetTransformInfo.h
+22-0llvm/lib/Target/Sparc/SparcTargetTransformInfo.cpp
+6-0llvm/lib/Target/Sparc/SparcTargetMachine.cpp
+3-0llvm/lib/Target/Sparc/CMakeLists.txt
+2-0llvm/test/Transforms/LoopIdiom/Sparc/lit.local.cfg
+408-01 files not shown
+409-07 files

LLVM/project 352932clldb/include/lldb/Host/windows ProcessLauncherWindows.h, lldb/source/Host/windows ProcessLauncherWindows.cpp

[NFC][lldb][windows] extract the UpdateProcThreadAttribute logic (#180565)

This NFC patch extracts the `UpdateProcThreadAttribute` logic to a
dedicated method be able to reuse it in
https://github.com/llvm/llvm-project/pull/180561.
DeltaFile
+13-4lldb/source/Host/windows/ProcessLauncherWindows.cpp
+8-1lldb/include/lldb/Host/windows/ProcessLauncherWindows.h
+21-52 files

LLVM/project f7e2e4dclang/unittests/Analysis/FlowSensitive UncheckedStatusOrAccessModelTestFixture.cpp

[NFC] [FlowSensitive] [StatusOr] Add test reassigning variable in loop



Reviewers: jvoung

Reviewed By: jvoung

Pull Request: https://github.com/llvm/llvm-project/pull/180091
DeltaFile
+49-0clang/unittests/Analysis/FlowSensitive/UncheckedStatusOrAccessModelTestFixture.cpp
+49-01 files

LLVM/project 839676bcompiler-rt/lib/asan asan_malloc_linux.cpp asan_allocator.cpp, compiler-rt/lib/sanitizer_common sanitizer_allocator.cpp sanitizer_allocator_internal.h

[asan][AIX] Add vec_malloc and vec_calloc interceptors (#175584)

On AIX, when both the `__VEC__` and `_ALL_SOURCE` macros are defined
(they are defined by default), the malloc and calloc system calls are
mapped to vec_malloc and vec_calloc respectively, so we need the
following vec_malloc and vec_calloc interceptors.

Issue: #138916
DeltaFile
+32-0compiler-rt/test/asan/TestCases/AIX/vec_malloc_calloc.cpp
+23-0compiler-rt/lib/asan/asan_malloc_linux.cpp
+13-2compiler-rt/lib/asan/asan_allocator.cpp
+3-2compiler-rt/lib/sanitizer_common/sanitizer_allocator.cpp
+3-2compiler-rt/lib/sanitizer_common/sanitizer_allocator_internal.h
+4-0compiler-rt/lib/asan/asan_allocator.h
+78-61 files not shown
+80-87 files

LLVM/project bc884a0clang/unittests/Analysis/FlowSensitive UncheckedStatusOrAccessModelTestFixture.cpp

[NFC] [FlowSensitive] [StatusOr] Add test for StatusOr nested in optional



Reviewers: jvoung

Reviewed By: jvoung

Pull Request: https://github.com/llvm/llvm-project/pull/180082
DeltaFile
+38-0clang/unittests/Analysis/FlowSensitive/UncheckedStatusOrAccessModelTestFixture.cpp
+38-01 files

LLVM/project d34d19dclang/unittests/Analysis/FlowSensitive UncheckedStatusOrAccessModelTestFixture.cpp

[NFC] [FlowSensitive] [StatusOr] Add tests for pointer receivers



Reviewers: jvoung

Reviewed By: jvoung

Pull Request: https://github.com/llvm/llvm-project/pull/180079
DeltaFile
+128-0clang/unittests/Analysis/FlowSensitive/UncheckedStatusOrAccessModelTestFixture.cpp
+128-01 files

LLVM/project 9ab3e33llvm/lib/Transforms/IPO IPO.cpp LoopExtractor.cpp

Revert "[NFC][LLVM][IPO] Remove pass initialization from pass constructors" (#180571)

Reverts llvm/llvm-project#180154

It seems to cause llc build failures, likely due to missing `ipo`
dependency.
DeltaFile
+2-3llvm/lib/Transforms/IPO/IPO.cpp
+3-1llvm/lib/Transforms/IPO/LoopExtractor.cpp
+3-1llvm/lib/Transforms/IPO/GlobalDCE.cpp
+3-1llvm/lib/Transforms/IPO/AlwaysInliner.cpp
+3-1llvm/lib/Transforms/IPO/BarrierNoopPass.cpp
+3-1llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp
+17-81 files not shown
+17-97 files

LLVM/project a29f0ddllvm/tools/llubi llubi.cpp, llvm/tools/llubi/lib Value.cpp Interpreter.cpp

[llubi] Add initial support for llubi (#180022)

This patch implements the initial support for upstreaming
[llubi](https://github.com/dtcxzyw/llvm-ub-aware-interpreter). It only
provides the minimal functionality to run a simple main function. I hope
we can focus on the interface design in this PR, rather than trivial
implementations for each instruction.
RFC link:
https://discourse.llvm.org/t/rfc-upstreaming-llvm-ub-aware-interpreter/89645

Excluding the driver `llubi.cpp`, this patch contains three components
for better decoupling:
+ `Value.h/cpp`: Value representation
+ `Context.h/cpp`: Global state management (e.g., memory) and
interpreter configuration
+ `Interpreter.cpp`: The main interpreter loop

Compared to the out-of-tree version, the major differences are listed
below:

    [12 lines not shown]
DeltaFile
+239-0llvm/tools/llubi/llubi.cpp
+230-0llvm/tools/llubi/lib/Value.cpp
+202-0llvm/tools/llubi/lib/Interpreter.cpp
+185-0llvm/tools/llubi/lib/Context.h
+152-0llvm/tools/llubi/lib/Value.h
+129-0llvm/tools/llubi/lib/Context.cpp
+1,137-09 files not shown
+1,279-015 files

LLVM/project 77cb666llvm/lib/Target/AArch64 AArch64LoadStoreOptimizer.cpp AArch64InstrInfo.cpp, llvm/test/CodeGen/AArch64 ldst-opt.mir

[AArch64] Add support for B and H loads/stores in LoadStoreOptimizer (#180535)

This means the load/store optimizer can generate pre and post increment
versions of these instructions.
DeltaFile
+250-0llvm/test/CodeGen/AArch64/ldst-opt.mir
+20-0llvm/lib/Target/AArch64/AArch64LoadStoreOptimizer.cpp
+4-0llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
+274-03 files

LLVM/project ff86dd0llvm/lib/Transforms/IPO IPO.cpp LoopExtractor.cpp

Revert "[NFC][LLVM][IPO] Remove pass initialization from pass constructors (#…"

This reverts commit d62bc3ae0ea289e586e706332a364fa2f1114778.
DeltaFile
+2-3llvm/lib/Transforms/IPO/IPO.cpp
+3-1llvm/lib/Transforms/IPO/LoopExtractor.cpp
+3-1llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp
+3-1llvm/lib/Transforms/IPO/AlwaysInliner.cpp
+3-1llvm/lib/Transforms/IPO/BarrierNoopPass.cpp
+3-1llvm/lib/Transforms/IPO/GlobalDCE.cpp
+17-81 files not shown
+17-97 files

LLVM/project a140980llvm/lib/Target/AArch64 AArch64InstrInfo.td AArch64ISelLowering.cpp, llvm/test/CodeGen/AArch64 arm64-cvt-simd-fptoi.ll arm64-cvtf-simd-itofp.ll

fixup!

Adjust code
DeltaFile
+46-178llvm/test/CodeGen/AArch64/arm64-cvt-simd-fptoi.ll
+10-40llvm/test/CodeGen/AArch64/arm64-cvtf-simd-itofp.ll
+2-2llvm/lib/Target/AArch64/AArch64InstrInfo.td
+1-1llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
+59-2214 files

LLVM/project 3163fe9llvm/lib/Target/AArch64 AArch64InstrInfo.td AArch64ISelLowering.cpp, llvm/test/CodeGen/AArch64 arm64-cvt-simd-fptoi.ll arm64-cvtf-simd-itofp.ll

[AArch64][llvm] Allow FPRCVT insns to run in streaming mode if safe

For FEAT_FPRCVT instructions, allow them to run in streaming mode if safe
DeltaFile
+34-92llvm/test/CodeGen/AArch64/arm64-cvt-simd-fptoi.ll
+10-20llvm/test/CodeGen/AArch64/arm64-cvtf-simd-itofp.ll
+2-2llvm/lib/Target/AArch64/AArch64InstrInfo.td
+3-0llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
+49-1144 files

LLVM/project 404f9e6llvm/lib/Target/AMDGPU AMDGPURegBankLegalizeRules.cpp, llvm/test/CodeGen/AMDGPU llvm.amdgcn.sffbh.ll

AMDGPU/GlobalISel: RegBankLegalize rules for amdgcn_sffbh (#180099)

Change test to use update_llc_test_checks.py and make `v_flbit` test
actually divergent.
DeltaFile
+29-19llvm/test/CodeGen/AMDGPU/llvm.amdgcn.sffbh.ll
+4-0llvm/lib/Target/AMDGPU/AMDGPURegBankLegalizeRules.cpp
+33-192 files

LLVM/project b6ee085.github/workflows release-documentation.yml release-tasks.yml

workflows/release-task: Use less privileged token for uploading release notes (#180299)

We were using one token for both pushing to the llvmbot fork and for
creating a pull request against the www-releases repository, since the
fork and the repository have different owners, we were using a classic
access token which has very coarse-grained permissions. By using two
separate tokens, we limit the permissions to just what we need to do the
task.

Also, at the same time run the release-documentation job in an
environment, so we can limit the accessiblity to these secrets.
DeltaFile
+6-1.github/workflows/release-documentation.yml
+2-0.github/workflows/release-tasks.yml
+8-12 files

LLVM/project 0040bdfllvm/lib/Target/AMDGPU AMDGPURegBankLegalizeRules.cpp, llvm/test/CodeGen/AMDGPU/GlobalISel llvm.amdgcn.struct.buffer.atomic.swap.ll llvm.amdgcn.raw.buffer.atomic.swap.ll

AMDGPU/GlobalISel: Regbanklegalize rules for buffer atomic swap (#180265)

DeltaFile
+658-0llvm/test/CodeGen/AMDGPU/GlobalISel/llvm.amdgcn.struct.buffer.atomic.swap.ll
+620-0llvm/test/CodeGen/AMDGPU/GlobalISel/llvm.amdgcn.raw.buffer.atomic.swap.ll
+250-0llvm/test/CodeGen/AMDGPU/GlobalISel/llvm.amdgcn.raw.ptr.buffer.atomic.swap.ll
+244-0llvm/test/CodeGen/AMDGPU/GlobalISel/llvm.amdgcn.struct.ptr.buffer.atomic.swap.ll
+4-0llvm/lib/Target/AMDGPU/AMDGPURegBankLegalizeRules.cpp
+1,776-05 files

LLVM/project cc72920lldb/source/Plugins/InstrumentationRuntime/TSan InstrumentationRuntimeTSan.cpp, lldb/test/API/functionalities/tsan/thread_leak TestTsanThreadLeak.py

[lldb] Fix TSan report on Linux (#179115)

Linux uses 0 for `RTLD_DEFAULT` opposite to macOS and BSD systems (they
use -2).
DeltaFile
+14-2lldb/source/Plugins/InstrumentationRuntime/TSan/InstrumentationRuntimeTSan.cpp
+0-4lldb/test/API/functionalities/tsan/thread_numbers/TestTsanThreadNumbers.py
+0-4lldb/test/API/functionalities/tsan/thread_leak/TestTsanThreadLeak.py
+14-103 files

LLVM/project 8bbdac9llvm/lib/CodeGen/MIRParser MIParser.cpp MILexer.cpp, llvm/test/CodeGen/MIR/AMDGPU instr-mmra-error.mir instr-mmra.mir

[MIParser] - Add support for MMRAs (#180320)

Probably just forgotten in #78569
DeltaFile
+49-0llvm/test/CodeGen/MIR/AMDGPU/instr-mmra-error.mir
+25-0llvm/test/CodeGen/MIR/AMDGPU/instr-mmra.mir
+21-2llvm/lib/CodeGen/MIRParser/MIParser.cpp
+1-0llvm/lib/CodeGen/MIRParser/MILexer.cpp
+1-0llvm/lib/CodeGen/MIRParser/MILexer.h
+97-25 files

LLVM/project d62bc3allvm/lib/Transforms/IPO IPO.cpp GlobalDCE.cpp

[NFC][LLVM][IPO] Remove pass initialization from pass constructors (#180154)

DeltaFile
+3-2llvm/lib/Transforms/IPO/IPO.cpp
+1-3llvm/lib/Transforms/IPO/GlobalDCE.cpp
+1-3llvm/lib/Transforms/IPO/AlwaysInliner.cpp
+1-3llvm/lib/Transforms/IPO/BarrierNoopPass.cpp
+1-3llvm/lib/Transforms/IPO/DeadArgumentElimination.cpp
+1-3llvm/lib/Transforms/IPO/LoopExtractor.cpp
+8-171 files not shown
+9-177 files

LLVM/project 35efbc0flang/lib/Parser prescan.cpp, flang/test/Parser continuation-in-conditional-compilation.f

[flang] Warn if conditional compilation statements begin with a continuation line (#179802)

In fixed source form, allow conditional compilation statements to begin
with a continuation line and emit a warning. This behavior is similar
to that of regular statements and -E mode.

Fixes #129457
DeltaFile
+21-21flang/lib/Parser/prescan.cpp
+6-0flang/test/Parser/OpenMP/cont-in-cond-comp.f
+6-0flang/test/Parser/continuation-in-conditional-compilation.f
+2-2flang/test/Parser/OpenMP/sentinels.f
+35-234 files

LLVM/project 7fcc12coffload/test lit.cfg, offload/test/mapping firstprivate_aligned.cpp

Reapply [Offload][lit] Link against SPIR-V DeviceRTL if present (#180231)

I'll merge this at the same time as some llvm-zorg changes that start
building the DeviceRTL.

We only see one new test passing because everything still fails because
of the issue described in
https://github.com/llvm/llvm-project/pull/178980

Once a fix for that issue is merged we will see many new passes.
DeltaFile
+3-2offload/test/lit.cfg
+0-1offload/test/mapping/firstprivate_aligned.cpp
+3-32 files

LLVM/project e6a72a1llvm/lib/Target/RISCV RISCVISelLowering.cpp RISCVISelDAGToDAG.cpp, llvm/test/CodeGen/RISCV rv32p.ll

[RISCV] Combine ADDD+WMULSU to WMACCSU (#180454)

Extend the existing combineADDDToWMACC DAG combine to also match
RISCVISD::WMULSU and produce RISCVISD::WMACCSU. This is similar to
how ADDD+UMUL_LOHI is combined to WMACCU and ADDD+SMUL_LOHI is
combined to WMACC.

This patch was generated by AI, but I reviewed it.
DeltaFile
+28-12llvm/lib/Target/RISCV/RISCVISelLowering.cpp
+28-0llvm/test/CodeGen/RISCV/rv32p.ll
+16-3llvm/lib/Target/RISCV/RISCVISelDAGToDAG.cpp
+1-0llvm/lib/Target/RISCV/RISCVInstrInfoP.td
+73-154 files

LLVM/project e6c73eblibcxx/docs CodingGuidelines.rst

[libc++][docs] Update `[[nodiscard]]` coding guidelines (#178384)

as requested in
https://github.com/llvm/llvm-project/pull/176936#pullrequestreview-3706775444

Clarifies when not to apply `[[nodiscard]]`.


https://libcxx.llvm.org/CodingGuidelines.html#apply-nodiscard-where-relevant

---------

Co-authored-by: Nikolas Klauser <nikolasklauser at berlin.de>
Co-authored-by: Hristo Hristov <zingam at outlook.com>
DeltaFile
+4-1libcxx/docs/CodingGuidelines.rst
+4-11 files

LLVM/project efe3cc2llvm/lib/Target/AArch64 AArch64ISelLowering.cpp, llvm/test/CodeGen/AArch64 arm64-cvt-simd-fptoi.ll arm64-cvtf-simd-itofp.ll

[AArch64][llvm] Preserve FP_TO_*_SAT VT operand in SVE scalar-combine

Updated RUN lines and generated new `CHECK‑SME`/`CHECK‑SVE` lines in:

    llvm/test/CodeGen/AArch64/arm64-cvt-simd-fptoi.ll
    llvm/test/CodeGen/AArch64/arm64-cvtf-simd-itofp.ll

by adding `-force-streaming` and `-force-streaming-compatible` runs,
as pre-commit tests for a future change to enable FPRCVT streaming.

This triggers a SVE scalar-combine path which requires a code update.
FP_TO_*_SAT nodes require operand 1 (the saturation VT) to be present.
Without it the node is malformed and hits the SelectionDAG assertion
“Invalid child # of SDNode!”.

Also, skip the SVE combine if the scalar/custom op is already legal.
DeltaFile
+1,552-0llvm/test/CodeGen/AArch64/arm64-cvt-simd-fptoi.ll
+282-0llvm/test/CodeGen/AArch64/arm64-cvtf-simd-itofp.ll
+16-1llvm/lib/Target/AArch64/AArch64ISelLowering.cpp
+1,850-13 files