* mingwex/fesetround.c (fesetround): Use unsigned int as operand
to stmxcsr. Thanks to Alexey Kuznetsov <ring0_mipt at users dot sf dot net>
This commit is contained in:
		| @@ -1,3 +1,9 @@ | ||||
| 2007-03-05  Danny Smith  <dannysmith@users.sourceforge.net> | ||||
|  | ||||
| 	* mingwex/fesetround.c (fesetround): Use unsigned int as operand | ||||
| 	to  stmxcsr. | ||||
| 	Thanks to Alexey Kuznetsov  <ring0_mipt at users dot sf dot net> | ||||
|  | ||||
| 2007-02-27  Thorsten Dahlheimer  <tdahlheim@gmx.net> | ||||
|  | ||||
| 	* include/stdio.h (_unlink, unlink): Add prototypes. | ||||
|   | ||||
| @@ -20,10 +20,11 @@ int fesetround (int mode) | ||||
|  | ||||
|  if (__HAS_SSE) | ||||
|     { | ||||
|       __asm__ volatile ("stmxcsr %0" : "=m" (_cw)); | ||||
|       _cw &= ~ 0x6000; | ||||
|       _cw |= (mode <<  __MXCSR_ROUND_FLAG_SHIFT); | ||||
|       __asm__ volatile ("ldmxcsr %0" : : "m" (_cw)); | ||||
|       unsigned int _mxcsr; | ||||
|       __asm__ volatile ("stmxcsr %0" : "=m" (_mxcsr)); | ||||
|       _mxcsr &= ~ 0x6000; | ||||
|       _mxcsr |= (mode <<  __MXCSR_ROUND_FLAG_SHIFT); | ||||
|       __asm__ volatile ("ldmxcsr %0" : : "m" (_mxcsr)); | ||||
|     } | ||||
|  | ||||
|   return 0; | ||||
|   | ||||
		Reference in New Issue
	
	Block a user