Skip to content

nir: Fix cast

Matt Turner requested to merge mattst88/mesa:nir-loop-unrolling-big-endian into main
nir: Fix cast

We were wrongly telling `nir_const_value_as_uint()` that `iter` had
`bit_size` bits, but in one case it is explicitly i64. This works on
little endian platforms, but caused the nir_loop_unroll_test.fadd{,_rev}
tests to fail on big endian platforms.

Bug: https://bugs.gentoo.org/921297
Fixes: 268ad47c111 ("nir/loop_analyze: Handle bit sizes correctly in calculate_iterations")
nir/tests: Reenable tests that failed on big-endian

These tests were disabled due to the bug fixed in the previous commit.

Merge request reports