diff options
Diffstat (limited to 'media-libs/openimageio/files/openimageio-2.5.8.0-fix-unit_simd.patch')
-rw-r--r-- | media-libs/openimageio/files/openimageio-2.5.8.0-fix-unit_simd.patch | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/media-libs/openimageio/files/openimageio-2.5.8.0-fix-unit_simd.patch b/media-libs/openimageio/files/openimageio-2.5.8.0-fix-unit_simd.patch new file mode 100644 index 000000000000..b43d96ce959b --- /dev/null +++ b/media-libs/openimageio/files/openimageio-2.5.8.0-fix-unit_simd.patch @@ -0,0 +1,18 @@ +From: Paul Zander <negril.nx+gentoo@gmail.com> +Make simd tests use a threshold for floating point equality check + +diff --git a/src/libutil/simd_test.cpp b/src/libutil/simd_test.cpp +index 4ecee70..0c15d81 100644 +--- a/src/libutil/simd_test.cpp ++++ b/src/libutil/simd_test.cpp +@@ -1611,8 +1611,8 @@ void test_mathfuncs () + VEC expA = mkvec<VEC> (0.367879441171442f, 1.0f, 2.718281828459045f, 90.0171313005218f); + OIIO_CHECK_SIMD_EQUAL (exp(A), expA); + OIIO_CHECK_SIMD_EQUAL_THRESH (log(expA), A, 1e-6f); +- OIIO_CHECK_SIMD_EQUAL (fast_exp(A), +- mkvec<VEC>(fast_exp(A[0]), fast_exp(A[1]), fast_exp(A[2]), fast_exp(A[3]))); ++ OIIO_CHECK_SIMD_EQUAL_THRESH (fast_exp(A), ++ mkvec<VEC>(fast_exp(A[0]), fast_exp(A[1]), fast_exp(A[2]), fast_exp(A[3])), 1e-7f); + OIIO_CHECK_SIMD_EQUAL_THRESH (fast_log(expA), + mkvec<VEC>(fast_log(expA[0]), fast_log(expA[1]), fast_log(expA[2]), fast_log(expA[3])), 0.00001f); + OIIO_CHECK_SIMD_EQUAL_THRESH (fast_pow_pos(VEC(2.0f), A), |