I have a traditional IRA that has a non-deductible basis amount. In 2018, I rolled my 401K and my defined contribution pension into the IRA. Does that impact the basis?

My assumption is that the basis remains the same but that it becomes a much smaller percentage when I take a distribution which I did in 2018.  This makes me wonder if I should have considered the 401k and pension when I converted amounts from the traditional IRA to my Roth IRA in 2016 and 2017.