-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Labels
A-runtimeArea: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflowsArea: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflowsC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.O-windowsOperating system: WindowsOperating system: WindowsT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.
Description
libpanic_abort currently uses Rust's abort intrinsic for aborts (which uses an illegal opcode to abort the process). This directly contrasts with libstd which uses inline assembly to call into Windows __failfail intrinsic. This is preferred because __fastfail allows for debuggers to attach after the process has aborted for debugging.
Perhaps we should use the same abort implementation used in libstd for libpanic_abort.
Drawbacks
Before Windows 8 __fastfail wasn't available and so calling into it on this platforms leads to an access violation. Access violations are not catchable by normal exception handlers but are catchable by [SEH}(https://docs.microsoft.com/en-us/windows/win32/debug/structured-exception-handling)
seritools
Metadata
Metadata
Assignees
Labels
A-runtimeArea: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflowsArea: std's runtime and "pre-main" init for handling backtraces, unwinds, stack overflowsC-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.O-windowsOperating system: WindowsOperating system: WindowsT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.