[lldb-server] Implement support for MultiBreakpoint packet
This is fairly straightforward, thanks to the helper functions created
in the previous commit.
https://github.com/llvm/llvm-project/pull/192910
Remove unused parameter; NFC (#193767)
As part of removing delayed typo handling in
9eef4d1c5fa6b1bcbbe675c14ca8301d5d346f7b, the KeywordReplacement
parameter ended up being unused, so this patch removes it and adjusts
the callers. This issue was discovered by a downstream static analysis
scan.
It is an NFC change because the callers of the function were looking for
a sentinel return value to determine whether they needed to call
UnconsumeToken on that parameter, but those calls cannot be reached
because the sentinel return value cannot be produced any longer.
[flang] Route elemental CHARACTER MIN/MAX OPTIONAL cases through custom lowering (#191244)
Follow-up to #189464.
Elemental CHARACTER MIN/MAX with dynamically optional arguments was
bypassing the custom optional-handling path and could lower incorrectly.
This change routes those cases through `genCustomIntrinsicRefCore` so
they hit the existing TODO instead of producing bad code. It also
unwraps sequence types before checking `fir::isa_char`, so the same TODO
is triggered for elemental calls as well as scalar ones, and adds a
negative test for the diagnostic.
Co-authored-by: Sairudra More <moresair at pe31.hpc.amslabs.hpecorp.net>
[lldb-server][NFC] Factor out code handling breakpoint packets
This commit extracts the code handling breakpoint packets into a helper
function that can be used by a future implementation of the
MultiBreakpointPacket.
It is meant to be purely NFC.
There are two functions handling breakpoint packets (`handle_Z`
and `handle_z`) with a lot of repeated code. This commit did not attempt
to merge the two, as that would make the diff much larger due to subtle
differences in the error message produced by the two. The only
deduplication done is in the code processing a GDBStoppointType, where a
helper struct (`BreakpointKind`) and function (`std::optional<BreakpointKind> getBreakpointKind(GDBStoppointType stoppoint_type)`) was created.
https://github.com/llvm/llvm-project/pull/192910
[llubi] Implement intrinsics for integer arithmetic/bit manipulation (#193702)
This PR implements intrinsics for integer arithmetic (from the [Standard
C/C++ Library
Intrinsics](https://llvm.org/docs/LangRef.html#standard-c-c-library-intrinsics)),
bit manipulation, overflow arithmetic, and saturation arithmetic.
Use the new FCNTL mechanism to move blocks to clean segments, rather than
duplicating the code in user space. lfs_cleanerd still decides which
segments' blocks to move but no longer identifies individual blocks
for cleaning, and does not handle file data.
Reland #2 "[STLExtras] Add a template for detecting whether a type has an equality comparison operator" (#177415)
Reland PR #176893 which was an attempt to reland PR #176429.
Fix:
There was a test case asserting that for types `StructA` `StructB` where
`operator==(const StructB &, const StructA &)` is defined,
`has_equality_comparison_v<StructA, StructB>` is false because the
arguments are the wrong way around. However, in C++20, operator overload
resolution was changed so that for reflexive comparison operators `==`
and `!=` if a candidate exists with the arguments swapped then this will
be used. This means the test case failed when compiled with C++20. That
check was simply removed in this version.
[HLSL] Add codegen for accessing resource members of a struct (2nd merge attempt) (#193584)
Any expression that accesses a resource or resource array member of a global struct instance must be during codegen replaced by an access of the corresponding implicit global resource variable.
When codegen encounters a `MemberExpr` of a resource type, it traverses the AST to locate the parent struct declaration, building the expected global resource variable name along the way. If the parent declaration is a non-static global struct instance, codegen searches its `HLSLAssociatedResourceDeclAttr` attributes to locate the matching global resource variable and then generates IR code to access the resource global in place of the member access.
Fixes #182989
This is the second try to land this. The [first one](https://github.com/llvm/llvm-project/pull/187127)collided with #188792 and both PRs had to be reverted. No updates needed to this change. I synced with @inbelic and we agreed
that this one should go in first.
[ConstantRange] Expand makeAllowedICmpRegion to use samesign to give tighter range (#174355)
After the addition of samesign then instcombine correctly transforms
unsigned greater than to use it if it can prove that value is greater
than zero and then removes the assume that allowed it to prove that. For
example:
```
define i8 @remove_for_samesign(i8 %x) {
%gt = icmp sgt i8 %x, 10
call void @llvm.assume(i1 %gt)
%gt.zero = icmp sge i8 %x, 0
call void @llvm.assume(i1 %gt.zero)
ret i8 %x
}
```
Is optimized to:
```
define i8 @remove_for_samesign(i8 %x) {
%gt= icmp samesign ugt i8 [[X:%.*]], 10
[11 lines not shown]
[lldb] Fix flaky TestRunLocker by using lldb.target instead of lldb.frame (#193788)
`lldb.frame` is a Python convenience variable that resolves to `None`
when the process is running (no selected frame), potentially causing an
`AttributeError` before the run locker check is ever reached. Use
`lldb.target` instead, which is always valid and properly exercises the
run locker path.
Fixes #193787
[flang] Support polymorphic types in conditional expressions (#192684)
Add lowering support for polymorphic (`CLASS(T)`) conditional
expressions.
`ConditionalExpr::GetType()` now checks both branches and returns the
polymorphic type if either is polymorphic (F2023 10.1.4(7)). In
lowering, polymorphic conditionals use `fir::ClassType` instead of
`fir::BoxType` for the allocatable temporary so that dynamic type info
is preserved through `hlfir.assign` realloc.
Covers scalar, array, and mixed `TYPE(T)`/`CLASS(T)` operands. Unlimited
polymorphic `CLASS(*)` does not have a declared type, and is therefore
rejected in semantics. LIT tests for lowering and semantics have been
updated.
[InstCombine] Fold neg arg in hyperbolic lib functions (#193586)
Fix #173706 (it is closed but not really fixed).
The previous PR #173730 only addressed the **intrinsics**
`@llvm.sinh.f64` etc, which does not have effects on the C program
compiled without `-fno-math-errno`.
I validated the optimization by `clang -O2`.
Reland "[Lit][NFC] Refactor shell environment functionality and in-process builtins from TestRunner.py into new modules" (#193759)
Fixed version of #177358 which accidentally removed an import.
This is the first in a series of PRs reworking Lit's handling of
in-process builtins to be run as part of command pipelines, and to
enable users to provide new in-process builtins via Lit's configuration.
The full series of patches can be found here:
https://github.com/BStott6/llvm-project/tree/lit-inproc-builtins.
This work is required for the test daemonization project:
https://discourse.llvm.org/t//88612/9
This PR moves the shell environment functionality and existing
in-process builtins from TestRunner.py into new modules. This is
important not just for organizational purposes but also because,
eventually, user defined in-process builtins will need to be able to
import items from these modules, but these cannot import TestRunner as
this would result in a dependency cycle.
[lit] Fix `progress-bar.py` flaky test
The `lit` progress-bar test was checking for exact progress-bar text
like `0.. 10.. 20.. 30.. 40..`, but that output is not stable from run
to run.
The progress bar is based on timing estimates, including saved timings
from earlier runs, so small timing differences can change which numbers
get printed.
That made the test flaky: FileCheck could match the wrong Testing: line
and then fail later, even though the actual test failures were correct.
Relax the test to verify ordering instead of exact progress-bar
contents. The updated checks assert that the test header is printed, that
each failing test result is separated by a Testing: progress-bar line,
and that the final failed-tests summary lists all expected tests in order.
This preserves coverage for the simple progress-bar path while removing
[3 lines not shown]
[RISCV][GlobalISel] Add intial support for inline asm (#193314)
This patch adds the (almost) minimal changes to support inline assembly
in the RISC-V GlobalISel backend.
The tests are mostly from
`llvm/test/CodeGen/AArch64/GlobalISel/irtranslator-inline-asm.ll` but
sadly not all test could be taken. I am planning to address the
remaining tests in later PRs.
The motivation for the PR was a fallback to SelectionDAG when compiling
libc. The motivating case can be seen in the test
`test_input_register_pointer`. That is also the reason for the small
changes in `RISCVInstructionSelector::selectCopy`.
net/teddycloud: Update 0.6.7 => 0.6.8
Changelog:
https://github.com/toniebox-reverse-engineering/teddycloud/releases/tag/tc_v0.6.8
Port changes:
* Replace several source code patch files with CFLAGS instead.
* Replace long paths with DATADIR and ETCDIR instead.
* Pet portlint: remove empty line between *_DEPENDS.
* Convert pkg-message to files/pkg-message.in and fix typo.
PR: 294230
Reported by: Michael Pape <freebsd at pe82.de> (maintainer)
Approved by: vvd (co-mentor)