Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thread states not properly maintained on Windows #25034

Open
llvmbot opened this issue Sep 1, 2015 · 2 comments
Open

Thread states not properly maintained on Windows #25034

llvmbot opened this issue Sep 1, 2015 · 2 comments
Labels
bugzilla Issues migrated from bugzilla lldb

Comments

@llvmbot
Copy link
Collaborator

llvmbot commented Sep 1, 2015

Bugzilla Link 24660
Version unspecified
OS Windows NT
Blocks #22140
Reporter LLVM Bugzilla Contributor

Extended Description

The following tests are failing:

TestThreadStates.ThreadStateTestCase.test_state_after_continue_with_dwarf
TestThreadStates.ThreadStateTestCase.test_state_after_expression_with_dwarf

with the following stack trace:

FAIL

<bound method SBProcess.Kill of <lldb.SBProcess; proxy of <Swig Object of type 'lldb::SBProcess *' at 0x02B74D18> >>: success

Traceback (most recent call last):
File "D:\src\llvm\tools\lldb\test\lldbtest.py", line 551, in wrapper
return func(self, *args, **kwargs)
File "D:\src\llvm\tools\lldb\test\lldbtest.py", line 615, in wrapper
func(*args, **kwargs)
File "D:\src\llvm\tools\lldb\test\functionalities\thread\state\TestThreadStates.py", line 45, in test_state_after_continue_with_dwarf
self.thread_state_after_continue_test()
File "D:\src\llvm\tools\lldb\test\functionalities\thread\state\TestThreadStates.py", line 181, in thread_state_after_continue_test
self.assertFalse(thread.IsStopped(), "Thread state is 'stopped' when it should be running.")
AssertionError: True is not False : Thread state is 'stopped' when it should be running.

@llvmbot
Copy link
Collaborator Author

llvmbot commented Sep 3, 2015

This sounds awfully similar to something I hit when proving out the llgs work and testing vs. OS X. At the time last year, OS X was not guaranteeing thread state info reliability at the SB level, which I think I had working for Linux, but was then getting diverging results on tests that checked thread state at certain points.

What I'm not remembering is if it really was a OS-related issue or a propagation issue on the lldb infrastructure side. (I seem to think Linux could get it right because we were moving to a thread state coordinator state machine that always knew the state of threads, whereas on OS X I think it was query based and the state wasn't automatically known? Something like that). If we end up having multiple OSes (possibly Windows) that have trouble with that, we might want to rethink how (if?) we expose it, or if we can just fix it, do that.

@llvmbot
Copy link
Collaborator Author

llvmbot commented Sep 3, 2015

Yea I've seen a lot of tests that are xfailed with comments saying "thread states are not properly maintained". So it sounds like, even if we can get this working on Windows, there's some underlying issue that would be great to fix on the LLDB side. I didn't investigate this long enough to come to a conclusion about what the problem might be on the Windows side, because right now I'm just trying to get down to a clean run of the test suite. I suspect there's at least some improvements we could make on the Windows side, but it's very possible that a more comprehensive fix is needed.

@llvmbot llvmbot transferred this issue from llvm/llvm-bugzilla-archive Dec 10, 2021
DavidSpickett added a commit that referenced this issue Feb 26, 2024
No idea why but this is now passing (though if it randomly fails
I won't be surprised).

See #25034 for background
on the original expected fail.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugzilla Issues migrated from bugzilla lldb
Projects
None yet
Development

No branches or pull requests

1 participant