JJonas Devlieghere[NFC][Py Reformat] Reformat python files in lldb
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
[lldb][test] Remove symlink for API tests. Summary: Moves lldbsuite tests to lldb/test/API. This is a largely mechanical change, moved with the following steps: rm lldb/test/API/testcases mkdir -p lldb/test/API/{test_runner/test,tools/lldb-{server,vscode}} mv lldb/packages/Python/lldbsuite/test/test_runner/test lldb/test/API/test_runner for d in $(find lldb/packages/Python/lldbsuite/test/* -maxdepth 0 -type d | egrep -v "make|plugins|test_runner|tools"); do mv $d lldb/test/API; done for d in $(find lldb/packages/Python/lldbsuite/test/tools/lldb-vscode -maxdepth 1 -mindepth 1 | grep -v ".py"); do mv $d lldb/test/API/tools/lldb-vscode; done for d in $(find lldb/packages/Python/lldbsuite/test/tools/lldb-server -maxdepth 1 -mindepth 1 | egrep -v "gdbremote_testcase.py|lldbgdbserverutils.py|socket_packet_pump.py"); do mv $d lldb/test/API/tools/lldb-server; done lldb/packages/Python/lldbsuite/__init__.py and lldb/test/API/lit.cfg.py were also updated with the new directory structure. Reviewers: labath, JDevlieghere Tags: #lldb Differential Revision: https://reviews.llvm.org/D71151 | 6 年前 | |
[NFC][Py Reformat] Reformat python files in lldb 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 | 3 年前 | |
[lldb] [test] Extend watchpoint test to wait for thread to start TestWatchpointMultipleThreads currently accounts for two scenarios: setting the watchpoint before a new thread starts (presumably, verifying that it will be propagated to the new thread) and setting it after the thread starts (presumably, verifying that a new watchpoint is set on all threads). However, the latter test currently assumes that the thread will be reported to the debugger before the breakpoint is hit. This is not the case on FreeBSD and NetBSD. On NetBSD, new threads do not inherit debug registers from their parent threads. Instead, LLDB copies them manually after the new thread is reported. Since the thread is actually reported after the second breakpoint location, both tests effectively check the same behavior (i.e. watchpoint being set before the new thread is reported). On FreeBSD, new threads inherit debug registers and we seem to hit an interesting race condition. While the thread is reported after the breakpoint is hit, the kernel seems to construct it and copy the debug register before that happens. As a result, setting the watchpoint at the second breakpoint location modifies the debug registers of the first thread after they have been copied to the second thread but before the debugger is aware of it. Therefore, the watchpoint is not propagated to the second thread and the test fails. Extend the test to cover all three possible scenarios: setting watchpoint before the thread is lanched, after it is launched but before it is guaranteed to have started and after it has actually started. Add a second barrier to account for the last case. This should ensure that the second assumption (i.e. that the watchpoint is set on all currently known threads) is actually tested on FreeBSD and NetBSD. Differential Revision: https://reviews.llvm.org/D91030 | 5 年前 |