Start math tests with a clean fenv.
We always want the default floating point environment when running these
tests.
Bug: 17358010
Change-Id: I6ca2552e9f2d3e07d7b9dcaf0aec66905401c466
diff --git a/tests/math_sincosf_test.cpp b/tests/math_sincosf_test.cpp
index c1a32c9..d30f72e 100644
--- a/tests/math_sincosf_test.cpp
+++ b/tests/math_sincosf_test.cpp
@@ -16,6 +16,8 @@
#include <math.h>
+#include <fenv.h>
+
#include <gtest/gtest.h>
#if defined(__BIONIC__)
@@ -4646,6 +4648,7 @@
TEST(math_sincosf, sincosf_intel) {
#if defined(__BIONIC__)
+ fesetenv(FE_DFL_ENV);
for (size_t i = 0; i < sizeof(g_sincosf_intel_data)/sizeof(sincosf_intel_data_t); i++) {
float fsin, fcos;
sincosf(g_sincosf_intel_data[i].call_data, &fsin, &fcos);