[AArch64][llvm] Add support for FEAT_HINTE for Armv9.6 onwards (#206905)
Add support for `FEAT_HINTE`, as defined in the Arm ARM M.c edition[1]
This defines the Extended Hint instruction space. `FEAT_HINTE` is
optional from Armv9.0, and mandatory from Armv9.6.
Add MC coverage for assembly, disassembly, diagnostics, generic sysreg
fallback behavior, Clang driver handling, and target parser extension
mapping.
[1] https://developer.arm.com/documentation/ddi0487/latest
[Dexter] Add !type and !type/all nodes to test variable types (#204159)
This patch adds the second kind of variable expect, !type, which tests
the type of a variable as reported by the debugger. As with !value, this
is a string comparison of the debugger output with the script expected
value - this means that even if two types are identical (e.g. typedef),
a !type node will only match the one that the debugger displays by
default.
Script writing and aggregates work the same for !type as for !value, and
the metrics reported are largely similar, with the exception that
"unexpected", "seen", and "missing" metrics are reported separately for
values and types.
[ARM] Change register class of tTAILJUMPr's destination (#206763)
This patch changes the register class of tTAILJUMPr's destination from
tcGPR to GPR.
tTAILJUMPr is lowered into a BX (branch-and-exchange) with a register
operand. This instruction has no restrictions about its register
operand, therefore the previous limitation to tcGPR was too tight.
The important consequence of this change is in the machine outliner for
ARM. With this change, code sequences that terminate with a tBLXr can be
outlined regardless of the register used as operand. Before, if the
register used was callee saved, that is, not in tcGPR, the outliner gave
up. The outlining process replaces the call (BLX) by a tail call (BX).
This replacement can be problematic if the callee saved registers are
not properly restored before the tail call. However, one important
detail to mention is that tTAILJUMPr is created during pseudo
instruction expansion, which in turn takes place after register
[4 lines not shown]
[Dexter] Update lldb-based dexter-tests to use script-mode
This patch replaces uses of heuristic-mode Dexter in the dexter-tests suite
with uses of the script-mode, for tests that use DAP (via lldb-dap). The
updates are largely straightforward but occasionally non-trivial, and in
some cases some slight modifications have been made to keep the "spirit" of
the test intact.
[Dexter] Document the structured script model
This patch adds documentation for the script model to the Dexter README,
shunting heuristic-mode information into a separate doc, creating a new
doc for script-mode, and linking to both (with a brief summary of the
differences) from the base README.
[Dexter] Switch to using script-mode by default
This patch changes the default mode of Dexter from heuristic-mode to
script-mode. The --use-script argument is replaced with --use-heuristic,
some comments/docs/error messages are updated accordingly, and tests have
their flags switched accordingly.
[Dexter] Add !type and !type/all nodes to test variable types
This patch adds the second kind of variable expect, !type, which tests the
type of a variable as reported by the debugger. As with !value, this is a
string comparison of the debugger output with the script expected value -
this means that even if two types are identical (e.g. typedef), a !type node
will only match the one that the debugger displays by default.
Script writing and aggregates work the same for !type as for !value, and the
metrics reported are largely similar, with the exception that "unexpected",
"seen", and "missing" metrics are reported separately for values and types.
[Dexter] Add ability to check float values within a range
Adds a new node type, !float, which can be used to match debugger ouptut as
float values rather than as strings, optionally allowing a range to be
specified for inexact matches. This new node allows a list of values to be
given, effectively a shorthand for a list of individual !float nodes.
[Dexter] Allow matching lists of values for aggregate members
This patch slightly extends the matching of aggregate members to allow for
lists of expected values for individual members, functioning the same as
lists of expected values for scalar values.
[libc++][test] Cover byteswap _BitInt padding on every ABI with width 72 (#206360)
`std::byteswap` is required to reject integer types that have padding
bits, and one test case checks that it does. The case used `unsigned
_BitInt(96)`, but #205295 had to skip it on 32-bit x86. On the i386
System V ABI, `_BitInt(96)` is exactly 12 bytes with no padding, so
`std::byteswap` accepts it and the expected error never fires. The skip
used `!defined(__i386__)`, a target name that stands in for an object
layout the preprocessor cannot see.
This change uses `unsigned _BitInt(72)` instead. Its 9 value bytes round
up to 12 bytes on 32-bit x86 and 16 bytes everywhere else, so the type
always has padding and `std::byteswap` always rejects it. The case now
runs on every target, 32-bit x86 included, with no target guard.
Follows up on #205295.
Assisted-by: Claude (Anthropic)
[3 lines not shown]
[lldb][Windows] Return EOF from PipeWindows::Read on a closed write end (#207017)
A closed pipe write end is EOF, not an error. On POSIX, `read()` returns
0, but on Windows `ReadFile` fails with `ERROR_BROKEN_PIPE`. The
lldb-server `gdbserver/platform` pipe synchronization in
`GDBRemoteCommunication::StartDebugserverProcess` reads the pipe until
EOF, so without this it sees an error instead of EOF and reports the
sync as failed.
Translate both broken-pipe conditions to a zero-length read so
cross-platform callers can detect EOF uniformly.
rdar://180736036
[LV] Inline llvm-lit DEFINEs in interleaved-cost.ll NFC (#207143)
Turns out update_analyze_test_checks.py doesn't really like the
DEFINEs, which causes some subsequent updates to have CHECK lines
erroneously merged.
Reapply "[libc++] Optimize fstream::read" (#206453)
This was reverted due to causing crashes if an ifstream wasn't opened.
This patch addresses this issue by simply checking whether the `__file_`
handle is null, and if it is simply fall back to the generic
implementation.
Fixes #168628
Fixes #205845
This reverts commit 347512ff38748ac6ebfacbfda172edb5cf1edbe2.