e78bd88a06
Wether need_nuw is used is currently decided in two different ways: - globally through the allow_offset_wrap option; - per intrinsic but hard-coded in opt_offsets. Make this more flexible by creating a callback that is called per intrinsic. This will allow backends to decide, on a per-intrinsic basis, whether need_nuw is needed. Note that the main use case for ir3 is to add support for opt_offsets for global memory accesses. Other intrinsics don't need need_nuw but global memory accesses do. Signed-off-by: Job Noorman <jnoorman@igalia.com> Reviewed-by: Timur Kristóf <timur.kristof@gmail.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/37114>