Bug 94714 - dEQP ldexp precision tests fail
Summary: dEQP ldexp precision tests fail
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i965 (show other bugs)
Version: git
Hardware: Other All
: medium normal
Assignee: Jason Ekstrand
QA Contact: Intel 3D Bugs Mailing List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: i965-deqp
  Show dependency treegraph
 
Reported: 2016-03-26 09:29 UTC by Kenneth Graunke
Modified: 2019-03-14 08:40 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description Kenneth Graunke 2016-03-26 09:29:16 UTC
24 of the dEQP-GLES31.functional.shaders.builtin_functions.precision.ldexp.* tests fail, at least on Broadwell.  (These tests also exist in the Vulkan conformance suite.)

It seems that our current lowering breaks for certain values.
Comment 1 Jason Ekstrand 2016-03-26 14:42:45 UTC
Among the patches I posted to the list yesterday is a new lowering for ldexp that I think is better than both the spec stupidity and what we have today.  The spec'd f*2.0^exp is sufficient for deqp but has range problems. What we have today misses some edge cases when denormals get involved.
Comment 2 Kenneth Graunke 2016-04-14 05:57:23 UTC
Fixed in master by Jason:

commit 505a8fbdf8f2b6d2aaab5a04244cd3329f9dbe97
Author: Kenneth Graunke <kenneth@whitecape.org>
Date:   Tue Apr 12 02:30:25 2016 -0700

    i965: Switch to NIR for ldexp lowering.
    
    The old GLSL IR based lowering doesn't quite work right in all cases,
    and fails several dEQP-GLES31 and Vulkan CTS tests.  Jason's new
    approach in NIR passes all the tests.  There's not likely to be a ton
    of advantage to lowering early in GLSL IR anyway, so...switch.
    
    Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
    Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
    Reviewed-by: Matt Turner <mattst88@gmail.com>

commit 4455bfa9a0cc53a3c7e3c171b022cbe6d6dcdff8
Author: Jason Ekstrand <jason.ekstrand@intel.com>
Date:   Fri Mar 25 12:12:38 2016 -0700

    nir/algebraic: Add lowering for ldexp
    
    The algorithm used is different from both the naive suggestion from the
    GLSL spec and the one used in GLSL IR today.  Unfortunately, the GLSL IR
    implementation that we have today doesn't handle denormals (for those that
    care) or the case where the float source is +-inf.
    
    Reviewed-by: Matt Turner <mattst88@gmail.com>

Thanks Jason and Matt!


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.