nir/builder: Add a helper for getting the most recently added instruction