From 8a5b89a3adf30b4e0d2fdf7953384634b3648805 Mon Sep 17 00:00:00 2001 From: burnus Date: Wed, 11 Dec 2013 19:50:56 +0000 Subject: [PATCH] 2013-12-11 Tobias Burnus * config/fpu-387.h (sigill_hdlr, get_fpu_rounding_mode): Emit * SSE instructions when __SSE_MATH__ is defined. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@205903 138bc75d-0d04-0410-961f-82ee72b054a4 --- libgfortran/ChangeLog | 5 +++++ libgfortran/config/fpu-387.h | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/libgfortran/ChangeLog b/libgfortran/ChangeLog index 02524ad..ec2be14 100644 --- a/libgfortran/ChangeLog +++ b/libgfortran/ChangeLog @@ -1,3 +1,8 @@ +2013-12-11 Tobias Burnus + + * config/fpu-387.h (sigill_hdlr, get_fpu_rounding_mode): Emit SSE + instructions when __SSE_MATH__ is defined. + 2013-12-06 Rainer Orth * intrinsics/erfc_scaled.c (_M_2_SQRTPI): Define if missing. diff --git a/libgfortran/config/fpu-387.h b/libgfortran/config/fpu-387.h index b35c315..0317ef1 100644 --- a/libgfortran/config/fpu-387.h +++ b/libgfortran/config/fpu-387.h @@ -23,7 +23,7 @@ a copy of the GCC Runtime Library Exception along with this program; see the files COPYING3 and COPYING.RUNTIME respectively. If not, see . */ -#ifndef __x86_64__ +#ifndef __SSE_MATH__ #include "cpuid.h" #endif @@ -50,7 +50,7 @@ sigill_hdlr (int sig __attribute((unused)), static int has_sse (void) { -#ifndef __x86_64__ +#ifndef __SSE_MATH__ unsigned int eax, ebx, ecx, edx; if (!__get_cpuid (1, &eax, &ebx, &ecx, &edx)) @@ -227,7 +227,7 @@ get_fpu_rounding_mode (void) { int round_mode; -#ifdef __x86_64__ +#ifdef __SSE_MATH__ unsigned int cw; __asm__ __volatile__ ("%vstmxcsr\t%0" : "=m" (cw)); -- 2.7.4