mirror of
https://github.com/tobast/libunwind-eh_elf.git
synced 2025-01-22 08:10:30 +01:00
Add new Platform-specific Notes section and document that getcontext()
can be used in lieu of unw_getcontext() but not vice versa. (Logical change 1.196)
This commit is contained in:
parent
e0f02d4775
commit
37e20822f4
1 changed files with 11 additions and 0 deletions
|
@ -26,6 +26,17 @@ stack-pointer, will be stored.
|
|||
This routine is normally implemented as a macro and applications
|
||||
should not attempt to take its address.
|
||||
|
||||
\section{Platform-specific Notes}
|
||||
|
||||
On IA-64, \Type{unw\_context\_t} has a layout that is compatible with
|
||||
that of \Type{ucontext\_t} and such structures can be initialized with
|
||||
\Func{getcontext}() instead of \Func{unw\_getcontext}(). However, the
|
||||
reverse is \emph{not} true and it is \emph{not} safe to use structures
|
||||
initialized by \Func{unw\_getcontext()} in places where a structure
|
||||
initialized by \Func{getcontext()} is expected. The reason for this
|
||||
asymmetry is that \Func{unw\_getcontext()} is optimized for maximum
|
||||
performance and does not, for example, save the signal mask.
|
||||
|
||||
\section{Return Value}
|
||||
|
||||
On successful completion, \Func{unw\_getcontext}() returns 0.
|
||||
|
|
Loading…
Reference in a new issue