nir/lower_viewport: Check variable mode first