[X86][NewPM] Port DynAllocaExpander to New PM
No tests modified as there are none that explicitly stop at
DynAllocaExpander, and we do not have enough of a pipeline to run those
yet anyways.
Reviewers: phoebewang, RKSimon, paperchalice, arsenm
Reviewed By: arsenm
Pull Request: https://github.com/llvm/llvm-project/pull/167740
[clang][HLSL] Fix crash issue due to Twine usage
- Dangling pointer (from std::string) is created and trigger crash on
some Linux distributions under different build types.
[flang] Fixed regression in copy-in/copy-out (#161259)
Fixed the polymprphic check for copy-in/copy-out, added regression
tests.
Changed MayNeedCopy() to return std::optional<bool> and renamed it to
ActualArgNeedsCopy(). This function now returns true/false when it's
known that actual arguments needs copy in/out, or std::nullopt to
signify that it's now known, whether copy in/out is needed.
Fixes #159149
[libc] Handle the `unknown` default target in CMake (#115122)
When the backend for the host target isn't enabled, Clang would report
the default target as `unknown`. This currently breaks the libc CMake
build, but shouldn't in the case where we're cross-compiling since we're
given an explicit target and the default one isn't being used.
[bazel] Fix LLDB :Host Build (#167711)
On some systems (probably those with a more recent clang), building
:Host errors out with a layering check violation due to the histedit.h
system include. Opt it out of layering checks for now, similar to other
targets that depend on non standard library system includes.
[mlir][memref] Remove invalid `extract_aligned_pointer_as_index` folding in `ExpandStridedMetadata` (#167615)
`RewriteExtractAlignedPointerAsIndexOfViewLikeOp` tries to propagate
`extract_aligned_pointer_as_index` through the view ops.
`ViewLikeOpInterface` by itself doesn't guarantee to preserve the base
pointer and `memref.view` is one such example, so limit pattern to a few
specific ops.
TargetLowering: Avoid hardcoding OpenBSD + __guard_local name
Query RuntimeLibcalls for the support and the name. The check
that the implementation is exactly __guard_local instead of
unsupported feels a bit strange.
[lldb][ClangExpressionParser] Clean up ownership of members in ClangDiagnosticManagerAdapter (#167731)
This aligns `ClangDiagnosticManagerAdapter` with how we set up the
diagnostics in `ClangModulesDeclVendor`. We fixed lifetime issues around
the same kind of setup here:
https://github.com/llvm/llvm-project/pull/167724
This class didn't suffer from the same lifetime issue because it used
`shared_ptr`s. So the stream wasn't freed before
`~TextDiagnosticPrinter` accessing it. But that begged the question of
why these are `shared_ptr`s in the first place. This patch makes these
`unique_ptr`s and fixes the destruction order that would now be an
issue.
[lldb] Remove test that disassembles all of Foundation (#167596)
This test attempts to disassemble every Code symbol in Foundation.
There's no need to disassemble every code symbol and this certainly does
not scale. In some cases, this test can take multiple minutes to run or
even time out.
[MLIR][XeGPU][TransformOps] Add convert_layout op (#167342)
Adds `transform.xegpu.convert_layout` transform op that inserts an
`xegpu.convert_layout` op for a given `Value`.
[lldb] Adapt shared cache ObjC class metadata extraction for long term growth (#167579)
On Apple's platforms, the size of the shared cache grows steadily. As it
grows, so does its list of ObjC classes. LLDB currently accepts an upper
limit to the number of classes when it extracts the class information.
Every few years we will hit the limit and increase the upper limit of
classes.
This approach is fundamentally unsustainable. On top of needing to
manually adjust the number every few years, our current method requires
us to allocate memory in the inferior process. On macOS this is usually
not a problem, but on embedded devices there is usually a limit to how
much memory a process can allocate before they are killed by the OS.
My solution involves running the metadata extraction logic multiple
times. I've added a new parameter to our utility function `start_idx`
that keeps track of where it stopped during the previous run so that it
may pick up again where it stopped.
rdar://91398396
[mlir][linalg][python] Add Python Bindings for Inferring Contraction Dimensions from Affine Maps (#167587)
This PR exposes `linalg::inferContractionDims(ArrayRef<AffineMap>)` to
Python, allowing users to infer contraction dimensions (batch/m/n/k)
directly from a list of affine maps without needing an operation.
---------
Signed-off-by: Bangtian Liu <liubangtian at gmail.com>
[CIR] Handle null base class initialization (#167023)
This adds handling for null base class initialization, but only for the
trivial case where the class is empty. This also moves
emitCXXConstructExpr to CIRGenExprCXX.cpp for consistency with classic
codegen and the incubator repo.
[AMDGPU] Avoid changing minOccupancy if unclustered schedule was not run for any region. (#162025)
During init of unclustered schedule stage, minOccupancy may be
temporarily increased. But subsequently, if none of the regions are
scheduled because they don't meet the conditions of initGCNRegion,
minOccupancy remains incorrectly set. This patch avoids this
incorrectness by delaying the change of minOccupancy until a region is
about to be scheduled.