nir: Use nir_intrinsic_set_base in atomic lowering.
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 14 Jul 2016 21:18:33 +0000 (14:18 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Sat, 16 Jul 2016 00:17:10 +0000 (17:17 -0700)
commit52e75dcb8c04c0dde989970c4c587cbe8313f7cf
treed431e9711da17fd258a79b614ce26c925af7bc70
parent50b9bb94219ae443d81cda1b15cda519d48dbdc7
nir: Use nir_intrinsic_set_base in atomic lowering.

This is more readable and also offers assertions that protect against
setting const_index fields on the wrong kind of intrinsic.

Suggested by Jason.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/compiler/nir/nir_lower_io.c