- 23 2月, 2014 2 次提交
- 10 2月, 2014 2 次提交
-
-
由 Szabolcs Nagy 提交于
-
由 Szabolcs Nagy 提交于
the default fenv was not set up properly, in particular the tag word that indicates the contents of the x87 registers was set to 0 (used) instead of 0xffff (empty) this could cause random crashes after setting the default fenv because it corrupted the fpu stack and then any float computation gives NaN result breaking the program logic (usually after a float to integer conversion).
-
- 29 10月, 2013 1 次提交
-
-
由 Szabolcs Nagy 提交于
i386 fenv code checks __hwcap for sse support, but in fesetround the sse code was unconditionally jumped over after the test so the sse rounding mode was never set.
-
- 28 8月, 2013 1 次提交
-
-
由 Rich Felker 提交于
there is no non-dot version of the andis instruction, but there's no harm in updating the flags anyway, so just use the dot version.
-
- 19 8月, 2013 4 次提交
-
-
由 Szabolcs Nagy 提交于
fesetround.c is a wrapper to do the arch independent argument check (on archs where rounding mode is not stored in 2 bits __fesetround still has to check its arguments) on powerpc fe*except functions do not accept the extra invalid flags of its fpscr register the useless FENV_ACCESS pragma was removed from feupdateenv
-
由 Szabolcs Nagy 提交于
the x87 exception summary (ES) and stack fault (SF) flags may be spuriously cleared by feclearexcept using the fnclex instruction, but these flags are not observable through libc hence maintaining their state is not critical.
-
由 Szabolcs Nagy 提交于
the sse and x87 rounding modes should be always the same, the visible exception flags are the bitwise or of the two fenv states (so it's enough to query the rounding mode or raise exceptions on one fenv)
-
由 Szabolcs Nagy 提交于
-
- 17 8月, 2013 1 次提交
-
-
由 Rich Felker 提交于
patch by nsz. I've tested it on an armhf machine and it seems to be working correctly.
-
- 19 11月, 2012 2 次提交
-
-
由 Rich Felker 提交于
based on code sent to the mailing list by nsz, with minor changes.
-
由 Rich Felker 提交于
-
- 14 11月, 2012 1 次提交
-
-
由 Szabolcs Nagy 提交于
-
- 13 11月, 2012 1 次提交
-
-
由 Szabolcs Nagy 提交于
-
- 19 10月, 2012 1 次提交
-
-
由 Rich Felker 提交于
-
- 18 3月, 2012 4 次提交
-
-
由 Rich Felker 提交于
untested; may need followup-fixes.
-
由 Rich Felker 提交于
if all exception flags will be cleared, we can avoid the expensive store/reload of the environment and just use the fnclex instruction.
-
由 Rich Felker 提交于
-
由 Rich Felker 提交于
-
- 17 3月, 2012 1 次提交
-
-
由 nsz 提交于
Note that the new fesetround has slightly different semantics: Storing the floating-point environment with fnstenv makes the next fldenv (or fldcw) "non-signaling", so unmasked and pending exceptions does not invoke the exception handler. (These are rare since exceptions are handled immediately and by default all exceptions are masked anyway. But if one manually unmasks an exception in the control word then either sets the corresponding exception flag in the status word or the execution of an exception raising floating-point operation gets interrupted then it may happen). So the old implementation did not trap in some rare cases where the new implementation traps. However POSIX does not specify anything like the x87 exception handling traps and the fnstenv/fldenv pair is significantly slower than the fnstcw/fldcw pair (new code is about 5x faster here and it's dominated by the function call overhead).
-
- 29 6月, 2011 1 次提交
-
-
由 Rich Felker 提交于
-
- 14 6月, 2011 2 次提交
-
-
由 Rich Felker 提交于
-
由 Rich Felker 提交于
-
- 13 6月, 2011 1 次提交
-
-
由 Rich Felker 提交于
at present the i386 code does not support sse floating point, which is not part of the standard i386 abi. while it may be desirable to support it later, doing so will reduce performance and require some tricks to probe if sse support is present. this first commit is i386-only, but it should be trivial to port the asm to x86_64.
-