Payment of the UBIT is the responsibility of the tax-exempt entity, presumably your retirement account, not you personally. Whatever amount the retirement account pays reduces the balance that will be subject to income tax when eventually distributed, but yes, the income that the retirement account received that was subject to UBIT will be subject to ordinary income tax when eventually distributed (unless the investment is in a Roth account). Your retirement account paying UBIT does not create any after-tax basis in the account.