From owner-freebsd-hackers Sun Apr 30 6:46:27 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from kweetal.tue.nl (kweetal.tue.nl [131.155.2.7]) by hub.freebsd.org (Postfix) with ESMTP id 3443637BCBA for ; Sun, 30 Apr 2000 06:46:23 -0700 (PDT) (envelope-from marcov@toad.stack.nl) Received: from hermes.tue.nl [131.155.2.46] by kweetal.tue.nl (8.9.3) for id PAA29422 (ESMTP); Sun, 30 Apr 2000 15:46:20 +0200 (MDT) Received: from deathstar (n170.dial.tue.nl [131.155.209.169]) by hermes.tue.nl (Postfix) with ESMTP id C29D82E806 for ; Sun, 30 Apr 2000 15:46:19 +0200 (CEST) From: "Marco van de Voort" To: hackers@freebsd.org Date: Sun, 30 Apr 2000 15:46:27 +0100 Subject: fp statusword in sigcontext X-mailer: Pegasus Mail for Win32 (v3.12b) Message-Id: <20000430134619.C29D82E806@hermes.tue.nl> Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I want a signalhandler, which splits out sigfpe to the different copro signals. I found a linux example, which is based on the statusword field of the sigcontext structure passed to the signalhandler set Problem is that the linux sigcontext has a field for the floatingpoint statusword, while the BSD sigcontext (machine/signal.h) has only two arrays of int's: (FPU part struct sigcontext * XXX FPU state is 27 * 4 bytes h/w, 1 * 4 bytes s/w (probably not * needed here), or that + 16 * 4 bytes for emulators (probably all * needed here). The "spare" bytes are mostly not spare. */ int sc_fpregs[28]; /* machine state (FPU): */ int sc_spare[17]; }; Does somebody know how to distille the FP statusword from this struct? Marco van de Voort (MarcoV@Stack.nl) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message