summaryrefslogtreecommitdiff
path: root/lldb/test/API/tools/lldb-server/memory-allocation/TestGdbRemoteMemoryAllocation.py
AgeCommit message (Collapse)Author
2023-05-25[NFC][Py Reformat] Reformat python files in lldbJonas Devlieghere
This is an ongoing series of commits that are reformatting our Python code. Reformatting is done with `black` (23.1.0). If you end up having problems merging this commit because you have made changes to a python file, the best way to handle that is to run `git checkout --ours <yourfile>` and then reformat it with black. RFC: https://discourse.llvm.org/t/rfc-document-and-standardize-python-code-style Differential revision: https://reviews.llvm.org/D151460
2022-06-17[lldb][tests] Automatically call compute_mydir (NFC)Dave Lee
Eliminate boilerplate of having each test manually assign to `mydir` by calling `compute_mydir` in lldbtest.py. Differential Revision: https://reviews.llvm.org/D128077
2022-02-07[lldb] Skip part of TestGdbRemoteMemoryAllocation.py on Apple SiliconJonas Devlieghere
Skip the part of TestGdbRemoteMemoryAllocation.py that attempts to allocate both writable and executable memory.
2021-01-06[lldb] Simplify some lldb-server testsPavel Labath
Remove manual test duplication.
2020-12-18[lldb/test] Reduce boilerplate in lldb-server testsPavel Labath
Nearly all of our lldb-server tests have two flavours (lldb-server and debugserver). Each of them is tagged with an appropriate decorator, and each of them starts with a call to a matching "init" method. The init calls are mandatory, and it's not possible to meaningfully combine them with a different decorator. This patch leverages the existing decorators to also tag the tests with the appropriate debug server tag, similar to how we do with debug info flavours. This allows us to make the "init" calls from inside the common setUp method.
2020-10-14[lldb] More memory allocation test fixesPavel Labath
XFAIL nodefaultlib.cpp on darwin - the test does not pass there XFAIL TestGdbRemoteMemoryAllocation on windows - memory is allocated with incorrect permissions
2020-10-14[lldb] Fix TestGdbRemoteMemoryAllocation on windowsPavel Labath
It appears that memory allocation actually works on windows (but it was not fully wired up before 2c4226f8).
2020-10-14[lldb-server][linux] Add ability to allocate memoryPavel Labath
This patch adds support for the _M and _m gdb-remote packets, which (de)allocate memory in the inferior. This works by "injecting" a m(un)map syscall into the inferior. This consists of: - finding an executable page of memory - writing the syscall opcode to it - setting up registers according to the os syscall convention - single stepping over the syscall The advantage of this approach over calling the mmap function is that this works even in case the mmap function is buggy or unavailable. The disadvantage is it is more platform-dependent, which is why this patch only works on X86 (_32 and _64) right now. Adding support for other linux architectures should be easy and consist of defining the appropriate syscall constants. Adding support for other OSes depends on the its ability to do a similar trick. Differential Revision: https://reviews.llvm.org/D89124