DECLARE_CODE_SEGMENT()
declare_alignment(2)
-define_c_label(x86_64_fpe_reset_traps)
+define_c_label(x86_64_interface_initialize)
OP(push,q) REG(rbp)
OP(mov,q) TW(REG(rsp),REG(rbp))
OP(sub,q) TW(IMM(8),REG(rsp))
*/
\f
#define ASM_RESET_HOOK i386_reset_hook
-#define FPE_RESET_TRAPS i386_interface_initialize
#define CMPINT_USE_STRUCS 1
int offset = (COMPILER_REGBLOCK_N_FIXED * (sizeof (SCHEME_OBJECT)));
unsigned char * rsi_value = ((unsigned char *) Registers);
- x86_64_fpe_reset_traps ();
+ x86_64_interface_initialize ();
/* These must match machines/x86-64/lapgen.scm */
*/
\f
#define ASM_RESET_HOOK x86_64_reset_hook
-#define FPE_RESET_TRAPS x86_64_fpe_reset_traps
#define CMPINT_USE_STRUCS 1
# define ASM_ENTRY_POINT(name) name
#endif
-extern void ASM_ENTRY_POINT (x86_64_fpe_reset_traps) (void);
+extern void ASM_ENTRY_POINT (x86_64_interface_initialize) (void);
extern void ASM_ENTRY_POINT (within_c_stack) (void (*) (void *), void *);
extern void asm_assignment_trap (void);
#endif
}
+void
+clear_float_exceptions (void)
+{
+#ifdef HAVE_FECLEAREXCEPT
+ (void) feclearexcept (FE_ALL_EXCEPT);
+#endif
+}
+
/* FIXME: Alignment? */
static SCHEME_OBJECT
? (find_signal_name (signo))
: 0)))
\f
-#ifndef FPE_RESET_TRAPS
-# define FPE_RESET_TRAPS()
-#endif
-
#ifdef HAVE_SIGFPE
+extern void clear_float_exceptions (void);
+
static
DEFUN_STD_HANDLER (sighnd_fpe,
{
- FPE_RESET_TRAPS ();
+ clear_float_exceptions ();
trap_handler ("floating-point exception", signo, info, scp);
})
#endif