Skip to content
Commit 0b540a70 authored by Faith Ekstrand's avatar Faith Ekstrand Committed by Juan A. Suarez Romero
Browse files

nir/loop_analyze: Handle bit sizes correctly in calculate_iterations



The current code assumes everything is 32-bit which is very likely true
but not guaranteed by any means.  Instead, use nir_eval_const_opcode to
do the calculations in a bit-size-agnostic way.  We also use the new
constant constructors to build the correct size constants.

Fixes: 6772a17a "nir: Add a loop analysis pass"
Reviewed-by: default avatarTimothy Arceri <tarceri@itsqueeze.com>
(cherry picked from commit 268ad47c)
parent afaec581
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment