bug-glibc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

mxcsr and ucontext_t on x86 GNU/Linux


From: Drew Hess
Subject: mxcsr and ucontext_t on x86 GNU/Linux
Date: Mon, 12 Jan 2004 14:46:08 -0800 (PST)

Hi,

How does one access the saved state of the mxcsr register in a signal
handler on x86 GNU/Linux?  The _libc_fpstate struct in
/usr/include/sys/ucontext.h doesn't include that register (not in GNU libc
2.3.2, at least), even though the kernel's own _fpstate struct does on
recent kernels.

If no other alternative exists, is it safe to #include <asm/sigcontext.h>
and typecast the libc fpregset_t to an _fpstate so that I can access the
mxcsr?  It's ugly, but the code where I need to do this stuff is already
doing some pretty platform-specific things anyway, like using the
_SET_FPUCW macros from GNU libc.


thanks
-dwh-







reply via email to

[Prev in Thread] Current Thread [Next in Thread]