Skip to content

zink: use actual const for const offset

Erik Faye-Lund requested to merge kusma/mesa:zink-fix-const-offset into main

When we emit constants, we don't know what type they'll be used as, so we just emit them as uint, and then bitcast them to whatever we need.

But this isn't a good idea for ConstOffset, which needs to actually be a const value, and not a const value bitcasted. So we sadly have to open-code the const emitting here to avoid the problem.

Fixes: e963d35e ("zink: use ConstOffset for nir_tex_src_offset") Closes: #4831 (closed)

Merge request reports