Skip to content
Commit 9be36fb8 authored by Joseph Myers's avatar Joseph Myers
Browse files

Make x86_64 fegetenv preserve exception mask (bug 16198).

Bug 16198 is x86_64 fegetenv wrongly masking exceptions for which
traps are enabled, because that's a side-effect of the fnstenv
instruction.  This patch fixes it to use fldenv immediately after
fnstenv, like the i386 version.  Tested x86_64 and x86.

	[BZ #16198]
	* sysdeps/x86_64/fpu/fegetenv.c (fegetenv): Use fldenv after
	fnstenv.
	* math/test-fenv-preserve.c: New file.
	* math/Makefile (tests): Add test-fenv-preserve.
parent 60a2f3c1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment