1. [clang-tidy] Suppress readability-static-access-through-instance for CUDA built-in variables (details)
  2. [NFC] [LoopPeel] Update IDoms of non-loop blocks dominated by the loop (details)
  3. llvm pretty printers: Fix StringRef and workaround StringMap in Python 2 (details)
  4. [NFC] Remove obsolete simplifyOnceImpl function (details)
  5. [llvm-profgen] Allow unsymbolized profile as perf input (details)
  6. [LLDB] Fix LLDB buildbots break due to --image-base (details)
  7. Make Python MLIR Operation not iterable (details)
  8. [lldb/DWARF] Move a declaration closer to its use (details)
  9. [lldb] Remove ConstString from Platform plugin names (details)
  10. [fir] Add substring to fir.slice operation (details)
  11. [clangd] IncludeCleaner: Don't consider the definition as usage for function forward declarations (details)
Commit b43a2aee4ee946d8897880e824f4b09fe4c46143 by carlosgalvezp
[clang-tidy] Suppress readability-static-access-through-instance for CUDA built-in variables

clang-tidy can be used to statically analyze CUDA code,
thanks to clang being able to compile CUDA code natively.
This makes clang-tidy the one and only open-source
static analyzer for CUDA.

However it currently warns for native CUDA built-in
variables, like threadIdx, due to the way they
are implemented in clang.

Users don't need to know the details of the clang
implementation, and they should continue to write
idiomatic code. Therefore, suppress the warning
if a CUDA built-in variable is encountered.

The file was modifiedclang-tools-extra/clang-tidy/readability/StaticAccessedThroughInstanceCheck.cpp
The file was modifiedclang-tools-extra/test/clang-tidy/checkers/readability-static-accessed-through-instance.cpp
The file was addedclang-tools-extra/test/clang-tidy/checkers/Inputs/readability-static-accessed-through-instance/__clang_cuda_builtin_vars.h
Commit d4c74cd4e8f321a63154fb7fc442399b38a69935 by mkazantsev
[NFC] [LoopPeel] Update IDoms of non-loop blocks dominated by the loop

When peeling a loop, we assume that the latch has a `br` terminator and that
all loop exits are either terminated with an `unreachable` or have a terminating
deoptimize call. So when we peel off the 1st iteration, we change the IDom of
all loop exits to the peeled copy of `NCD(IDom(Exit), Latch)`. This works now,
but if we add logic to support loops with exits that are followed by a block
with an `unreachable` or a terminating deoptimize call, changing the exit's idom
wouldn't be enough and DT would be broken.

For example, let `Exit1` and `Exit2` are loop exits, and each of them
unconditionally branches to the same `unreachable` terminated block. So neither
of the exits dominates this unreachable block. If we change the IDoms of the
exits to some peeled loop block, we don't update the dominators of the unreachable
block. Currently we just don't get to the peeling logic, saying that we can't peel
such loops.

Previously we stored exits' IDoms in a map before peeling a loop and then, after
peeling off one iteration, we changed their IDoms.
Now we use the same logic not only for exits but for all non-loop blocks dominated
by the loop.
So when we add logic to support peeling loops with exits which branch, for example,
to an unreachable-terminated block, we would update the IDoms not only for exits,
but for their successors.

Patch by Dmitry Makogon!

Differential Revision:
Reviewed By: mkazantsev, nikic
The file was modifiedllvm/lib/Transforms/Utils/LoopPeel.cpp
Commit a36032345ed823414fcee0f9aed43628f4320001 by dblaikie
llvm pretty printers: Fix StringRef and workaround StringMap in Python 2
The file was modifiedllvm/utils/gdb-scripts/
The file was modifiedcross-project-tests/debuginfo-tests/llvm-prettyprinters/gdb/llvm-support.gdb
Commit 9bbfe0f72c37a884c5a6c1654cc705258c5e2886 by mkazantsev
[NFC] Remove obsolete simplifyOnceImpl function

The function simplifyOnce only calls simplifyOnceImpl and does nothing else.
Having this separate helper makes no sense. Removing it.

Patch by Dmitry Bakunevich!

Differential Revision:
Reviewed By: mkazantsev
The file was modifiedllvm/lib/Transforms/Utils/SimplifyCFG.cpp
Commit a5f411b7f88caf1ef000a0397eb93d1a39d25690 by wlei
[llvm-profgen] Allow unsymbolized profile as perf input

This change allows the unsymbolized profile as input. The unsymbolized profile is created by `llvm-profgen` with `--skip-symbolization` and it's after the sample aggregation but before symbolization , so it has much small file size. It can be used for sample merging and trimming,  also is useful for debugging or adding test cases. A switch `--unsymbolized-profile=file-patch` is added for this.

Format of unsymbolized profile:

   [context stack1]    # If it's a CS profile
      number of entries in RangeCounter
      number of entries in BranchCounter
    [context stack2]

Reviewed By: hoy, wenlei

Differential Revision:
The file was modifiedllvm/tools/llvm-profgen/llvm-profgen.cpp
The file was modifiedllvm/test/tools/llvm-profgen/noinline-cs-noprobe.test
The file was modifiedllvm/tools/llvm-profgen/PerfReader.cpp
The file was modifiedllvm/include/llvm/ProfileData/SampleProf.h
The file was modifiedllvm/test/tools/llvm-profgen/inline-noprobe.test
The file was modifiedllvm/tools/llvm-profgen/PerfReader.h
The file was modifiedllvm/test/tools/llvm-profgen/inline-noprobe2.test
Commit 4c8ea90b252eeead9a6943f67444a229147949fb by omair.javaid
[LLDB] Fix LLDB buildbots break due to --image-base

