The Reactor code in floatToHalfBits() did not match the reference implementation of the sw::half type, leading to failures in dEQP tests which are enabled by the shaderStorageImageExtendedFormats feature. The previous code was based on https://gist.github.com/rygorous/2156668. It doesn't round to nearest even in case of a tie, but that's not demanded by Vulkan. It merits a closer look to see whether there was a bug, or whether dEQP-VK is too strict. Dawn also found the previous implementation to not handle infinity correctly, so a bug seems likely. In any case, it's good to use a reference implementation for now, and look for optimization opportunities later. Bug: b/147900455 Bug: swiftshader:147 Tests: dEQP-VK.image.format_reinterpret.buffer.*_b10g11r11_ufloat_pack32 Change-Id: Id817a012ff38af814907c2de2914ec24565622f3 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/46148 Presubmit-Ready: Nicolas Capens <nicolascapens@google.com> Kokoro-Result: kokoro <noreply+kokoro@google.com> Tested-by:Nicolas Capens <nicolascapens@google.com> Reviewed-by:
Antonio Maiorano <amaiorano@google.com>
| Name |
Last commit
|
Last update |
|---|---|---|
| .. | ||
| Linux | Loading commit data... | |
| BUILD.gn | Loading commit data... | |
| Build.cpp | Loading commit data... | |
| Build.hpp | Loading commit data... | |
| CMakeLists.txt | Loading commit data... | |
| CPUID.cpp | Loading commit data... | |
| CPUID.hpp | Loading commit data... | |
| Configurator.cpp | Loading commit data... | |
| Configurator.hpp | Loading commit data... | |
| Debug.cpp | Loading commit data... | |
| Debug.hpp | Loading commit data... | |
| GrallocAndroid.cpp | Loading commit data... | |
| GrallocAndroid.hpp | Loading commit data... | |
| Half.cpp | Loading commit data... | |
| Half.hpp | Loading commit data... | |
| LRUCache.hpp | Loading commit data... | |
| Math.cpp | Loading commit data... | |
| Math.hpp | Loading commit data... | |
| Memory.cpp | Loading commit data... | |
| Memory.hpp | Loading commit data... | |
| SharedLibrary.hpp | Loading commit data... | |
| Socket.cpp | Loading commit data... | |
| Socket.hpp | Loading commit data... | |
| Synchronization.hpp | Loading commit data... | |
| Timer.cpp | Loading commit data... | |
| Timer.hpp | Loading commit data... | |
| Types.hpp | Loading commit data... |