Skip to content

llvmpipe: Use lp_build_round_arch on IBM Z (s390x)

Marius Hillenbrand requested to merge mhillenbrand/mesa:s390x_arch_rounding into main

LLVM has all the required intrinsics available on IBM Z, so use them for rounding operations (they will be implemented as a single instruction). This change makes the test case lp_test_arit pass, because it avoids using the buggy generic code.

As preparation for changing the behavior of LLVMpipe on IBM Z, add a flag to detect that platform. As it is always known at compile-time, we do not add it to the struct for cpu flags to avoid inflating that struct's size.

Tested with Mesa's test suite, where it solves the failure of lp_test_arit and does not cause regressions, and piglit, where it fixes 22 failing tests.

Signed-off-by: Marius Hillenbrand mhillen@linux.ibm.com

Merge request reports