LLDB build were failing due to following two test failures:
lldb-shell :: ObjectFile/ELF/basic-info.yaml
lldb-shell :: SymbolFile/DWARF/x86/debug-types-address-ranges.s

There were caused by commit 6506907a0a1a8a789ad7036ef911f7e31213c9a5
The file was modifiedlldb/test/Shell/SymbolFile/DWARF/x86/debug-types-address-ranges.s
The file was modifiedlldb/test/Shell/ObjectFile/ELF/basic-info.yaml
Commit f431d3878a07a67e544dacb98ad553b6a0b6b25a by joker.eph
Make Python MLIR Operation not iterable

The current behavior is conveniently allowing to iterate on the regions of an operation
implicitly by exposing an operation as Iterable. However this is also error prone and
code that may intend to iterate on the results or the operands could end up "working"
apparently instead of throwing a runtime error.
The lack of static type checking in Python contributes to the ambiguity here, it seems
safer to not do this and require and explicit qualification to iterate (`op.results`, `op.regions`, ...).

Reviewed By: ftynse

Differential Revision:
The file was modifiedmlir/test/python/ir/
The file was modifiedmlir/lib/Bindings/Python/IRCore.cpp
The file was modifiedmlir/python/mlir/dialects/
The file was modifiedmlir/test/python/dialects/
The file was modifiedmlir/test/python/dialects/
The file was modifiedmlir/python/mlir/dialects/
Commit b69564d94d90b83ccdcc501f811959c23aeec52a by pavel
[lldb/DWARF] Move a declaration closer to its use

Adresses post-commit feedback on D112310.
The file was modifiedlldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
Commit a458ef4f732b27312d8a5d20d2843d8bff35daeb by pavel
[lldb] Remove ConstString from Platform plugin names
The file was modifiedlldb/source/Plugins/Platform/Android/PlatformAndroid.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteiOS.cpp
The file was modifiedlldb/source/Plugins/Platform/Linux/PlatformLinux.cpp
The file was modifiedlldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.h
The file was modifiedlldb/source/Commands/CommandObjectPlatform.cpp
The file was modifiedlldb/source/Target/Platform.cpp
The file was modifiedlldb/unittests/Target/RemoteAwarePlatformTest.cpp
The file was modifiedlldb/source/Plugins/Platform/OpenBSD/PlatformOpenBSD.h
The file was modifiedlldb/source/Plugins/Platform/Linux/PlatformLinux.h
The file was modifiedlldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.h
The file was modifiedlldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteAppleBridge.h
The file was modifiedlldb/source/Plugins/Platform/OpenBSD/PlatformOpenBSD.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.cpp
The file was modifiedlldb/source/Plugins/Platform/Windows/PlatformWindows.h
The file was modifiedlldb/source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteMacOSX.h
The file was modifiedlldb/source/Plugins/Platform/FreeBSD/PlatformFreeBSD.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformDarwinKernel.h
The file was modifiedlldb/source/API/SBDebugger.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.h
The file was modifiedlldb/source/Plugins/Platform/NetBSD/PlatformNetBSD.h
The file was modifiedlldb/source/Plugins/Platform/gdb-server/PlatformRemoteGDBServer.cpp
The file was modifiedlldb/source/Plugins/Platform/Android/PlatformAndroid.h
The file was modifiedlldb/source/Core/IOHandlerCursesGUI.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformDarwinKernel.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteAppleBridge.cpp
The file was modifiedlldb/source/Plugins/Platform/Windows/PlatformWindows.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteAppleWatch.cpp
The file was modifiedlldb/source/Plugins/Platform/NetBSD/PlatformNetBSD.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteAppleWatch.h
The file was modifiedlldb/source/Core/PluginManager.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformAppleSimulator.h
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteMacOSX.cpp
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteiOS.h
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformMacOSX.h
The file was modifiedlldb/include/lldb/Target/Platform.h
The file was modifiedlldb/source/Plugins/Platform/MacOSX/PlatformRemoteAppleTV.cpp
The file was modifiedlldb/include/lldb/Core/PluginManager.h
Commit 7812f510d28f34ed6209b1a382cdad7247b9090c by clementval
[fir] Add substring to fir.slice operation

This patch adds the substriing information to the fir.slice
operation. This will be used by character operations in later
upstreaming patches.

This patch is part of the upstreaming effort from fir-dev branch.

Reviewed By: jeanPerier

Differential Revision:

Co-authored-by: Eric Schweitz <>
The file was modifiedflang/include/flang/Optimizer/Dialect/
The file was modifiedflang/lib/Optimizer/Dialect/FIROps.cpp
The file was modifiedflang/test/Fir/invalid.fir
The file was modifiedflang/test/Fir/fir-ops.fir
Commit c521288ed391bd29a37f1c444d08ae542df5341c by kbobyrev
[clangd] IncludeCleaner: Don't consider the definition as usage for function forward declarations

Reviewed By: kadircet

Differential Revision:
The file was modifiedclang-tools-extra/clangd/IncludeCleaner.cpp
The file was modifiedclang-tools-extra/clangd/unittests/IncludeCleanerTests.cpp