-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Crash in mono debugger. #6299
Comments
@mfilippov how exactly do I do |
@marek-safar We attach over mono soft-debugger API (connect to debugger port) Are you need some additional info? |
@mfilippov instead of accessing your machine, would it be possible to create a repro setup from the crash on your machine? |
We trying to create repro and found one more problem native stack:
|
@mfilippov standalone repro for the crash would be great to speed things up |
@marek-safar Yes, I understand. But we cannot find small repro. We test it on the master branch. But the issue still there. It happened not frequently and always on the step into interface method. Maybe we can enable some logs to understand better what happened? |
There is only connection logging env variable. @vargaz is there anything on runtime side to help to track this down? |
@marek-safar We found the reason for the problem. It is the race condition between threads in methods invalidate_frames and ss_start. I add log for log thread ID and enter and exit function. I attach striped the log file from the moment of entering into ss_start. |
@marek-safar looks on address 0x7feed1aa2c40 in log. It address from log in line mono/mono/mini/debugger-agent.c Line 5656 in 36ad395 |
#6456 Didn't work it code deadlocked.
and
|
@marek-safar Is this info enough to fix? |
@vargaz is this "repro" good enough for you? |
Not really. |
@vargaz Could add add any additional information? I cannot create repro but I have stable local repro in our project. I can add any logs into mono runtime. |
As I cannot reproduce with the steps in bugzilla 58505, this report will help me identify the reported issue if they are the same. Thanks for filing it, @mfilippov |
If you can pass |
@mfilippov if you could try that when you have the time, it would be appreciated |
I think the deadlock may just be due to the fact that I took the debugger lock, and this races with code that takes the loader lock. I think I should have taken the loader lock, that would have kept these two functions from running concurrently. |
@mfilippov I made a locking change to #6456 . If you have an easy reproduction, it would be helpful to see if that fixes the deadlock |
@alexanderkyte Sorry for the long delay. This is the log for crashed debugger session. |
@alexanderkyte Any news about this issue? It is the very painful problem for us. |
@vargaz @alexanderkyte is there anything interesting in the log file? |
Fixes: mono/mono#6299 Fixes: mono/mono#7125 Fixes: mono/mono#9318 Fixes: #1951 Prevent unaligned access errors (mono/mono#9546) MERP fixes.
Steps to Reproduce
Current Behavior
Mono crashed
Expected Behavior
Execute step into
On which platforms did you notice this
[ X] macOS
[ ] Linux
[ ] Windows
Version Used:
mono 5.4.1.5
We compiled the debug version of mono, attach to runtime with VS Code and reproduce crash.
This is screenshot with debuger state in exception time:
Stacktrace
The text was updated successfully, but these errors were encountered: