-
Notifications
You must be signed in to change notification settings - Fork 4
Crash at runtime if a signal is encountered (for now). #75
Comments
I am not quite sure what this issue is about @vext01. |
I think this is referring to potential problems if a signal interrupts execution while we have PT turned on. I think Edd came up with a fix for that (maybe we just ignored the resulting trace? I don't remember!) but I might be wrong. |
I think a user setting a signal handler is even more rare than using |
I have a Rust program which sets signals :) Also, user programs in the languages implemented in yk may set signals (doing so is semi-common in Python). But "handling" it can simply mean "throw away any PT trace which was interrupted by a signal." |
I'm using signals and windows exceptions to implement GC safepoints and all it is in Rust. I don't think it is a good idea to interrupt trace when it is just GC safepoint? |
If we record a trace and that thread happens to enter GC mode as the result of a signal, we probably do want to throw the trace away (unless it's an explicit call to the GC, but that wouldn't be the result of a signal). However, we're currently doing a fairly hefty reorganisation of yk/ykrustc so this detail might change (though probably not I suspect). |
@ltratt What if this wasn't entering GC cycle but signal happened because thread had to suspend for GC to run in another thread? |
Isn't that the same thing? |
Suspending a thread to wait for GC to finish is simple spin loop while GC cycle is not. |
See: ykjit/ykdocs#4
The text was updated successfully, but these errors were encountered: