-
Notifications
You must be signed in to change notification settings - Fork 816
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 WallClock::getThreadState #862
Comments
Yes, please provide the registers section and the memory map (Dynamic libraries) from hs_err. |
|
Happy to share hs_err file privately. What email should I use? |
support at profiler . tools Has the error happened just once or multiple times? |
Sent to email. I have seen 2 failures due to async-profiler. However I am not sure that second one is caused by same issue and I don't have any details anymore |
The crash looks weird to me: in the signal handler, |
Thanks for looking into this. I'll look into upgrading dependencies, but it will take long time
Feel free to close issue if you believe that it's not caused by async-profiler |
Yeah, the crash happened when async-profiler tried to access an instruction at the address obtained here: async-profiler/src/wallClock.cpp Line 41 in 62c1a79
pc address is passed to a signal handler from outside. Normally, it always points to a valid instruction, but here pc = 0x423, that suggests some external bug. I just thought of another (although unlikely) hypothesis: for instance, some third-party library uses the same signal as async-profiler (SIGVTALRM), but does not do signal chaining properly. If this is the case, you may configure async-profiler to use a different signal, see #759. I'll close the issue for now. Please update, if the bug happens again. We'll see if there is a common pattern. |
Hmm.. Your guess about signal handler seems possible. Thanks for the help!!! |
Update: Unexpected moment: it impacts only wall profiler. I am not able to reproduce issue with |
Thank you for the update. So it looks like OpenOnload indeed uses SIGVTALRM for its own purpose, but does not care about signal chaining. CPU profiling works with a different signal - SIGPROF. Did you you try to configure an alternative profiling signal? E.g. to use SIGPROF for wall clock profiling, run |
Would it work with multi event profiling? So far it seems to not fail, so workaround works I am trying to do (collect wall and alloc together): |
If you want to profile cpu+wall together, you'll need two different signals. Something like As a side note, there are multiple issues with your asprof command:
|
Thanks! I appreciate response. We pin threads to cores, so I'd expect that number of threads is not much larger than number of cores (300us is used trying reproduce issue above) |
Yes, looks good. |
Async profiler caused a crash of JVM
Async profieler is provided via ap-loader:
me.bechberger:ap-loader:2.9-2-all
Java: 21.0.1+12
Thread stack:
I can provide additional debug information from hs_err_pid file if needed
The text was updated successfully, but these errors were encountered: