<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/lldb/test/API/api/multithreaded/TestMultithreaded.py, branch main</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/'/>
<entry>
<title>Convert the StackFrameList mutex to a shared mutex. (#117252)</title>
<updated>2024-12-12T20:48:41+00:00</updated>
<author>
<name>jimingham</name>
<email>jingham@apple.com</email>
</author>
<published>2024-12-12T20:48:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=186fac33d08b34be494caa58fe63972f69c6d6ab'/>
<id>186fac33d08b34be494caa58fe63972f69c6d6ab</id>
<content type='text'>
In fact, there's only one public API in StackFrameList that changes
 the list explicitly.  The rest only change the list if you happen to
ask for more frames than lldb has currently fetched and that 
always adds frames "behind the user's back".  So we were
much more prone to deadlocking than we needed to be.

This patch uses a shared_mutex instead, and when we have to add more
frames (in GetFramesUpTo) we switches to exclusive long enough to add
the frames, then goes back to shared.
    
Most of the work here was actually getting the stack frame list locking
to not
require a recursive mutex (shared mutexes aren't recursive). 
    
I also added a test that has 5 threads progressively asking for more
frames simultaneously to make sure we get back valid frames and don't
deadlock.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In fact, there's only one public API in StackFrameList that changes
 the list explicitly.  The rest only change the list if you happen to
ask for more frames than lldb has currently fetched and that 
always adds frames "behind the user's back".  So we were
much more prone to deadlocking than we needed to be.

This patch uses a shared_mutex instead, and when we have to add more
frames (in GetFramesUpTo) we switches to exclusive long enough to add
the frames, then goes back to shared.
    
Most of the work here was actually getting the stack frame list locking
to not
require a recursive mutex (shared mutexes aren't recursive). 
    
I also added a test that has 5 threads progressively asking for more
frames simultaneously to make sure we get back valid frames and don't
deadlock.</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb] Don't overwrite the dynamic loader library path for "driver tests"</title>
<updated>2024-02-16T16:47:38+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2024-02-16T16:16:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=0da0966da4b813386a85cf70ae0d0efc7cb2eaea'/>
<id>0da0966da4b813386a85cf70ae0d0efc7cb2eaea</id>
<content type='text'>
We have a handful of tests that build a driver which links against LLDB.
When running those binaries, we overwrite the dynamic loader library
path to point to the build directory's libs dir, presumably to make sure
we load LLDB from there.

This above becomes an issue when you have libc++ enabled and the driver
is linked against the system's libc++, but the dynamic loader flag
forces it to pick up libc++ from the libs dir.

We could try to make the logic for building the driver smarter and have
it pick up the just-built libc++ like we do for our test binaries, but I
don't think we need to overwrite the library path in the first place.
The build logic to build these drivers already takes care to set the
correct RPATH in the linker.

This patch removes the logic and simplifies the tests.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We have a handful of tests that build a driver which links against LLDB.
When running those binaries, we overwrite the dynamic loader library
path to point to the build directory's libs dir, presumably to make sure
we load LLDB from there.

This above becomes an issue when you have libc++ enabled and the driver
is linked against the system's libc++, but the dynamic loader flag
forces it to pick up libc++ from the libs dir.

We could try to make the logic for building the driver smarter and have
it pick up the just-built libc++ like we do for our test binaries, but I
don't think we need to overwrite the library path in the first place.
The build logic to build these drivers already takes care to set the
correct RPATH in the linker.

This patch removes the logic and simplifies the tests.
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb] Fix and rename skipIfHostIncompatibleWithRemote</title>
<updated>2024-02-16T15:59:03+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2024-02-16T07:43:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=bf93f4b85fd4efbd7a3083935a2ddbbb00f1a35f'/>
<id>bf93f4b85fd4efbd7a3083935a2ddbbb00f1a35f</id>
<content type='text'>
Fix and rename the broken and confusingly named decorator
skipIfHostIncompatibleWithRemote. The decorator is meant to skip test
which uses the inferior test build system (i.e. to build test inferiors)
to build host binaries (e.g. lldb drivers).

The decorator was broken on macOS, where the host and target platform
report macosx, but the decorator overwrote it with Darwin, resulting in
tests incorrectly being skipped.

The decorator was also missing on a handful of tests that use the
buildDriver helper, which this commit fixes as well.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix and rename the broken and confusingly named decorator
skipIfHostIncompatibleWithRemote. The decorator is meant to skip test
which uses the inferior test build system (i.e. to build test inferiors)
to build host binaries (e.g. lldb drivers).

The decorator was broken on macOS, where the host and target platform
report macosx, but the decorator overwrote it with Darwin, resulting in
tests incorrectly being skipped.

The decorator was also missing on a handful of tests that use the
buildDriver helper, which this commit fixes as well.
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb] Remove obsolete signBinary helper (#79656)</title>
<updated>2024-01-27T04:37:44+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2024-01-27T04:37:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=75952873036fc9989fcf12c526d1a2deaeef596a'/>
<id>75952873036fc9989fcf12c526d1a2deaeef596a</id>
<content type='text'>
On Darwin, the Makefile already (ad-hoc) signs everything it builds.
There's also no need to use lldb_codesign for this.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
On Darwin, the Makefile already (ad-hoc) signs everything it builds.
There's also no need to use lldb_codesign for this.</pre>
</div>
</content>
</entry>
<entry>
<title>[NFC][Py Reformat] Reformat python files in lldb</title>
<updated>2023-05-25T19:54:09+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2023-05-25T15:48:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=2238dcc39358353cac21df75c3c3286ab20b8f53'/>
<id>2238dcc39358353cac21df75c3c3286ab20b8f53</id>
<content type='text'>
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 &lt;yourfile&gt;` 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
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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 &lt;yourfile&gt;` 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
</pre>
</div>
</content>
</entry>
<entry>
<title>[test] Allow skipTestIfFn to apply to entire classes for skipIfNoSBHeaders</title>
<updated>2022-11-17T16:17:10+00:00</updated>
<author>
<name>Jordan Rupprecht</name>
<email>rupprecht@google.com</email>
</author>
<published>2022-11-17T16:17:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=8be41c787f9e12a4eb101e2dcad67ddc2da7ec1f'/>
<id>8be41c787f9e12a4eb101e2dcad67ddc2da7ec1f</id>
<content type='text'>
Some test cases are already marked @skipIfNoSBHeaders, but they make use of SBAPI headers in test setup. The setup will fail if the headers are missing, so it is too late to wait until the test case to apply the skip annotation.

In addition to allowing this to apply to entire classes, I also changed all the existing annotations from test cases to test classes where necessary/appropriate.

Reviewed By: DavidSpickett

Differential Revision: https://reviews.llvm.org/D138181
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some test cases are already marked @skipIfNoSBHeaders, but they make use of SBAPI headers in test setup. The setup will fail if the headers are missing, so it is too late to wait until the test case to apply the skip annotation.

In addition to allowing this to apply to entire classes, I also changed all the existing annotations from test cases to test classes where necessary/appropriate.

Reviewed By: DavidSpickett

Differential Revision: https://reviews.llvm.org/D138181
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb] Add SBBreakpointLocation::SetCallback</title>
<updated>2022-09-12T17:44:02+00:00</updated>
<author>
<name>Laura Chaparro-Gutierrez</name>
<email>lauralcg@google.com</email>
</author>
<published>2022-09-12T15:39:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=6f5d109fca23056dd74d673d2e3439ece22c80b4'/>
<id>6f5d109fca23056dd74d673d2e3439ece22c80b4</id>
<content type='text'>
* Include SetCallback in SBBreakpointLocation, similar as in SBBreakpoint.
* Add test_breakpoint_location_callback test as part of TestMultithreaded.

