(Edited to correct "inheritance tax" to the technically correct term, "estate tax")
If you're a billionaire who does the "take out loans against your unrealized cap gains" trick, then you, you know... can't sell your stock. So then your stock passes to your kids -- who, due to the stepped up basis, yes, do not have to pay cap gains on that stock.
But there's a 40% estate tax.
Estate tax generally isn't very relevant even to the ordinarily-rich, because it has an extremely high deduction (about $27M for a married couple), but for a billionaire it's absolutely relevant.
Now, sure, if you paid both the cap gains and the estate tax you'd pay that much more taxes, but if you compare a normally-wealthy person (pays 15-20% cap gains and 0% estate tax) and a billionaire (pays 0% cap gains and 40% estate tax), it's obvious that the billionaire, eventually, pays a much higher tax rate.
Yeah, the real loophole is step-up in basis with no corresponding tax event. What should really happen is that every step-up in basis should correspond to a tax event or, somewhat more speculatively, only net changes in basis should result in tax events. Incidentally, this would also give everybody access to reduced taxes due to unrealized losses (tax loss harvesting) instead of just people with accountants.