Skip to content

Commit a15f160

Browse files
committed
Don't mess with floating-point control word on SSE architectures
1 parent 4f47ba9 commit a15f160

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Zend/zend_float.c

+4-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
ZEND_API void zend_init_fpu(void) /* {{{ */
2424
{
25-
#if XPFPA_HAVE_CW
25+
#if XPFPA_HAVE_CW && !defined(__SSE__)
2626
XPFPA_DECLARE
2727

2828
if (!EG(saved_fpu_cw_ptr)) {
@@ -38,7 +38,7 @@ ZEND_API void zend_init_fpu(void) /* {{{ */
3838

3939
ZEND_API void zend_shutdown_fpu(void) /* {{{ */
4040
{
41-
#if XPFPA_HAVE_CW
41+
#if XPFPA_HAVE_CW && !defined(__SSE__)
4242
if (EG(saved_fpu_cw_ptr)) {
4343
XPFPA_RESTORE_CW(EG(saved_fpu_cw_ptr));
4444
}
@@ -49,8 +49,10 @@ ZEND_API void zend_shutdown_fpu(void) /* {{{ */
4949

5050
ZEND_API void zend_ensure_fpu_mode(void) /* {{{ */
5151
{
52+
#ifndef __SSE__
5253
XPFPA_DECLARE
5354

5455
XPFPA_SWITCH_DOUBLE();
56+
#endif
5557
}
5658
/* }}} */

0 commit comments

Comments
 (0)