List of affected tests: dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_vertex.scalar dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_vertex.vec2 dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_vertex.vec3 dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_vertex.vec4 dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_fragment.scalar dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_fragment.vec2 dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_fragment.vec3 dEQP-GLES3.functional.shaders.builtin_functions.precision.asin.highp_fragment.vec4 dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_vertex.scalar dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_vertex.vec2 dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_vertex.vec3 dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_vertex.vec4 dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_fragment.scalar dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_fragment.vec2 dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_fragment.vec3 dEQP-GLES3.functional.shaders.builtin_functions.precision.acos.highp_fragment.vec4 dEQP-GLES3.functional.shaders.builtin_functions.precision.acosh.highp_fragment.scalar dEQP-GLES3.functional.shaders.builtin_functions.precision.acosh.highp_fragment.vec2 dEQP-GLES3.functional.shaders.builtin_functions.precision.acosh.highp_fragment.vec3 dEQP-GLES3.functional.shaders.builtin_functions.precision.acosh.highp_fragment.vec4 According to the GLES3 specs, trigonometric functions have undefined precision, so I wonder if these tests are valid at all. Since these are approximated using polynomials, in case we want to improve precision, we could use higher order polynomials at the cost of some performance. I have conducted some tests after a quick research and found some polynomials that seemed to reduce significantly the number of tests failed (for combined highp, mediump, lowp tests) but increased significantly the maximum absolute error we obtained in some cases, so we probably want to find better polynomials if we want to improve this.
Using better polynomials is probably wise. In case someone wants to take this on and is interested in the performance impact: Programs known to use acos: Lightsmark, Tropico 5, Unigine Valley. Unreal 4's Sun Temple demo. Programs known to use atan: Champions of Regnum, Guacamelee, Natural Selection 2, The Polynomial, To The Moon, Unigine Valley, Unreal 4's Sun Temple demo. Nobody uses asin.
Curro recently did some work in this area: commit a6046d217d14130a46f6ffe42992fd745551a928 Author: Francisco Jerez <currojerez@riseup.net> Date: Wed Mar 2 23:50:04 2016 -0800 glsl: Improve the accuracy of the acos() approximation. The adjusted polynomial coefficients come from the numerical minimization of the L2 norm of the relative error. The old coefficients would give a maximum relative error of about 15000 ULP in the neighborhood around acos(x) = 0, the new ones give a relative error bounded by less than 2000 ULP in the same neighborhood. Fixes four dEQP subtests: dEQP-GLES31.functional.shaders.builtin_functions.precision.acos. highp_compute.{scalar,vec2,vec3,vec4} All the tests seem to be passing these days. So, marking this Resolved/Fixed.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.