Reviewed By: werat, JDevlieghere

Differential Revision: https://reviews.llvm.org/D133689

Co-authored-by: Andy Yankovsky &lt;weratt@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Include SetCallback in SBBreakpointLocation, similar as in SBBreakpoint.
* Add test_breakpoint_location_callback test as part of TestMultithreaded.

Reviewed By: werat, JDevlieghere

Differential Revision: https://reviews.llvm.org/D133689

Co-authored-by: Andy Yankovsky &lt;weratt@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[LLDB] Remove __future__ imports from tests</title>
<updated>2022-08-15T08:54:06+00:00</updated>
<author>
<name>David Spickett</name>
<email>david.spickett@linaro.org</email>
</author>
<published>2022-08-12T10:56:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=193259cbcec77add8e189c4dedeefb15fef50d5e'/>
<id>193259cbcec77add8e189c4dedeefb15fef50d5e</id>
<content type='text'>
Not needed now that we require python 3.

Reviewed By: kastiglione, JDevlieghere

Differential Revision: https://reviews.llvm.org/D131761
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Not needed now that we require python 3.

Reviewed By: kastiglione, JDevlieghere

Differential Revision: https://reviews.llvm.org/D131761
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb][tests] Automatically call compute_mydir (NFC)</title>
<updated>2022-06-17T21:34:49+00:00</updated>
<author>
<name>Dave Lee</name>
<email>davelee.com@gmail.com</email>
</author>
<published>2022-06-17T00:38:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=4cc8f2a017c76af25234afc7c380550e9c93135c'/>
<id>4cc8f2a017c76af25234afc7c380550e9c93135c</id>
<content type='text'>
Eliminate boilerplate of having each test manually assign to `mydir` by calling
`compute_mydir` in lldbtest.py.

Differential Revision: https://reviews.llvm.org/D128077
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Eliminate boilerplate of having each test manually assign to `mydir` by calling
`compute_mydir` in lldbtest.py.

Differential Revision: https://reviews.llvm.org/D128077
</pre>
</div>
</content>
</entry>
<entry>
<title>[lldb] Update TestMultithreaded to report FAIL for a non-zero exit code</title>
<updated>2022-06-08T15:58:15+00:00</updated>
<author>
<name>Jonas Devlieghere</name>
<email>jonas@devlieghere.com</email>
</author>
<published>2022-06-08T15:45:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=37028d3ea7fc9fa7e640c91faa9c347808598dd6'/>
<id>37028d3ea7fc9fa7e640c91faa9c347808598dd6</id>
<content type='text'>
A non-zero exit code from the test binary results in a
CalledProcessError. Without catching the exception, that would result in
a error (unresolved test) instead of a failure. This patch fixes that.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
A non-zero exit code from the test binary results in a
CalledProcessError. Without catching the exception, that would result in
a error (unresolved test) instead of a failure. This patch fixes that.
</pre>
</div>
</content>
</entry>
</feed>
